ci: make mapping test work for new mappings

This commit is contained in:
Wieland Schöbl
2019-11-05 13:26:33 +01:00
parent 8f7201e2cf
commit 19ef656289
5 changed files with 30735 additions and 31669 deletions

View File

@@ -256,28 +256,11 @@ export interface ElasticsearchObject {
};
}
export interface ElasticsearchMapping {
/**
* The mappings of the index
*/
mappings: {
[name: string]: ElasticsearchObject;
};
/**
* The settings for the index
*/
settings: unknown;
/**
* The name of the index
*/
template: string;
}
// TODO: docs
export interface ElasticsearchMappings {
[indexName: string]: ElasticsearchMapping;
/**
* A collection of Elasticsearch Templates
*/
export interface ElasticsearchTemplateCollection {
[indexName: string]: ElasticsearchTemplate;
}
/**
@@ -291,39 +274,7 @@ export interface ElasticsearchTemplate {
* This is a pre-defined structure you should use for your mapping
*/
mappings: {
/**
* This mapping will be used by default for everything
*/
_default_: {
/**
* Contains the original JSON document body
*
* https://www.elastic.co/guide/en/elasticsearch/reference/5.6/mapping-source-field.html
*/
_source: {
/**
* Any fields that are excluded from the source
*/
excludes: string[];
};
/**
* Whether Elasticsearch should automatically add date fields to objects
*/
date_detection: false;
/**
* This is where all the dynamic templates should go
*/
dynamic_templates: ElasticsearchDynamicTemplate[];
/**
* This is where all the mappings should go
*/
properties: {
[name: string]: ElasticsearchObject;
};
};
[typeName: string]: ElasticsearchObject;
};
/**