mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 09:48:58 -04:00
[ML] Account for "properties" layer in find_file_structure mappings (#77035)
This is the UI side companion for elastic/elasticsearch#62158 Previously the "mappings" field of the response from the find_file_structure endpoint was not a drop-in for the mappings format of the create index endpoint - the "properties" layer was missing. The reason for omitting it initially was that the assumption was that the find_file_structure endpoint would only ever return very simple mappings without any nested objects. However, this will not be true in the future, as we will improve mappings detection for complex JSON objects. As a first step it makes sense to move the returned mappings closer to the standard format.
This commit is contained in:
parent
538bd4be51
commit
c7dac8000c
2 changed files with 7 additions and 2 deletions
|
@ -84,7 +84,12 @@ export interface Settings {
|
|||
}
|
||||
|
||||
export interface Mappings {
|
||||
[key: string]: any;
|
||||
_meta?: {
|
||||
created_by: string;
|
||||
};
|
||||
properties: {
|
||||
[key: string]: any;
|
||||
};
|
||||
}
|
||||
|
||||
export interface IngestPipelineWrapper {
|
||||
|
|
|
@ -94,7 +94,7 @@ export function importDataProvider({ asCurrentUser }: IScopedClusterClient) {
|
|||
_meta: {
|
||||
created_by: INDEX_META_DATA_CREATED_BY,
|
||||
},
|
||||
properties: mappings,
|
||||
properties: mappings.properties,
|
||||
},
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue