Class ElasticsearchUtil
- java.lang.Object
-
- lumis.portal.bigdata.elasticsearch.ElasticsearchUtil
-
public abstract class ElasticsearchUtil extends Object
Utility methods for Elasticsearch big data implementation.- Since:
- 8.1.0
- Version:
- $Revision: 24561 $ $Date: 2021-06-25 11:01:24 -0300 (Fri, 25 Jun 2021) $
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ElasticsearchUtil.Client
Elasticsearch client-related operations.
-
Constructor Summary
Constructors Constructor Description ElasticsearchUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Map<String,Object>
convertFieldAndValuesToElasticsearch(Map<DocumentTypeField,Object> fieldValues)
Method responsable for perform the conversion ofDocumentTypeField
to the correct elasticsearch field, also this will convert the value to the right format.static Object
getValueInMapChain(String key, Map currentObject)
Returns event field value from the given object by your full key id.static List<Object>
getValuesInMapChain(String key, Object currentObject)
Returns event field values from the given object by your full key id.static void
putValueInMapChain(String key, Object value, Map map)
Create a chain of Maps and put the value in the most inner map.
-
-
-
Method Detail
-
getValueInMapChain
public static Object getValueInMapChain(String key, Map currentObject)
Returns event field value from the given object by your full key id.- Parameters:
key
- the event field identifier.currentObject
- the current object.- Returns:
- event value in chain map.
- Since:
- 12.2.0
-
getValuesInMapChain
public static List<Object> getValuesInMapChain(String key, Object currentObject)
Returns event field values from the given object by your full key id.- Parameters:
key
- the event field identifier.currentObject
- the current object.- Returns:
- event values in chain map.
- Since:
- 12.2.0
-
putValueInMapChain
public static void putValueInMapChain(String key, Object value, Map map)
Create a chain of Maps and put the value in the most inner map.- Parameters:
key
- the id of event for chain identifier.value
- the value to storemap
- the root chain.- Since:
- 12.0.0
-
convertFieldAndValuesToElasticsearch
public static Map<String,Object> convertFieldAndValuesToElasticsearch(Map<DocumentTypeField,Object> fieldValues)
Method responsable for perform the conversion ofDocumentTypeField
to the correct elasticsearch field, also this will convert the value to the right format.- Parameters:
fieldValues
- the map ofDocumentTypeField
and relative value.- Returns:
- the converted map to elasticsearch field and value.
- Since:
- 12.3.0
-
-