for (Vertex vertex : dendriteGraphTx.query().limit(300).vertices()) {
addVertex(verticesMap, vertex);
}
for (Edge edge : dendriteGraphTx.query().limit(300).edges()) {
addEdge(verticesMap, edgesMap, edge);
}
response.put("vertices", new ArrayList<>(verticesMap.values()));
response.put("edges", new ArrayList<>(edgesMap.values()));