@@ -151,16 +151,16 @@ protected void transformSelectorDefinition(
151151
152152 private List <ColumnMetadata > getIndexColumnsMetadata (String indexName )
153153 throws IOException {
154- String [] indexNameArray = StringUtils .split (indexName ,"," );
154+ String [] indexNameArray = StringUtils .split (indexName , "," );
155155 List <String > columnNames = new ArrayList <>();
156- for (String index : indexNameArray ) {
156+ for (String index : indexNameArray ) {
157157 Request request = new Request ("GET" , index );
158158 Response response = httpClient .performRequest (request );
159159 String data = EntityUtils .toString (response .getEntity ());
160160 JsonParser jsonParser = new JsonParser ();
161161 JsonObject root = (JsonObject ) jsonParser .parse (data );
162- JsonObject properties = root .get (index ).getAsJsonObject ()
163- .get ( "mappings" ). getAsJsonObject ().get ("properties" ).getAsJsonObject ();
162+ JsonObject properties = root .get (index ).getAsJsonObject (). get ( "mappings" )
163+ .getAsJsonObject ().get ("properties" ).getAsJsonObject ();
164164
165165 properties .entrySet ();
166166 for (Map .Entry <String , JsonElement > map : properties .entrySet ()) {
@@ -337,8 +337,8 @@ protected Operand[] buildColumnOperands(
337337 String value = columnMetadata .getValue ();
338338 int index = value .indexOf ('(' );
339339 if (index == -1 ) {
340- index = value .indexOf ('.' );
341- value = value .substring (index + 1 );
340+ // index = value.indexOf('.');
341+ // value = value.substring(index + 1);
342342 } else {
343343 value = getAggregationFunctionExpression (columnMetadata );
344344 }
@@ -370,6 +370,7 @@ protected EntityMap toQueryEntityMap(JsonObject jsonObject) {
370370 return new EntityMapImpl (record );
371371 }
372372
373+
373374 protected void toMap (JsonObject jsonObject , Map <String , Object > record ) {
374375 for (Map .Entry <String , JsonElement > entry : jsonObject .entrySet ()) {
375376 if (entry .getKey ().equals ("_source" )) {
@@ -379,10 +380,7 @@ protected void toMap(JsonObject jsonObject, Map<String, Object> record) {
379380 Object value = entry .getValue ();
380381 if (entry .getValue () instanceof JsonPrimitive ) {
381382 value = getValue ((JsonPrimitive ) entry .getValue ());
382- } else {
383- value = entry .getValue ().toString ();
384383 }
385-
386384 record .put (entry .getKey (), value );
387385 }
388386 }
0 commit comments