From 4673c143ce52ebe63eed0609f814501dfddaa73e Mon Sep 17 00:00:00 2001 From: Enrico Ottonello Date: Thu, 7 Jan 2021 11:48:00 +0100 Subject: [PATCH] curl command to create catalog index with mapping for elastic search on production --- .../es/schemaCatalogElasticsearch.curl | 440 ++++++++++++++++++ 1 file changed, 440 insertions(+) create mode 100644 dnet-ariadneplus/src/main/resources/es/schemaCatalogElasticsearch.curl diff --git a/dnet-ariadneplus/src/main/resources/es/schemaCatalogElasticsearch.curl b/dnet-ariadneplus/src/main/resources/es/schemaCatalogElasticsearch.curl new file mode 100644 index 0000000..0dbf707 --- /dev/null +++ b/dnet-ariadneplus/src/main/resources/es/schemaCatalogElasticsearch.curl @@ -0,0 +1,440 @@ +curl -X PUT "http://elastic.ariadne.d4science.org:9200/catalog?pretty" -H 'Content-Type: application/json' -d ' +{ + "mappings" : { + "properties" : { + "aatSubjects" : { + "properties" : { + "id" : { + "type" : "text" + }, + "label" : { + "type" : "text" + }, + "lang" : { + "type" : "text" + } + } + }, + "accessPolicy" : { + "type" : "text" + }, + "accessRights" : { + "type" : "text" + }, + "accrualPeriodicity" : { + "type" : "text" + }, + "archaeologicalResourceType" : { + "properties" : { + "id" : { + "type" : "long" + }, + "name" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + } + } + }, + "archeologicalResourceType" : { + "properties" : { + "name" : { + "type" : "text", + "fields" : { + "keyword" : { + "type" : "keyword", + "ignore_above" : 256 + } + } + } + } + }, + "audience" : { + "type" : "text" + }, + "contactPoint" : { + "type" : "text" + }, + "contributor" : { + "properties" : { + "email" : { + "type" : "text" + }, + "name" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + }, + "phone" : { + "type" : "text" + }, + "type" : { + "type" : "text" + } + } + }, + "creator" : { + "properties" : { + "email" : { + "type" : "text" + }, + "name" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + }, + "phone" : { + "type" : "text" + }, + "type" : { + "type" : "text" + } + } + }, + "derivedSubject" : { + "properties" : { + "prefLabel" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + }, + "source" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + } + } + }, + "description" : { + "type" : "text" + }, + "distribution" : { + "properties" : { + "accessURL" : { + "type" : "text" + }, + "description" : { + "type" : "text" + }, + "issued" : { + "type" : "date", + "format" : "year || date_optional_time" + }, + "modified" : { + "type" : "date", + "format" : "year || date_optional_time" + }, + "publisher" : { + "properties" : { + "email" : { + "type" : "text" + }, + "name" : { + "type" : "text" + }, + "phone" : { + "type" : "text", + "fields" : { + "keyword" : { + "type" : "keyword", + "ignore_above" : 256 + } + } + }, + "type" : { + "type" : "text" + } + } + }, + "title" : { + "type" : "text" + } + } + }, + "extent" : { + "type" : "text" + }, + "hasItemMetadataStructure" : { + "properties" : { + "characterSet" : { + "type" : "text" + } + } + }, + "hasMetadataRecord" : { + "properties" : { + "conformsTo" : { + "properties" : { + "characterSet" : { + "type" : "text" + }, + "description" : { + "type" : "text" + } + } + }, + "xmlDoc" : { + "type" : "text" + } + } + }, + "identifier" : { + "type" : "keyword" + }, + "isPartOf" : { + "type" : "text" + }, + "issued" : { + "type" : "date", + "format" : "year || date_optional_time" + }, + "keyword" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + }, + "landingPage" : { + "type" : "text" + }, + "language" : { + "type" : "text" + }, + "legalResponsible" : { + "properties" : { + "email" : { + "type" : "text" + }, + "name" : { + "type" : "text" + }, + "phone" : { + "type" : "text" + }, + "type" : { + "type" : "text" + } + } + }, + "modified" : { + "type" : "date", + "format" : "year || date_optional_time" + }, + "nativeSubject" : { + "properties" : { + "prefLabel" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + }, + "rdfAbout" : { + "type" : "text", + "fields" : { + "keyword" : { + "type" : "keyword", + "ignore_above" : 256 + } + } + } + } + }, + "originalId" : { + "type" : "text" + }, + "owner" : { + "properties" : { + "email" : { + "type" : "text" + }, + "name" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + }, + "phone" : { + "type" : "text" + }, + "type" : { + "type" : "text" + } + } + }, + "packageId" : { + "type" : "text" + }, + "placeName" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + }, + "postcode" : { + "type" : "text" + }, + "providerId" : { + "type" : "text" + }, + "publisher" : { + "properties" : { + "email" : { + "type" : "text" + }, + "name" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + }, + "phone" : { + "type" : "text" + }, + "type" : { + "type" : "text" + } + } + }, + "rdfAbout" : { + "type" : "text" + }, + "resourceType" : { + "type" : "text" + }, + "rights" : { + "type" : "text" + }, + "scientificResponsible" : { + "properties" : { + "email" : { + "type" : "text" + }, + "name" : { + "type" : "text" + }, + "phone" : { + "type" : "text" + }, + "type" : { + "type" : "text" + } + } + }, + "spatial" : { + "properties" : { + "address" : { + "type" : "text" + }, + "boundingBoxMaxLat" : { + "type" : "text" + }, + "boundingBoxMaxLon" : { + "type" : "text" + }, + "boundingBoxMinLat" : { + "type" : "text" + }, + "boundingBoxMinLon" : { + "type" : "text" + }, + "coordinateSystem" : { + "type" : "text" + }, + "country" : { + "type" : "text" + }, + "location" : { + "type" : "geo_point" + }, + "placeName" : { + "type" : "text", + "fields" : { + "keyword" : { + "type" : "keyword", + "ignore_above" : 256 + } + } + }, + "postcode" : { + "type" : "text", + "fields" : { + "keyword" : { + "type" : "keyword", + "ignore_above" : 256 + } + } + } + } + }, + "technicalResponsible" : { + "properties" : { + "email" : { + "type" : "text" + }, + "name" : { + "type" : "text" + }, + "phone" : { + "type" : "text" + }, + "type" : { + "type" : "text" + } + } + }, + "temporal" : { + "type" : "nested", + "properties" : { + "from" : { + "type" : "date", + "format" : "year || date_optional_time" + }, + "periodName" : { + "type" : "text", + "fields" : { + "raw" : { + "type" : "keyword" + } + } + }, + "until" : { + "type" : "date", + "format" : "year || date_optional_time" + }, + "uri" : { + "type" : "text" + } + } + }, + "title" : { + "type" : "text" + } + } + } + } + ' \ No newline at end of file