1Minion::Command::minionU:s:ewrorCkoenrt(r3i)buted Perl DMoicnuimoenn:t:aCtoimomnand::minion::worker(3)
2
3
4

NAME

6       Minion::Command::minion::worker - Minion worker command
7

SYNOPSIS

9         Usage: APPLICATION minion worker [OPTIONS]
10
11           ./myapp.pl minion worker
12           ./myapp.pl minion worker -f
13           ./myapp.pl minion worker -m production -I 15 -C 5 -R 3600 -j 10
14           ./myapp.pl minion worker -q important -q default
15
16         Options:
17           -C, --command-interval <seconds>     Worker remote control command interval,
18                                                defaults to 10
19           -D, dequeue-timeout <seconds>        Maximum amount of time to wait for
20                                                jobs, defaults to 5
21           -h, --help                           Show this summary of available options
22               --home <path>                    Path to home directory of your
23                                                application, defaults to the value of
24                                                MOJO_HOME or auto-detection
25           -I, --heartbeat-interval <seconds>   Heartbeat interval, defaults to 300
26           -j, --jobs <number>                  Maximum number of jobs to perform
27                                                parallel in forked worker processes,
28                                                defaults to 4
29           -m, --mode <name>                    Operating mode for your application,
30                                                defaults to the value of
31                                                MOJO_MODE/PLACK_ENV or "development"
32           -q, --queue <name>                   One or more queues to get jobs from,
33                                                defaults to "default"
34           -R, --repair-interval <seconds>      Repair interval, up to half of this
35                                                value can be subtracted randomly to
36                                                make sure not all workers repair at the
37                                                same time, defaults to 21600 (6 hours)
38

DESCRIPTION

40       Minion::Command::minion::worker starts a Minion worker. You can have as
41       many workers as you like.
42

SIGNALS

44       The Minion::Command::minion::worker process can be controlled at
45       runtime with the following signals.
46
47   INT, TERM
48       Stop gracefully after finishing the current jobs.
49
50   QUIT
51       Stop immediately without finishing the current jobs.
52

REMOTE CONTROL COMMANDS

54       The Minion::Command::minion::worker process can be controlled at
55       runtime through Minion::Command::minion::job, from anywhere in the
56       network, by broadcasting the following remote control commands.
57
58   jobs
59         $ ./myapp.pl minion job -b jobs -a '[10]'
60         $ ./myapp.pl minion job -b jobs -a '[10]' 23
61
62       Instruct one or more workers to change the number of jobs to perform
63       concurrently. Setting this value to 0 will effectively pause the
64       worker. That means all current jobs will be finished, but no new ones
65       accepted, until the number is increased again.
66
67   stop
68         $ ./myapp.pl minion job -b stop -a '[10025]'
69         $ ./myapp.pl minion job -b stop -a '[10025]' 23
70
71       Instruct one or more workers to stop a job that is currently being
72       performed immediately. This command will be ignored by workers that do
73       not have a job matching the id. That means it is safe to broadcast this
74       command to all workers.
75

ATTRIBUTES

77       Minion::Command::minion::worker inherits all attributes from
78       Mojolicious::Command and implements the following new ones.
79
80   description
81         my $description = $worker->description;
82         $worker         = $worker->description('Foo');
83
84       Short description of this command, used for the command list.
85
86   usage
87         my $usage = $worker->usage;
88         $worker   = $worker->usage('Foo');
89
90       Usage information for this command, used for the help screen.
91

METHODS

93       Minion::Command::minion::worker inherits all methods from
94       Mojolicious::Command and implements the following new ones.
95
96   run
97         $worker->run(@ARGV);
98
99       Run this command.
100

SEE ALSO

102       Minion, Mojolicious::Guides, <http://mojolicious.org>.
103
104
105
106perl v5.28.0                      2018-02-18Minion::Command::minion::worker(3)
Impressum