--
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+unsubscribe@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/96267126-1214-45ae-b885-c3f8c29d80f3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Vert.x does exactly that when shut down correctly.Make sure that instances are taken down correctly so vert.x can unsubscribe from the cluster.Vert.x doesn't have a chance to deregister from Hazelcast if the JVM is simply killed.There has been a discussion on this topic quite recently, search the list.
2016-10-20 9:26 GMT+02:00 Jonas Bergström <lucky...@gmail.com>:
Hi all,We're running about 20 vert.x instances with different business logic in them, typically two or three instances per service type. Each service has 2-5 verticals deployed.When we do rolling upgrades (take one service instance down, bring the new version up, until all instances are replaced) we often get error logs from hazelcast and subs map inconsistencies. Which eventually sorts itself out, but meanwhile we get a number of failing requests.So the question is, what is the proper procedure for rolling upgrades? Should we do it in another way?What we would like is that vertx supports some sort of two-step shutdown procedure so we can take a running instance out of service before shutting it down. I'e unregister verticals so no more messages are delivered and wait until all ongoing messages have been handled, and disconnect from hazelcast. And then we can take down the instance.Is there a way to implement that today?BR / Jonas
--
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/96267126-1214-45ae-b885-c3f8c29d80f3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
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+unsubscribe@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/a15f9b61-681f-4830-bb87-a9c55440413b%40googlegroups.com.
public class Proxy extends AbstractVerticle {
@Override
public void start(Future<Void> fut) {
vertx
.createHttpServer()
.requestHandler(
request ->
vertx.eventBus().send("ping", null, new DeliveryOptions().setSendTimeout(1000),
response ->
{
if (response.succeeded())
request.response().end("<h1>Got pong</h1>");
else
request.response().setStatusCode(500).end("<h1>Got error</h1>");
}))
.listen(8080, result -> {
if (result.succeeded()) {
fut.complete();
} else {
fut.fail(result.cause());
}
});
}
}
public class Service extends AbstractVerticle {
@Override
public void start(Future<Void> fut)
{
vertx.eventBus().consumer("ping", message -> message.reply("pong"));
}
}
--
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+unsubscribe@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/d2aa51d8-05e8-410b-ab6c-a866e1debec6%40googlegroups.com.
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/d2aa51d8-05e8-410b-ab6c-a866e1debec6%40googlegroups.com.