@Override public void start(Future<Void> startFuture) throws Exception { Weld weld = this.weld != null ? this.weld : createDefaultWeld(); if (weld.getContainerId() == null) { weld.containerId(deploymentID()); } weld.addExtension(new VertxExtension(vertx, context)); configureWeld(weld); // Bootstrap can take some time to complete vertx.executeBlocking(future -> { try { this.weldContainer = weld.initialize(); future.complete(); } catch (Exception e) { future.fail(e); } }, result -> { if (result.succeeded()) { LOGGER.info("Weld verticle started for deployment {0}", deploymentID()); startFuture.complete(); } else { startFuture.fail(result.cause()); } }); }
@Override public void start(Future<Void> startFuture) throws Exception { Weld weld = this.weld != null ? this.weld : createDefaultWeld(); if (weld.getContainerId() == null) { weld.containerId(deploymentID()); } weld.addExtension(new VertxExtension(vertx, context)); configureWeld(weld); // Bootstrap can take some time to complete vertx.executeBlocking(future -> { try { this.weldContainer = weld.initialize(); future.complete(); } catch (Exception e) { future.fail(e); } }, result -> { if (result.succeeded()) { LOGGER.info("Weld verticle started for deployment {0}", deploymentID()); startFuture.complete(); } else { startFuture.fail(result.cause()); } }); }