2019-07-25 14:32:31 -04:00
|
|
|
[role="xpack"]
|
|
|
|
[testenv="gold+"]
|
|
|
|
[[elasticsearch-croneval]]
|
|
|
|
== elasticsearch-croneval
|
|
|
|
|
2020-05-12 19:36:18 -04:00
|
|
|
Validates and evaluates a <<cron-expressions,cron expression>>.
|
2019-07-25 14:32:31 -04:00
|
|
|
|
|
|
|
[discrete]
|
|
|
|
=== Synopsis
|
|
|
|
|
|
|
|
[source,shell]
|
|
|
|
--------------------------------------------------
|
|
|
|
bin/elasticsearch-croneval <expression>
|
|
|
|
[-c, --count <integer>] [-h, --help]
|
|
|
|
([-s, --silent] | [-v, --verbose])
|
|
|
|
--------------------------------------------------
|
|
|
|
|
|
|
|
[discrete]
|
|
|
|
=== Description
|
|
|
|
|
|
|
|
This command enables you to verify that your
|
2020-05-12 19:36:18 -04:00
|
|
|
cron expressions are valid for use with
|
|
|
|
{es} and produce the expected results.
|
2019-07-25 14:32:31 -04:00
|
|
|
|
|
|
|
This command is provided in the `$ES_HOME/bin` directory.
|
|
|
|
|
|
|
|
=== Parameters
|
|
|
|
|
|
|
|
`-c, --count` <Integer>::
|
|
|
|
The number of future times this expression will be triggered. The default
|
|
|
|
value is `10`.
|
2020-01-02 18:57:51 -05:00
|
|
|
|
|
|
|
`-d, --detail`::
|
|
|
|
Shows detail for invalid cron expression. It will print the stacktrace if the
|
|
|
|
expression is not valid.
|
|
|
|
|
2019-07-25 14:32:31 -04:00
|
|
|
`-h, --help`::
|
|
|
|
Returns all of the command parameters.
|
|
|
|
|
|
|
|
`-s, --silent`::
|
|
|
|
Shows minimal output.
|
|
|
|
|
|
|
|
`-v, --verbose`::
|
|
|
|
Shows verbose output.
|
|
|
|
|
|
|
|
[discrete]
|
2020-05-12 19:36:18 -04:00
|
|
|
=== Example
|
2019-07-25 14:32:31 -04:00
|
|
|
|
|
|
|
If the cron expression is valid, the following command displays the next
|
|
|
|
20 times that the schedule will be triggered:
|
|
|
|
|
|
|
|
[source,bash]
|
|
|
|
--------------------------------------------------
|
|
|
|
bin/elasticsearch-croneval "0 0/1 * * * ?" -c 20
|
|
|
|
--------------------------------------------------
|