# Refresh Reflection using API call

**URL:** <https://community.dremio.com/t/refresh-reflection-using-api-call/4559>\
**Category:** Uncategorized\
**Created:** [November 12, 2019, 3:36pm UTC](https://community.dremio.com/t/refresh-reflection-using-api-call/4559 "2019-11-12T15:36:20Z")\
**Posts on this page:** 9\
**Page:** 2

<div class="post-metadata">

**Author:** ![joelhansen](https://avatars.discourse-cdn.com/v4/letter/j/3be4f8/32.png) [@joelhansen](https://community.dremio.com/u/joelhansen)\
**Post date:** [January 29, 2021, 4:52pm UTC](https://community.dremio.com/t/refresh-reflection-using-api-call/4559/21 "2021-01-29T16:52:57Z")

</div>

@balaji.ramaswamy

This POST call updates all reflections from the physical dataset, right?

I can’t use it because I have several virtual datasets with reflection that come from the same physical dataset, and I need to programmatically update only the reflection of one virtual dataset.

Or can I use this POST in some way with a virtual dataset?

Tks!

---

<div class="post-metadata">

**Author:** ![joelhansen](https://avatars.discourse-cdn.com/v4/letter/j/3be4f8/32.png) [@joelhansen](https://community.dremio.com/u/joelhansen)\
**Post date:** [January 29, 2021, 5:02pm UTC](https://community.dremio.com/t/refresh-reflection-using-api-call/4559/22 "2021-01-29T17:02:08Z")

</div>

@balaji.ramaswamy

In short, I would need to programmatically reproduce for a single reflection what Dremio does scheduled for the reflections auto refresh.

---

<div class="post-metadata">

**Author:** ![balaji.ramaswamy](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/balaji.ramaswamy/32/843_2.png) [@balaji.ramaswamy](https://community.dremio.com/u/balaji.ramaswamy)\
**Post date:** [January 30, 2021, 4:03am UTC](https://community.dremio.com/t/refresh-reflection-using-api-call/4559/23 "2021-01-30T04:03:57Z")

</div>

@joelhansen

Currently that is not possible. One way is to disable and enable the reflection on the VDS. Looks like you can pass enabled: false  
{

> “entityType”: “reflection” [immutable, generated by Dremio],  
> “id”: String [immutable, generated by Dremio],  
> “tag”: String [immutable, generated by Dremio],  
> “name”: String,  
> “enabled”: Boolean,  
> “createdAt”: String (RFC3339 date) [immutable, generated by Dremio],  
> “updatedAt”: String (RFC3339 date) [immutable, generated by Dremio],  
> “type”: String [“AGGREGATION”, “RAW”] [immutable after creation],  
> “datasetId”: String [immutable after creation],  
> “currentSizeBytes”: Number [immutable, generated by Dremio],  
> “totalSizeBytes”: Number [immutable, generated by Dremio],  
> “status”: Reflection Status [immutable, generated by Dremio],  
> “dimensionFields”: [Reflection Field With Granularity] [optional, only valid for AGGREGATION],  
> “measureFields”: [Reflection Field] [optional, only valid for AGGREGATION],  
> “displayFields”: [Reflection Field] [optional, only valid for RAW],  
> “distributionFields”: [Reflection Field] [optional],  
> “partitionFields”: [Reflection Field] [optional],  
> “sortFields”: [Reflection Field] [optional],  
> “partitionDistributionStrategy”: String [“CONSOLIDATED”, “STRIPED”],  
> }

[http://docs.dremio.com/rest-api/reflections/put-reflection.html](http://docs.dremio.com/rest-api/reflections/put-reflection.html)

---

<div class="post-metadata">

**Author:** ![allCag](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@allCag](https://community.dremio.com/u/allCag)\
**Post date:** [December 29, 2023, 3:32pm UTC](https://community.dremio.com/t/refresh-reflection-using-api-call/4559/24 "2023-12-29T15:32:36Z")

</div>

Hello @balaji.ramaswamy ,

this old thread raised a problem we would like to improve on: trigger a refresh of a reflection using the API without having to do a “disable” of the reflection. As @joelhansen it’s a problem because users are still posting queries when the reflection is being refreshed.

What are the plans to implement such API triggered reflection refresh without disabling the last available version of it ?  
Is there a workaround to this current limitation (we use v24) ?

Thanks & Rgs,  
Alexandre

---

<div class="post-metadata">

**Author:** ![balaji.ramaswamy](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/balaji.ramaswamy/32/843_2.png) [@balaji.ramaswamy](https://community.dremio.com/u/balaji.ramaswamy)\
**Post date:** [December 30, 2023, 11:36pm UTC](https://community.dremio.com/t/refresh-reflection-using-api-call/4559/25 "2023-12-30T23:36:20Z")

</div>

@allCag The feature to refresh at VDS level is coming up. At present either background refresh or API catalog refresh on opne of the PDS on which the VDS is defined or disable/enable (This option however will lose job history)

Let me find out on timelines on all the new features coming for reflection management 2.0

---

<div class="post-metadata">

**Author:** ![allCag](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@allCag](https://community.dremio.com/u/allCag)\
**Post date:** [February 12, 2024, 10:47am UTC](https://community.dremio.com/t/refresh-reflection-using-api-call/4559/26 "2024-02-12T10:47:35Z")

</div>

> [@balaji.ramaswamy](#):
>
> n management

Hi @balaji.ramaswamy ,  
that’s great to hear that this feature will come !  
Could you update on the timeline for the delivery of this Reflection Management v2.0 ?  
Rgs,  
Alexandre

---

<div class="post-metadata">

**Author:** ![balaji.ramaswamy](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/balaji.ramaswamy/32/843_2.png) [@balaji.ramaswamy](https://community.dremio.com/u/balaji.ramaswamy)\
**Post date:** [February 15, 2024, 12:00am UTC](https://community.dremio.com/t/refresh-reflection-using-api-call/4559/27 "2024-02-15T00:00:37Z")

</div>

@allCag VDS level refresh is slated for this year but no exact ETA, the release notes should have it, please check here in a few months and hopefully will have a version/date

---

<div class="post-metadata">

**Author:** ![Muneer](https://avatars.discourse-cdn.com/v4/letter/m/cdc98d/32.png) [@Muneer](https://community.dremio.com/u/Muneer)\
**Post date:** [May 7, 2024, 3:10pm UTC](https://community.dremio.com/t/refresh-reflection-using-api-call/4559/28 "2024-05-07T15:10:02Z")

</div>

Is there a comprehensive doc on Reflection management? Please do post a link here if possible. Thanks!

---

<div class="post-metadata">

**Author:** ![balaji.ramaswamy](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/balaji.ramaswamy/32/843_2.png) [@balaji.ramaswamy](https://community.dremio.com/u/balaji.ramaswamy)\
**Post date:** [May 13, 2024, 7:11am UTC](https://community.dremio.com/t/refresh-reflection-using-api-call/4559/29 "2024-05-13T07:11:16Z")

</div>

@Muneer

> **[Accelerating Queries with Reflections | Dremio Documentation](https://docs.dremio.com/current/sonar/reflections/)**
>
> A reflection is an optimized materialization of source data or a query, similar to a materialized view, that is derived from an existing table or view. A table or view that a reflection is derived from is that refection's anchor.

> **[Reflection | Dremio Documentation](https://docs.dremio.com/current/reference/api/reflections/)**
>
> Use the Reflection API to retrieve a list of raw and aggregation reflections, retrieve individual reflections, and create, update, and delete reflections.

> **[Reflection | Dremio Documentation](https://docs.dremio.com/current/reference/api/reflections/#refreshing-a-reflection)**
>
> Use the Reflection API to retrieve a list of raw and aggregation reflections, retrieve individual reflections, and create, update, and delete reflections.

[Previous page](https://community.dremio.com/t/refresh-reflection-using-api-call/4559.md?page=1)
