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

Deamon Mode Exception at startup #109

Closed
quotschmacher opened this issue Feb 9, 2023 · 4 comments
Closed

Deamon Mode Exception at startup #109

quotschmacher opened this issue Feb 9, 2023 · 4 comments

Comments

@quotschmacher
Copy link

I got the validator running inside a Docker Container as a Daemon.

At Version 1.4.1 I started it using CMD ["java", "-jar", "validationtool-1.4.1-java8-standalone.jar", "-s", "scenarios.xml", "-D", "-P", "8080", "-H", "0.0.0.0"].

With Version 1.5.0 I get an exception:

kosit-2.0.0  | KoSIT Validator version 1.5.0
kosit-2.0.0  | java.lang.IllegalArgumentException: No repository location for scenario definition 'default_1' specified
kosit-2.0.0  |  at de.kosit.validationtool.cmd.Validator.findRepository(Validator.java:214)
kosit-2.0.0  |  at de.kosit.validationtool.cmd.Validator.lambda$getConfiguration$0(Validator.java:193)
kosit-2.0.0  |  at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
kosit-2.0.0  |  at java.util.HashMap$EntrySpliterator.forEachRemaining(HashMap.java:1699)
kosit-2.0.0  |  at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
kosit-2.0.0  |  at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:472)
kosit-2.0.0  |  at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)
kosit-2.0.0  |  at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
kosit-2.0.0  |  at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:566)
kosit-2.0.0  |  at de.kosit.validationtool.cmd.Validator.getConfiguration(Validator.java:200)
kosit-2.0.0  |  at de.kosit.validationtool.cmd.Validator.startDaemonMode(Validator.java:122)
kosit-2.0.0  |  at de.kosit.validationtool.cmd.Validator.mainProgram(Validator.java:84)
kosit-2.0.0  |  at de.kosit.validationtool.cmd.CommandLineOptions.call(CommandLineOptions.java:173)
kosit-2.0.0  |  at de.kosit.validationtool.cmd.CommandLineOptions.call(CommandLineOptions.java:40)
kosit-2.0.0  |  at picocli.CommandLine.executeUserObject(CommandLine.java:2041)
kosit-2.0.0  |  at picocli.CommandLine.access$1500(CommandLine.java:148)
kosit-2.0.0  |  at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2461)
kosit-2.0.0  |  at picocli.CommandLine$RunLast.handle(CommandLine.java:2453)
kosit-2.0.0  |  at picocli.CommandLine$RunLast.handle(CommandLine.java:2415)
kosit-2.0.0  |  at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2273)
kosit-2.0.0  |  at picocli.CommandLine$RunLast.execute(CommandLine.java:2417)
kosit-2.0.0  |  at picocli.CommandLine.execute(CommandLine.java:2170)
kosit-2.0.0  |  at de.kosit.validationtool.cmd.CommandLineApplication.mainProgram(CommandLineApplication.java:82)
kosit-2.0.0  |  at de.kosit.validationtool.cmd.CommandLineApplication.main(CommandLineApplication.java:54)
kosit-2.0.0  | No repository location for scenario definition default_1 specified
kosit-2.0.0  | Usage: KoSIT Validator [-?dX] [-l <logLevel>] [-r repository-path]... -s
kosit-2.0.0  |                        scenario.xml [-s scenario.xml]... [[-D] [-H <host>] [-P
kosit-2.0.0  |                        <port>] [-T <workerCount>] [-G]] [[-o <outputPath>] [-h]
kosit-2.0.0  |                        [--serialize-report-input] [-c assertions-file]
kosit-2.0.0  |                        [--report-postfix <reportPostfix>] [--report-prefix
kosit-2.0.0  |                        <reportPrefix>] [-m] [-p] <files>...]
kosit-2.0.0  | Structural and semantic validation of xml files
kosit-2.0.0  |   -?, --help            display this help message
kosit-2.0.0  |   -d, --debug           Prints some more debug information
kosit-2.0.0  |   -l, --log-level <logLevel>
kosit-2.0.0  |                         Enables a certain log level for debugging purposes
kosit-2.0.0  |   -r, --repository repository-path
kosit-2.0.0  |                         Directory containing scenario content
kosit-2.0.0  |   -s, --scenarios scenario.xml
kosit-2.0.0  |                         Location of scenarios.xml
kosit-2.0.0  |   -X, --debug-logging   Enables full debug log. Alias for -l debug
kosit-2.0.0  | Daemon options
kosit-2.0.0  |   -D, --daemon          Starts a daemon listing for validation requests
kosit-2.0.0  |   -G, --disable-gui     Disables the GUI of the daemon mode
kosit-2.0.0  |   -H, --host <host>     The hostname / IP address to bind the daemon.
kosit-2.0.0  |                           Default: localhost
kosit-2.0.0  |   -P, --port <port>     The port to bind the daemon.
@apenski
Copy link
Collaborator

apenski commented Feb 10, 2023

well, a regression due to new multiple configuration support. Can you please try to specify a repository e.g. -r my-repo

@quotschmacher
Copy link
Author

so you mean specify an online repository? i am not sure what to use as a repo, when i already downloaded a scenario.xml

@SemikolonDEV
Copy link

try it with an additional parameter -r ""

@quotschmacher
Copy link
Author

thanks a lot @SemikolonDEV - using CMD ["java", "-jar", "validationtool-1.5.0-java8-standalone.jar", "-s", "scenarios.xml", "-D", "-P", "8080", "-H", "0.0.0.0", "-r", ""] it worked as expected

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

3 participants