--
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/73f83994-8537-4571-9e1f-40a3feb2ff41%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Hi,It’s probably a stupid idea but what about passing the vertx object or the eventbus object as parameter of your static function ?Clement
On 13 Oct 2016, at 09:49, gal.ch...@web-pick.com wrote:
Hello,I have a Vertx java application consisting of 7 Verticles.I need to access the event bus from all of the Verticles, a lot of the times from a static function.to do so, today, when a Verticle starts, we call a static function which stores the Vertx object in a static field,because of the class loader isolation, we do this in all 7 verticles.It works, but it looks awful, every time we want to access the event bus, we use VertxStatic.getVertx().eventBus().I wanted to ask if there is a more elegant solution you guys are using.Thanks,Gal.--
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/73f83994-8537-4571-9e1f-40a3feb2ff41%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.
To view this discussion on the web, visit https://groups.google.com/d/msgid/vertx/F72FFEF5-C3D2-4F02-9F5E-56AD1B60F677%40gmail.com.