-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Maps] Upgraded maps panel displays Cannot create AbstractESSourceDescriptor when indexPatternId is not provided error and no data #191777
Comments
Pinging @elastic/kibana-presentation (Team:Presentation) |
This looks like a reference error to me - the other panels on the dashboard are built on the same data view, and their references are being converted properly. Looking at the saved object - it seems like we are creating the reference ( This is just my guess as a Maps layman 🙈 |
You are right, its a reference problem. The error message is similar to one in canvas, #190994, which was a result of a reference problem. |
@bhavyarm Where did you get these dashboard exports from (which version, how where they made)? The references do not contain the expected shape. Provided reference for data view used in the map. Notice the
|
In 8.15, map embeddable was migrated from a legacy embeddable to a react embeddable. This changed reference injection. See below for details. TLDR is that legacy embeddables pass all references to the embeddable factory when no references for the panel exist. React embeddables just pass an empty reference list regardless of if panel references exist or not. Reference injection with legacy embeddables
Reference injection with react embeddables
|
…eDescriptor when indexPatternId is not provided error and no data (#199690) Closes #191777 In 8.15, map embeddable was migrated from a legacy embeddable to a react embeddable. This changed reference injection. See below for details. TLDR is that legacy embeddables pass all references to the embeddable factory when no references for the panel exist. React embeddables just pass an empty reference list regardless of if panel references exist or not. [Reference injection with legacy embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#L53) ``` workingState.panels[key] = { ...panel }; const filteredReferences = getReferencesForPanelId(key, references); const panelReferences = filteredReferences.length === 0 ? references : filteredReferences; ``` [Reference injection with react embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/public/dashboard_container/embeddable/dashboard_container.tsx#L835) ``` const rawState = this.getInput().panels[childId].explicitInput; const { id, ...serializedState } = rawState; if (!rawState || Object.keys(serializedState).length === 0) return; const references = getReferencesForPanelId(childId, this.savedObjectReferences); return { rawState, references, }; ``` ### Test instructions 1) install dashboard from 7.17 saved objects from issue. 2) Open dashboard. Verify data-view is found. Note, layer will not load since your install has no index 'logstash-*', but reference problem has been fixed Co-authored-by: Elastic Machine <[email protected]>
…eDescriptor when indexPatternId is not provided error and no data (elastic#199690) Closes elastic#191777 In 8.15, map embeddable was migrated from a legacy embeddable to a react embeddable. This changed reference injection. See below for details. TLDR is that legacy embeddables pass all references to the embeddable factory when no references for the panel exist. React embeddables just pass an empty reference list regardless of if panel references exist or not. [Reference injection with legacy embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#L53) ``` workingState.panels[key] = { ...panel }; const filteredReferences = getReferencesForPanelId(key, references); const panelReferences = filteredReferences.length === 0 ? references : filteredReferences; ``` [Reference injection with react embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/public/dashboard_container/embeddable/dashboard_container.tsx#L835) ``` const rawState = this.getInput().panels[childId].explicitInput; const { id, ...serializedState } = rawState; if (!rawState || Object.keys(serializedState).length === 0) return; const references = getReferencesForPanelId(childId, this.savedObjectReferences); return { rawState, references, }; ``` ### Test instructions 1) install dashboard from 7.17 saved objects from issue. 2) Open dashboard. Verify data-view is found. Note, layer will not load since your install has no index 'logstash-*', but reference problem has been fixed Co-authored-by: Elastic Machine <[email protected]> (cherry picked from commit 80a9f40)
…eDescriptor when indexPatternId is not provided error and no data (elastic#199690) Closes elastic#191777 In 8.15, map embeddable was migrated from a legacy embeddable to a react embeddable. This changed reference injection. See below for details. TLDR is that legacy embeddables pass all references to the embeddable factory when no references for the panel exist. React embeddables just pass an empty reference list regardless of if panel references exist or not. [Reference injection with legacy embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#L53) ``` workingState.panels[key] = { ...panel }; const filteredReferences = getReferencesForPanelId(key, references); const panelReferences = filteredReferences.length === 0 ? references : filteredReferences; ``` [Reference injection with react embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/public/dashboard_container/embeddable/dashboard_container.tsx#L835) ``` const rawState = this.getInput().panels[childId].explicitInput; const { id, ...serializedState } = rawState; if (!rawState || Object.keys(serializedState).length === 0) return; const references = getReferencesForPanelId(childId, this.savedObjectReferences); return { rawState, references, }; ``` ### Test instructions 1) install dashboard from 7.17 saved objects from issue. 2) Open dashboard. Verify data-view is found. Note, layer will not load since your install has no index 'logstash-*', but reference problem has been fixed Co-authored-by: Elastic Machine <[email protected]> (cherry picked from commit 80a9f40)
…eDescriptor when indexPatternId is not provided error and no data (elastic#199690) Closes elastic#191777 In 8.15, map embeddable was migrated from a legacy embeddable to a react embeddable. This changed reference injection. See below for details. TLDR is that legacy embeddables pass all references to the embeddable factory when no references for the panel exist. React embeddables just pass an empty reference list regardless of if panel references exist or not. [Reference injection with legacy embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#L53) ``` workingState.panels[key] = { ...panel }; const filteredReferences = getReferencesForPanelId(key, references); const panelReferences = filteredReferences.length === 0 ? references : filteredReferences; ``` [Reference injection with react embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/public/dashboard_container/embeddable/dashboard_container.tsx#L835) ``` const rawState = this.getInput().panels[childId].explicitInput; const { id, ...serializedState } = rawState; if (!rawState || Object.keys(serializedState).length === 0) return; const references = getReferencesForPanelId(childId, this.savedObjectReferences); return { rawState, references, }; ``` ### Test instructions 1) install dashboard from 7.17 saved objects from issue. 2) Open dashboard. Verify data-view is found. Note, layer will not load since your install has no index 'logstash-*', but reference problem has been fixed Co-authored-by: Elastic Machine <[email protected]> (cherry picked from commit 80a9f40)
…eDescriptor when indexPatternId is not provided error and no data (elastic#199690) Closes elastic#191777 In 8.15, map embeddable was migrated from a legacy embeddable to a react embeddable. This changed reference injection. See below for details. TLDR is that legacy embeddables pass all references to the embeddable factory when no references for the panel exist. React embeddables just pass an empty reference list regardless of if panel references exist or not. [Reference injection with legacy embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#L53) ``` workingState.panels[key] = { ...panel }; const filteredReferences = getReferencesForPanelId(key, references); const panelReferences = filteredReferences.length === 0 ? references : filteredReferences; ``` [Reference injection with react embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/public/dashboard_container/embeddable/dashboard_container.tsx#L835) ``` const rawState = this.getInput().panels[childId].explicitInput; const { id, ...serializedState } = rawState; if (!rawState || Object.keys(serializedState).length === 0) return; const references = getReferencesForPanelId(childId, this.savedObjectReferences); return { rawState, references, }; ``` ### Test instructions 1) install dashboard from 7.17 saved objects from issue. 2) Open dashboard. Verify data-view is found. Note, layer will not load since your install has no index 'logstash-*', but reference problem has been fixed Co-authored-by: Elastic Machine <[email protected]>
…eDescriptor when indexPatternId is not provided error and no data (elastic#199690) Closes elastic#191777 In 8.15, map embeddable was migrated from a legacy embeddable to a react embeddable. This changed reference injection. See below for details. TLDR is that legacy embeddables pass all references to the embeddable factory when no references for the panel exist. React embeddables just pass an empty reference list regardless of if panel references exist or not. [Reference injection with legacy embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#L53) ``` workingState.panels[key] = { ...panel }; const filteredReferences = getReferencesForPanelId(key, references); const panelReferences = filteredReferences.length === 0 ? references : filteredReferences; ``` [Reference injection with react embeddables](https://github.com/elastic/kibana/blob/8.15/src/plugins/dashboard/public/dashboard_container/embeddable/dashboard_container.tsx#L835) ``` const rawState = this.getInput().panels[childId].explicitInput; const { id, ...serializedState } = rawState; if (!rawState || Object.keys(serializedState).length === 0) return; const references = getReferencesForPanelId(childId, this.savedObjectReferences); return { rawState, references, }; ``` ### Test instructions 1) install dashboard from 7.17 saved objects from issue. 2) Open dashboard. Verify data-view is found. Note, layer will not load since your install has no index 'logstash-*', but reference problem has been fixed Co-authored-by: Elastic Machine <[email protected]>
Kibana version: 8.15.1
Browser version: chrome latest
Browser OS version: OS X
Original install method (e.g. download page, yum, from source, etc.): from staging
Describe the bug: I upgraded from 7.17.23->8.15.1 BC1 with a bunch of saved objects. In a dashboard, one of the maps panel doesn't display any data instead displays this error - "Unable to create layer. Cannot create AbstractESSourceDescriptor when indexPatternId is not provided"
Same error when I exported the dashboard saved object from 7.17.23 and imported it to 8.15.1.
Here is the attached saved object file from 7.17.23 -
7.17.x_dashboard.ndjson.zip
Saved object file from 8.15.1 BC1
8.15.1_dashboard.ndjson.zip
The text was updated successfully, but these errors were encountered: