### Question:
SimpleQueryGeometryHandler implements QueryGeometryHandler { @Override public QueryGeometryResponse getQueryGeometryResponse(String id, List<? extends BaseQueryMetric> metrics) { QueryGeometryResponse response = new QueryGeometryResponse(id, basemaps); if (metrics != null) { Set<QueryGeometry> queryGeometries = new LinkedHashSet<>(); for (BaseQueryMetric metric : metrics) { try { boolean isLuceneQuery = isLuceneQuery(metric.getParameters()); String jexlQuery = (isLuceneQuery) ? toJexlQuery(metric.getQuery()) : metric.getQuery(); JexlNode queryNode = JexlASTHelper.parseAndFlattenJexlQuery(jexlQuery); queryGeometries.addAll(GeoFeatureVisitor.getGeoFeatures(queryNode, isLuceneQuery)); } catch (Exception e) { response.addException(new Exception("Unable to parse the geo features")); } } response.setResult(new ArrayList<>(queryGeometries)); } return response; }  @Override QueryGeometryResponse getQueryGeometryResponse(String id, List<? extends BaseQueryMetric> metrics); static boolean isGeoQuery(BaseQueryMetric metric);  }### Answer:
@Test public void multipleQueryMetricsTest() { List<QueryMetric> queryMetrics = new ArrayList<>(); QueryMetric qm = new QueryMetric(); qm.setQueryId(commonId); qm.setQuery("#COVERS(field1, 'POINT(1 1)')"); qm.setParameters(luceneParams); queryMetrics.add(qm); qm = new QueryMetric(); qm.setQueryId("special-snowflake-id"); qm.setQuery("geowave:intersects(field2, 'POINT(2 2)')"); qm.setParameters(jexlParams); queryMetrics.add(qm); QueryGeometryResponse resp = handler.getQueryGeometryResponse(commonId, queryMetrics); Assert.assertEquals(2, resp.getResult().size()); QueryGeometry queryGeometry = resp.getResult().get(0); Assert.assertEquals("{\"type\":\"Point\",\"coordinates\":[1,1]}", queryGeometry.getGeometry()); Assert.assertEquals("#COVERS(field1, 'POINT(1 1)')", queryGeometry.getFunction()); queryGeometry = resp.getResult().get(1); Assert.assertEquals("{\"type\":\"Point\",\"coordinates\":[2,2]}", queryGeometry.getGeometry()); Assert.assertEquals("geowave:intersects(field2, 'POINT(2 2)')", queryGeometry.getFunction()); System.out.println("done!"); }