Skip to content
Snippets Groups Projects
Commit 3a0ce853 authored by Zhibin Mai's avatar Zhibin Mai
Browse files

Remove unused class and add missing files

parent 59d2d8c4
No related branches found
No related tags found
1 merge request!846Refactor the augmenter to search and fetch indexed data from the ElasticSearch service directly
Pipeline #294905 failed
Showing
with 208 additions and 3 deletions
package org.opengroup.osdu.indexer.util;public class AugmenterQuery {
}
/*
* Copyright © Schlumberger
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0 *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.opengroup.osdu.indexer.util;
import co.elastic.clients.elasticsearch._types.SortOptions;
......
/*
* Copyright © Schlumberger
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0 *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.opengroup.osdu.indexer.util;
import co.elastic.clients.elasticsearch.ElasticsearchClient;
......
/*
* Copyright © Schlumberger
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0 *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.opengroup.osdu.indexer.util;
import co.elastic.clients.elasticsearch._types.SortOptions;
......
package org.opengroup.osdu.indexer.util;
/*
* Copyright © Schlumberger
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0 *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.opengroup.osdu.indexer.util;
import co.elastic.clients.elasticsearch.ElasticsearchClient;
import co.elastic.clients.elasticsearch._types.FieldValue;
......
{
"nested": {
"boost": 1.0,
"ignore_unmapped": true,
"path": "data.Configurations",
"query": {
"nested": {
"boost": 1.0,
"ignore_unmapped": true,
"path": "data.Configurations.Paths",
"query": {
"query_string": {
"boost": 1.0,
"allow_leading_wildcard": false,
"auto_generate_synonyms_phrase_query": true,
"default_operator": "or",
"enable_position_increments": true,
"escape": false,
"fields": [],
"fuzziness": "AUTO",
"fuzzy_max_expansions": 50,
"fuzzy_prefix_length": 0,
"fuzzy_transpositions": true,
"max_determinized_states": 10000,
"phrase_slop": 0.0,
"query": "data.Configurations.Paths.RelatedObjectsSpec.RelationshipDirection: ChildToParent AND data.Configurations.Paths.RelatedObjectsSpec.RelatedObjectKind:\"osdu:wks:master-data--Wellbore:1.\"",
"type": "best_fields"
}
},
"score_mode": "avg"
}
},
"score_mode": "avg"
}
}
{
"bool": {
"boost": 1.0,
"should": [{
"query_string": {
"boost": 1.0,
"allow_leading_wildcard": false,
"auto_generate_synonyms_phrase_query": true,
"default_operator": "or",
"enable_position_increments": true,
"escape": false,
"fields": [],
"fuzziness": "AUTO",
"fuzzy_max_expansions": 50,
"fuzzy_prefix_length": 0,
"fuzzy_transpositions": true,
"max_determinized_states": 10000,
"phrase_slop": 0.0,
"query": "data.Code: \"osdu:wks:work-product-component--WellLog:1.\"",
"type": "best_fields"
}
}, {
"nested": {
"boost": 1.0,
"ignore_unmapped": true,
"path": "data.Configurations",
"query": {
"nested": {
"boost": 1.0,
"ignore_unmapped": true,
"path": "data.Configurations.Paths",
"query": {
"query_string": {
"boost": 1.0,
"allow_leading_wildcard": false,
"auto_generate_synonyms_phrase_query": true,
"default_operator": "or",
"enable_position_increments": true,
"escape": false,
"fields": [],
"fuzziness": "AUTO",
"fuzzy_max_expansions": 50,
"fuzzy_prefix_length": 0,
"fuzzy_transpositions": true,
"max_determinized_states": 10000,
"phrase_slop": 0.0,
"query": "data.Configurations.Paths.RelatedObjectsSpec.RelatedObjectKind:\"osdu:wks:work-product-component--WellLog:1.\"",
"type": "best_fields"
}
},
"score_mode": "avg"
}
},
"score_mode": "avg"
}
}
]
}
}
{
"nested": {
"boost": 1.0,
"ignore_unmapped": true,
"path": "data.Configurations",
"query": {
"nested": {
"boost": 1.0,
"ignore_unmapped": true,
"path": "data.Configurations.Paths",
"query": {
"query_string": {
"boost": 1.0,
"allow_leading_wildcard": false,
"auto_generate_synonyms_phrase_query": true,
"default_operator": "or",
"enable_position_increments": true,
"escape": false,
"fields": [],
"fuzziness": "AUTO",
"fuzzy_max_expansions": 50,
"fuzzy_prefix_length": 0,
"fuzzy_transpositions": true,
"max_determinized_states": 10000,
"phrase_slop": 0.0,
"query": "data.Configurations.Paths.RelatedObjectsSpec.RelationshipDirection: ParentToChildren AND data.Configurations.Paths.RelatedObjectsSpec.RelatedObjectKind:\"osdu:wks:work-product-component--WellLog:1.\"",
"type": "best_fields"
}
},
"score_mode": "avg"
}
},
"score_mode": "avg"
}
}
{
"query_string": {
"boost": 1.0,
"allow_leading_wildcard": false,
"auto_generate_synonyms_phrase_query": true,
"default_operator": "or",
"enable_position_increments": true,
"escape": false,
"fields": [],
"fuzziness": "AUTO",
"fuzzy_max_expansions": 50,
"fuzzy_prefix_length": 0,
"fuzzy_transpositions": true,
"max_determinized_states": 10000,
"phrase_slop": 0.0,
"query": "id:(\"id1\" OR \"id2\")",
"type": "best_fields"
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment