public class Launch
extends io.vertx.core.AbstractVerticle
Modifier and Type | Class and Description |
---|---|
static class |
Launch.ShutdownOptions
Options defining the behavior on Launch failure
|
Constructor and Description |
---|
Launch(java.lang.String paramConfigDir,
Launch.ShutdownOptions shutdownHow)
Default constructor for running system in Production
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getConfigDir() |
Launch.ShutdownOptions |
getShutdownOption() |
void |
handlerWebsockets(io.vertx.core.http.ServerWebSocket ws)
Handles incoming websocket requests for Eventbus tracking
|
static boolean |
isDebug()
Check if the application gets started in debug mode this will extend the loop timeout to avoid warnings of debugger blocking the event loop
|
static boolean |
isLocalMode(io.vertx.core.json.JsonObject aConfig) |
static io.vertx.core.Future<io.vertx.core.json.JsonObject> |
loadConfig(io.vertx.core.Vertx loaderVertx,
java.lang.String configDirName)
Loads the configuration from the internal configuration files and each JSON file that is in the configuration directory
|
static void |
main(java.lang.String[] args) |
static io.vertx.core.Future<Launch> |
restart(Launch oldLaunch)
Restarts Keep without shutting down the JVM.
|
java.lang.String |
runtime() |
static void |
runVerticle(Launch mainVerticle)
Starts a verticle to instantiate the whole system.
|
void |
start(io.vertx.core.Promise<java.lang.Void> startFuture) |
void |
stop(io.vertx.core.Promise<java.lang.Void> stopPromise) |
boolean |
validateShutdownRequest(io.vertx.core.json.JsonObject shutdownBody) |
public Launch(java.lang.String paramConfigDir, Launch.ShutdownOptions shutdownHow)
Default constructor for running system in Production
paramConfigDir
- shutdownHow
- Defines if JVM shall be terminated on program exitpublic static boolean isDebug()
Check if the application gets started in debug mode this will extend the loop timeout to avoid warnings of debugger blocking the event loop
public static boolean isLocalMode(io.vertx.core.json.JsonObject aConfig)
aConfig
- the configuration with the info we seekpublic static io.vertx.core.Future<io.vertx.core.json.JsonObject> loadConfig(io.vertx.core.Vertx loaderVertx, java.lang.String configDirName)
Loads the configuration from the internal configuration files and each JSON file that is in the configuration directory
loaderVertx
- configDirName
- public static void main(java.lang.String[] args)
args
- public static io.vertx.core.Future<Launch> restart(Launch oldLaunch)
Restarts Keep without shutting down the JVM. Reads new configuration
oldLaunch
- public static void runVerticle(Launch mainVerticle)
Starts a verticle to instantiate the whole system. Called from main()
mainVerticle
- the Launch verticle that loads everything elsepublic java.lang.String getConfigDir()
public Launch.ShutdownOptions getShutdownOption()
public void handlerWebsockets(io.vertx.core.http.ServerWebSocket ws)
Handles incoming websocket requests for Eventbus tracking
ws
- the websocketpublic java.lang.String runtime()
public void start(io.vertx.core.Promise<java.lang.Void> startFuture)
start
in interface io.vertx.core.Verticle
start
in class io.vertx.core.AbstractVerticle
public void stop(io.vertx.core.Promise<java.lang.Void> stopPromise)
stop
in interface io.vertx.core.Verticle
stop
in class io.vertx.core.AbstractVerticle
public boolean validateShutdownRequest(io.vertx.core.json.JsonObject shutdownBody)
shutdownBody
-