public static void main(String[] args) throws Exception {
..int vertxWorkerPoolSize=40;
ClusterManager mgr = new HazelcastClusterManager();
VertxOptions options = new VertxOptions().setClusterManager(mgr);
options.setHAEnabled(true);
DeploymentOptions deploymentOptions = new DeploymentOptions().setConfig(config);
deploymentOptions.setHa(true);
Vertx.clusteredVertx(options, res -> {
if (res.succeeded()) {
Vertx vertx = res.result();
deployVerticles(context, deploymentOptions, vertx);
} else {
logger.error("Error initiating Vertx cluster", res.cause());
}
});
}
private static void deployVerticles(ApplicationContext context, DeploymentOptions deploymentOptions, Vertx vertx) {
vertx.deployVerticle(new FirstVerticle, deploymentOptions);
vertx.deployVerticle(new SecondVerticle, deploymentOptions);...}}
--
You received this message because you are subscribed to the Google Groups "vert.x" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vertx+un...@googlegroups.com.
Visit this group at https://groups.google.com/group/vertx.
To view this discussion on the web, visit https://groups.google.com/d/msgid/vertx/b39f8708-f634-42b0-a6e4-c6c6f65288b8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
To view this discussion on the web, visit https://groups.google.com/d/msgid/vertx/AEC1254C-1C99-457E-A01E-AA55C1706735%40gmail.com.
Tim,You can see exactly how many verticles I have deployed (I pasted my code) - which is one per verticle (FirstVerticle, SecondVerticle)
You suggest to to deploy more verticles and automatically ill have additional cpu's involved ? or should I provide u additional information to nail this.
-- You received this message because you are subscribed to the Google Groups "vert.x" group. To unsubscribe from this group and stop receiving emails from it, send an email to vertx+un...@googlegroups.com. Visit this group at https://groups.google.com/group/vertx. To view this discussion on the web, visit https://groups.google.com/d/msgid/vertx/7dcc55f7-3a8d-4bc5-8e35-50a8fe2a7a31%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
We'd need to know what these verticles do. Just deploying a verticle doesn't mean it will use any CPU, it completely depends on what the verticle does.
-- You received this message because you are subscribed to the Google Groups "vert.x" group. To unsubscribe from this group and stop receiving emails from it, send an email to vertx+un...@googlegroups.com. Visit this group at https://groups.google.com/group/vertx. To view this discussion on the web, visit https://groups.google.com/d/msgid/vertx/e9b8c111-6ca1-4f00-8749-4b79de489d04%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.