Passing configuration to a verticle

Configuration in the form of Map can be passed to a verticle at deployment time:

def config = [
name:"tim",
directory:"/blah"
]
def options = [ "config" : config ];
vertx.deployVerticle("com.mycompany.MyOrderProcessorVerticle", options);

This configuration is then available via the Context, The configuration is returned as a Map object so you can retrieve data as follows:

println vertx.getOrCreateContext().config()["name"]
Note
The configuration can also be a JsonObject object.

Accessing environment variables in a Verticle

Environment variables and system properties are accessible using the Java API:

println System.getProperty("foo")
println System.getenv("HOME")