I am using vertx version - 3.5.1. I want to track my logs in ELK, For that I am using elastic.apm.
I am initialising my co.elastic.apm.api.Transaction object in the beginning of the method. I want to carry forward this object to the other threads which we are calling using event bus.
Below is my code.
SharedData sharedData = vertx.sharedData();
LocalMap<String, co.elastic.apm.api.Transaction> map1 = sharedData.getLocalMap("mymap1");
map1.put("transaction", transaction);
I am getting below exception.
java.lang.IllegalArgumentException: Invalid type for shareddata data structure: co.elastic.apm.api.NoopTransaction
I tried putting in JsonObject as well. But no luck.
SharedData sharedData = vertx.sharedData();
LocalMap<String, co.elastic.apm.api.Transaction> map1 = sharedData.getLocalMap("mymap1");
map1.put("transaction", transaction);
I suppose this source Vert.x code describes wich types in this case is allowed: