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

Use named parameters in command line interface #3

Closed
aecio opened this issue May 27, 2015 · 1 comment
Closed

Use named parameters in command line interface #3

aecio opened this issue May 27, 2015 · 1 comment

Comments

@aecio
Copy link
Member

aecio commented May 27, 2015

Currently, ache is started using a command line interface with fixed parameters like this:

ache startCrawl <data output path> <config path> <seed path> <model path> <lang detect profile path>

Command line should be modified to accept named parameters:

ache startCrawl --data-output <data output path> --config-path <config path> --seed-path <seed path> --model-path <model path> --lang-profile <lang detect profile path>

All ACHE command should accept named parameters, namely:

ache startCrawl
ache addSeeds
ache buildModel
ache startLinkStorage
ache startTargetStorage
ache startCrawlManager

It's also desirable that parameters can have a short form:
--data-output or -o
--model-path or -m
--lang-profileor -l

This feature should be implemented using a library like argparse4j (http://argparse4j.sourceforge.net) or Apache Commons CLI (https://commons.apache.org/proper/commons-cli/).

This feature is important to allow optional parameters be added in the future without breaking clients that are using the interface. For instance, ElasticSearch integration will need this feature to setup index name when ElasticSearch is used as TargetStorage backend.

@aecio
Copy link
Member Author

aecio commented Jun 11, 2015

Fixed in commit 52ab094

@aecio aecio closed this as completed Jun 11, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant