Open goodb opened 4 years ago
As @goodb suggested we can add an option to minerva-cli
to accept a config file like a YAML that controls all existing option settings like --import-owl-models
and --arachne
.
But I'm guessing this config-file
option should be optional, still allowing folks to manually set options on the command line? If yes, then given the scenario below:
# Snippet of example config file
ARACHNE: False
Running minerva with config and --arachne
option:
java minerva-cli.jar --config-file startup.yaml --arachne
How should the minerva-cli
option parser handle this conflict? Should the values in the config supersede the options explicitly set on the cmd line? Or the other way around?
CLI supersedes config: the most explicit intent in from of the user should be what's done to improve clarity.
@kltm Makes total sense to me. Thanks for clarifying!
I don't know, it seems like it would be cleaner to me to just limit all forms of user input to edits of the config file. This may be less convenient/important for the command line client, but it feels very right for the launch of the server.
What the balance is I'm happy to leave to others, but if there is a CLI, I believe it should override and config--the most explicit thing presented is the truth. That said, having things in a config makes things easy to control and share. In an ideal world, we would have both to suit our in-the-moment needs and desire for convenience...but we only have so much time to work on stuff... [Trivially, there should be at least a CLI flag for controlling the location of the config file. And help (-h).]
Launch configurations can get complex, especially with different ontology setups, catalogs etc. Migrating server settings from command line parameters to a (committed) configuration file will make it easier to manage, share and test work on the server (and work that depends on the server).