Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Return non-zero exit code if unable to start #35

Open
manics opened this issue Jul 1, 2019 · 0 comments
Open

Return non-zero exit code if unable to start #35

manics opened this issue Jul 1, 2019 · 0 comments

Comments

@manics
Copy link

manics commented Jul 1, 2019

omero-ms-image-region should exit with a non-zero status is an error is encountered during startup, e.g. invalid configuration, or invalid command line arguments. Currently (afec676) it exits with 0 implying success:

omero-ms@531b71dba100:~/omero-ms-image-region/bin$ ./omero-ms-image-region --invalid-args
2019-07-01 16:59:38,683 [vert.x-eventloop-thread-0] INFO  c.g.o.m.i.r.ImageRegionMicroserviceVerticle - Starting verticle
2019-07-01 16:59:38,989 [vert.x-eventloop-thread-0] INFO  c.g.o.m.i.r.ImageRegionMicroserviceVerticle - Deploying verticle
java.lang.IllegalArgumentException: 'omero.server' block missing from configuration
        at com.glencoesoftware.omero.ms.image.region.ImageRegionMicroserviceVerticle.deploy(ImageRegionMicroserviceVerticle.java:132)
        at com.glencoesoftware.omero.ms.image.region.ImageRegionMicroserviceVerticle$1.handle(ImageRegionMicroserviceVerticle.java:113)
        at com.glencoesoftware.omero.ms.image.region.ImageRegionMicroserviceVerticle$1.handle(ImageRegionMicroserviceVerticle.java:109)
        at io.vertx.config.impl.ConfigRetrieverImpl.lambda$getConfig$2(ConfigRetrieverImpl.java:180)
        at io.vertx.config.impl.ConfigRetrieverImpl.lambda$compute$9(ConfigRetrieverImpl.java:294)
        at io.vertx.core.impl.CompositeFutureImpl.lambda$all$1(CompositeFutureImpl.java:49)
        at io.vertx.core.impl.FutureImpl.tryComplete(FutureImpl.java:125)
        at io.vertx.config.impl.ConfigRetrieverImpl.lambda$null$6(ConfigRetrieverImpl.java:264)
        at io.vertx.config.impl.ConfigurationProvider.lambda$get$1(ConfigurationProvider.java:66)
        at io.vertx.core.impl.ContextImpl.lambda$null$0(ContextImpl.java:284)
        at io.vertx.core.impl.ContextImpl.executeTask(ContextImpl.java:320)
        at io.vertx.core.impl.EventLoopContext.lambda$executeAsync$0(EventLoopContext.java:38)
        at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:163)
        at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:404)
        at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:462)
        at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:897)
        at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
        at java.base/java.lang.Thread.run(Thread.java:834)
2019-07-01 16:59:39,014 [vert.x-eventloop-thread-1] ERROR i.v.c.i.l.c.VertxIsolatedDeployer - Failed in deploying verticle
java.lang.IllegalArgumentException: 'omero.server' block missing from configuration
        at com.glencoesoftware.omero.ms.image.region.ImageRegionMicroserviceVerticle.deploy(ImageRegionMicroserviceVerticle.java:132)
        at com.glencoesoftware.omero.ms.image.region.ImageRegionMicroserviceVerticle$1.handle(ImageRegionMicroserviceVerticle.java:113)
        at com.glencoesoftware.omero.ms.image.region.ImageRegionMicroserviceVerticle$1.handle(ImageRegionMicroserviceVerticle.java:109)
        at io.vertx.config.impl.ConfigRetrieverImpl.lambda$getConfig$2(ConfigRetrieverImpl.java:180)
        at io.vertx.config.impl.ConfigRetrieverImpl.lambda$compute$9(ConfigRetrieverImpl.java:294)
        at io.vertx.core.impl.CompositeFutureImpl.lambda$all$1(CompositeFutureImpl.java:49)
        at io.vertx.core.impl.FutureImpl.tryComplete(FutureImpl.java:125)
        at io.vertx.config.impl.ConfigRetrieverImpl.lambda$null$6(ConfigRetrieverImpl.java:264)
        at io.vertx.config.impl.ConfigurationProvider.lambda$get$1(ConfigurationProvider.java:66)
        at io.vertx.core.impl.ContextImpl.lambda$null$0(ContextImpl.java:284)
        at io.vertx.core.impl.ContextImpl.executeTask(ContextImpl.java:320)
        at io.vertx.core.impl.EventLoopContext.lambda$executeAsync$0(EventLoopContext.java:38)
        at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:163)
        at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:404)
        at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:462)
        at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:897)
        at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
        at java.base/java.lang.Thread.run(Thread.java:834)
java.lang.IllegalArgumentException: 'omero.server' block missing from configuration
        at com.glencoesoftware.omero.ms.image.region.ImageRegionMicroserviceVerticle.deploy(ImageRegionMicroserviceVerticle.java:132)
        at com.glencoesoftware.omero.ms.image.region.ImageRegionMicroserviceVerticle$1.handle(ImageRegionMicroserviceVerticle.java:113)
        at com.glencoesoftware.omero.ms.image.region.ImageRegionMicroserviceVerticle$1.handle(ImageRegionMicroserviceVerticle.java:109)
        at io.vertx.config.impl.ConfigRetrieverImpl.lambda$getConfig$2(ConfigRetrieverImpl.java:180)
        at io.vertx.config.impl.ConfigRetrieverImpl.lambda$compute$9(ConfigRetrieverImpl.java:294)
        at io.vertx.core.impl.CompositeFutureImpl.lambda$all$1(CompositeFutureImpl.java:49)
        at io.vertx.core.impl.FutureImpl.tryComplete(FutureImpl.java:125)
        at io.vertx.config.impl.ConfigRetrieverImpl.lambda$null$6(ConfigRetrieverImpl.java:264)
        at io.vertx.config.impl.ConfigurationProvider.lambda$get$1(ConfigurationProvider.java:66)
        at io.vertx.core.impl.ContextImpl.lambda$null$0(ContextImpl.java:284)
        at io.vertx.core.impl.ContextImpl.executeTask(ContextImpl.java:320)
        at io.vertx.core.impl.EventLoopContext.lambda$executeAsync$0(EventLoopContext.java:38)
        at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:163)
        at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:404)
        at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:462)
        at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:897)
        at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
        at java.base/java.lang.Thread.run(Thread.java:834)
omero-ms@531b71dba100:~/omero-ms-image-region/bin$ echo $?
0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant