diff --git a/simulator-http/src/main/java/de/dentrassi/hono/simulator/http/Application.java b/simulator-http/src/main/java/de/dentrassi/hono/simulator/http/Application.java index 6ebf69a..d6a28e2 100644 --- a/simulator-http/src/main/java/de/dentrassi/hono/simulator/http/Application.java +++ b/simulator-http/src/main/java/de/dentrassi/hono/simulator/http/Application.java @@ -108,9 +108,10 @@ private static void runSimulator(final AppRuntime runtime) throws InterruptedExc final Tags commonTags = Tags.of( Tag.of("protocol", "http"), - Tag.of("tenant", Tenant.TENANT) + Tag.of("tenant", Tenant.TENANT), + config.getType().asTag() ); - final Statistics stats = new Statistics(registry, commonTags.and(config.getType().asTag())); + final Statistics stats = new Statistics(registry, commonTags); final ScheduledExecutorService statsExecutor = Executors.newSingleThreadScheduledExecutor(); // statsExecutor.scheduleAtFixedRate(Application::dumpStats, 1, 1, TimeUnit.SECONDS); diff --git a/simulator-mqtt/src/main/java/de/dentrassi/hono/simulator/mqtt/Application.java b/simulator-mqtt/src/main/java/de/dentrassi/hono/simulator/mqtt/Application.java index 1534c18..be1bca7 100644 --- a/simulator-mqtt/src/main/java/de/dentrassi/hono/simulator/mqtt/Application.java +++ b/simulator-mqtt/src/main/java/de/dentrassi/hono/simulator/mqtt/Application.java @@ -76,11 +76,12 @@ private static void run(final AppRuntime runtime) throws InterruptedException { final Tags commonTags = Tags.of( of("tenant", Tenant.TENANT), - of("protocol", "mqtt")); + of("protocol", "mqtt"), + config.getType().asTag()); final MeterRegistry metrics = runtime.getRegistry(); final AtomicLong connected = metrics.gauge("connections", commonTags, new AtomicLong()); - final Statistics stats = new Statistics(metrics, commonTags.and(config.getType().asTag())); + final Statistics stats = new Statistics(metrics, commonTags); try {