vert-x3 / vertx-examples

Vert.x examples
Apache License 2.0
3.55k stars 2.09k forks source link

initialize vertx instance #328

Closed NavyaZaveri closed 5 years ago

NavyaZaveri commented 5 years ago

As it stands, calling start() on a fresh instance of the Server() throws a null pointer exception because vertx is not initialized. This commit ensures that it is.

jponge commented 5 years ago

@NavyaZaveri The vertx instance is initialized by Vert.x as it deploys the verticle. Are you trying to create the object yourself and call start?

NavyaZaveri commented 5 years ago

Yes, I created the object myself and called start. Didn't realize there was a separate way to deploy the verticle, thanks!

jponge commented 5 years ago

No worries!