1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69
|
.TH "GEARMAN_CLIENT_JOB_STATUS" "3" "May 04, 2012" "0.33" "Gearmand"
.SH NAME
gearman_client_job_status \- Gearmand Documentation, http://gearman.info/
.
.nr rst2man-indent-level 0
.
.de1 rstReportMargin
\\$1 \\n[an-margin]
level \\n[rst2man-indent-level]
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
-
\\n[rst2man-indent0]
\\n[rst2man-indent1]
\\n[rst2man-indent2]
..
.de1 INDENT
.\" .rstReportMargin pre:
. RS \\$1
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
. nr rst2man-indent-level +1
.\" .rstReportMargin post:
..
.de UNINDENT
. RE
.\" indent \\n[an-margin]
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
.nr rst2man-indent-level -1
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.\" Man page generated from reStructeredText.
.
.SH SYNOPSIS
.sp
#include <libgearman/gearman.h>
.INDENT 0.0
.TP
.B gearman_return_t gearman_client_job_status(gearman_client_st\fI\ *client\fP, gearman_job_handle_t\fI\ job_handle\fP, bool\fI\ *is_known\fP, bool\fI\ *is_running\fP, uint32_t\fI\ *numerator\fP, uint32_t\fI\ *denominator\fP)
.UNINDENT
.sp
Link with \-lgearman
.SH DESCRIPTION
.sp
\fI\%gearman_client_job_status()\fP is used to find the status of a job via its \fBgearman_job_handle_t\fP. The arguments is_known, is_running, numerator, and denominator are all optional. Unless a Gearman worker has sent numerator/denominator via \fBgearman_job_send_status()\fP, those values will be zero.
.sp
If the arguments is_known and is_running are ommitted then the function returns state data via \fBgearman_return_t\fP.
.SH RETURN VALUE
.sp
\fBgearman_return_t\fP will be returned. \fBGEARMAN_SUCCESS\fP will be returned upon success of the status being updated.
If the arguments is_known and is_running are omitted then \fI\%gearman_client_job_status()\fP will return \fBGEARMAN_JOB_EXISTS\fP if the \fBgearman_job_handle_t\fP is known on the server, and
\fBGEARMAN_IN_PROGRESS\fP if it is running. Knowing whether the job is running or not has higher precedence. \fBgearman_continue()\fP can be used for loops where you want to exit from the loop once the job has been completed.
.IP Warning
For loops you should always check \fBgearman_return_t\fP with \fBgearman_continue()\fP even if you specifiy the argument is_known or is_running. A non\-blocking IO call can return something other then \fBGEARMAN_SUCCESS\fP, in some cases you will want to treat those values not as errors.
.RE
.SH HOME
.sp
To find out more information please check:
\fI\%http://gearman.info/\fP
.IP "See also"
.sp
\fIgearmand(8)\fP \fIlibgearman(3)\fP \fIgearman_client_st(3)\fP \fIgearman_job_handle_t(3)\fP \fIgearman_continue(3\fP
.RE
.SH AUTHOR
Data Differential http://www.datadifferential.com/
.SH COPYRIGHT
2012, Data Differential, http://www.datadifferential.com/
.\" Generated by docutils manpage writer.
.\"
.
|