Run ProSA
Once you have created a binary using cargo-prosa
, the next step is to run this binary.
If you've installed a package or a container, you don't need to worry about the inner workings. However, if you want to execute the binary manually, this section explains the available parameters.
When you run prosa_binary -h
, you'll see output like the following:
Usage: prosa_binary [OPTIONS]
Options:
--dry_run Show how the ProSA will run but doesn't start it. Write the config file if it doesn't exist
-d, --daemon
-c, --config <CONFIG_PATH> Path of the ProSA configuration file [default: prosa.yml]
-n, --name <NAME> Name of the ProSA
--user <USER> User:Group to run the daemon ProSA
-l, --log_path <LOGPATH> Path of the output log
-t, --worker_threads <THREADS> Number of worker threads to use for the main [default: 1]
-h, --help Print help
-V, --version Print version
Based on this, you have several options:
- dry_run: Use this option to test your configuration file or create it if it doesn't exist.
- daemon: Run ProSA as a daemon. If you have configured stdout in your observability settings, a log file will be created.
- user: Useful for running ProSA as a daemon. This option allows you to specify the user under which the ProSA process will run.
- log_path: Also useful when running ProSA as a daemon. This option creates files in the specified folder where logs will be saved.
- config: Specify the path to your configuration folder/file.
- name: Override the name in your prosa settings. This sets the name of your ProSA instance.
- worker_threads: Specify the number of threads allocated for ProSA. Each processor can launch threads individually; thus, this option may have varying effects depending on your processor's capabilities.
- version: Provides information about the binary crate version as well as the versions of all components used. For example:
$ prosa_binary -V
prosa 0.1.0
$ prosa_binary --version
prosa 0.1.0 - core::main::MainProc = { crate = prosa, version = 0.2.0 }
inj
Processor: inj::proc::InjProc = { crate = prosa, version = 0.2.0 }
Adaptor : inj::adaptor::InjDummyAdaptor = { crate = prosa, version = 0.2.0 }
stub
Processor: stub::proc::StubProc = { crate = prosa, version = 0.2.0 }
Adaptor : stub::adaptor::StubParotAdaptor = { crate = prosa, version = 0.2.0 }