~fractalcat/gearmand/docfixes

« back to all changes in this revision

Viewing changes to docs/man/gearman_continue.3

  • Committer: Brian Aker
  • Date: 2012-09-30 23:55:03 UTC
  • mto: (621.4.21 workspace)
  • mto: This revision was merged to the branch mainline in revision 656.
  • Revision ID: brian@tangent.org-20120930235503-u6r0uq1hl0mdj5an
Fix it so that we don't need to store the manpages in the tree.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
.TH "GEARMAN_CONTINUE" "3" "September 14, 2012" "0.38" "Gearmand"
2
 
.SH NAME
3
 
gearman_continue \- Gearmand Documentation, http://gearman.info/
4
 
.
5
 
.nr rst2man-indent-level 0
6
 
.
7
 
.de1 rstReportMargin
8
 
\\$1 \\n[an-margin]
9
 
level \\n[rst2man-indent-level]
10
 
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
11
 
-
12
 
\\n[rst2man-indent0]
13
 
\\n[rst2man-indent1]
14
 
\\n[rst2man-indent2]
15
 
..
16
 
.de1 INDENT
17
 
.\" .rstReportMargin pre:
18
 
. RS \\$1
19
 
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
20
 
. nr rst2man-indent-level +1
21
 
.\" .rstReportMargin post:
22
 
..
23
 
.de UNINDENT
24
 
. RE
25
 
.\" indent \\n[an-margin]
26
 
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
27
 
.nr rst2man-indent-level -1
28
 
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
29
 
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
30
 
..
31
 
.\" Man page generated from reStructeredText.
32
 
.
33
 
.SH SYNOPSIS
34
 
.sp
35
 
#include <libgearman/gearman.h>
36
 
.INDENT 0.0
37
 
.TP
38
 
.B gearman_return_t
39
 
.UNINDENT
40
 
.INDENT 0.0
41
 
.TP
42
 
.B const char *gearman_strerror(\fI\%gearman_return_t\fP\fI\ rc\fP)
43
 
.UNINDENT
44
 
.INDENT 0.0
45
 
.TP
46
 
.B bool gearman_success(\fI\%gearman_return_t\fP\fI\ rc\fP)
47
 
.UNINDENT
48
 
.INDENT 0.0
49
 
.TP
50
 
.B bool gearman_failed(\fI\%gearman_return_t\fP\fI\ rc\fP)
51
 
.UNINDENT
52
 
.INDENT 0.0
53
 
.TP
54
 
.B bool gearman_continue(\fI\%gearman_return_t\fP\fI\ rc\fP)
55
 
.UNINDENT
56
 
.sp
57
 
Compile and link with \-lgearman
58
 
.SH DESCRIPTION
59
 
.sp
60
 
\fI\%gearman_return_t\fP is used as a return/error type for all calls using \fBgearman_client_st\fP and \fBgearman_worker_st\fP.
61
 
\fI\%GEARMAN_SUCCESS\fP is returned upon success, otherwise an error is returned. \fI\%gearman_failed()\fP can be used to see if the return value is a failing value.
62
 
You can print a text version of the error message with \fI\%gearman_strerror()\fP.
63
 
.sp
64
 
\fI\%gearman_success()\fP return true if \fI\%GEARMAN_SUCCESS\fP or if
65
 
\fI\%GEARMAN_NO_PENDING_TASKS\fP tests true.
66
 
.sp
67
 
\fI\%gearman_failed()\fP return true if any value other then \fI\%GEARMAN_SUCCESS\fP was provided.
68
 
.sp
69
 
\fI\%gearman_continue()\fP returns true if any error related to non\-blocking IO
70
 
occurred. This should be used for testing loops.
71
 
.SS Possible values of \fI\%gearman_return_t\fP:
72
 
.INDENT 0.0
73
 
.TP
74
 
.B GEARMAN_SUCCESS
75
 
Success
76
 
.UNINDENT
77
 
.INDENT 0.0
78
 
.TP
79
 
.B GEARMAN_NO_PENDING_TASKS
80
 
\fBgearman_client_run_tasks()\fP was called and it has completed all tasks assigned to the client.
81
 
.UNINDENT
82
 
.INDENT 0.0
83
 
.TP
84
 
.B GEARMAN_IO_WAIT
85
 
Blocking IO was found. gearman_continue() can be used to test for this.
86
 
.UNINDENT
87
 
.INDENT 0.0
88
 
.TP
89
 
.B GEARMAN_ERRNO
90
 
System error occurred. Use either \fBgearman_client_errno()\fP or \fBgearman_worker_errno()\fP
91
 
.UNINDENT
92
 
.INDENT 0.0
93
 
.TP
94
 
.B GEARMAN_NO_ACTIVE_FDS
95
 
No active connections were available.  gearman_continue() can be used to test for this.
96
 
.UNINDENT
97
 
.INDENT 0.0
98
 
.TP
99
 
.B GEARMAN_GETADDRINFO
100
 
Name resolution failed for a host.
101
 
.UNINDENT
102
 
.INDENT 0.0
103
 
.TP
104
 
.B GEARMAN_NO_SERVERS
105
 
No servers have been provided for the client/worker.
106
 
.UNINDENT
107
 
.INDENT 0.0
108
 
.TP
109
 
.B GEARMAN_LOST_CONNECTION
110
 
Connection was lost to the given server.
111
 
.UNINDENT
112
 
.INDENT 0.0
113
 
.TP
114
 
.B GEARMAN_MEMORY_ALLOCATION_FAILURE
115
 
Memory allocation failed.
116
 
.UNINDENT
117
 
.INDENT 0.0
118
 
.TP
119
 
.B GEARMAN_SERVER_ERROR
120
 
An error occurred on the server.
121
 
.UNINDENT
122
 
.INDENT 0.0
123
 
.TP
124
 
.B GEARMAN_NOT_CONNECTED
125
 
Client/Worker is not currently connected to the server.
126
 
.UNINDENT
127
 
.INDENT 0.0
128
 
.TP
129
 
.B GEARMAN_COULD_NOT_CONNECT
130
 
Server name was valid, but a connection could not be made.
131
 
.UNINDENT
132
 
.INDENT 0.0
133
 
.TP
134
 
.B GEARMAN_ECHO_DATA_CORRUPTION
135
 
Either \fBgearman_client_echo()\fP or \fBgearman_worker_echo()\fP echo
136
 
was unsuccessful because the data was returned from \fBgearmand\fP
137
 
corrupted.
138
 
.UNINDENT
139
 
.INDENT 0.0
140
 
.TP
141
 
.B GEARMAN_UNKNOWN_STATE
142
 
The gearman_return_t was never set.
143
 
.UNINDENT
144
 
.INDENT 0.0
145
 
.TP
146
 
.B GEARMAN_FLUSH_DATA
147
 
Internal state, should never be seen by either client or worker.
148
 
.UNINDENT
149
 
.INDENT 0.0
150
 
.TP
151
 
.B GEARMAN_SEND_BUFFER_TOO_SMALL
152
 
Send buffer was too small.
153
 
.UNINDENT
154
 
.INDENT 0.0
155
 
.TP
156
 
.B GEARMAN_TIMEOUT
157
 
A timeout occurred when making a request to the server.
158
 
.UNINDENT
159
 
.INDENT 0.0
160
 
.TP
161
 
.B GEARMAN_ARGUMENT_TOO_LARGE
162
 
Argument was too large for the current buffer.
163
 
.UNINDENT
164
 
.INDENT 0.0
165
 
.TP
166
 
.B GEARMAN_INVALID_ARGUMENT
167
 
One of the arguments to the given API call was invalid. EINVAL will be set if \fBgearman_client_error()\fP or \fBgearman_worker_error()\fP were not settable. This can also be returned if \fBGEARMAN_CLIENT_UNBUFFERED_RESULT\fP was set, but the client is not handling the data correctly.
168
 
.UNINDENT
169
 
.SS CLIENT ONLY
170
 
.INDENT 0.0
171
 
.TP
172
 
.B GEARMAN_NEED_WORKLOAD_FN
173
 
A client was asked for work, but no \fBgearman_workload_fn\fP callback was specified. See \fBgearman_client_set_workload_fn()\fP
174
 
.UNINDENT
175
 
.INDENT 0.0
176
 
.TP
177
 
.B GEARMAN_WORK_FAIL
178
 
A task has failed, and the worker has exited with an error or it called \fBgearman_job_send_fail()\fP
179
 
.UNINDENT
180
 
.INDENT 0.0
181
 
.TP
182
 
.B GEARMAN_IN_PROGRESS
183
 
\fBgearman_client_job_status()\fP has been called for a \fBgearman_job_handle_t\fP and the Job is currently being run by a worker.
184
 
.UNINDENT
185
 
.INDENT 0.0
186
 
.TP
187
 
.B GEARMAN_JOB_EXISTS
188
 
\fBgearman_client_job_status()\fP has been called for a \fBgearman_job_handle_t\fP and the Job is currently known by a server, but is not being run by a worker.
189
 
.UNINDENT
190
 
.SS WORKER ONLY
191
 
.INDENT 0.0
192
 
.TP
193
 
.B GEARMAN_INVALID_FUNCTION_NAME
194
 
A worker was sent a request for a job that it did not have a valid function for.
195
 
.UNINDENT
196
 
.INDENT 0.0
197
 
.TP
198
 
.B GEARMAN_INVALID_WORKER_FUNCTION
199
 
No callback was provided by the worker for a given function.
200
 
.UNINDENT
201
 
.INDENT 0.0
202
 
.TP
203
 
.B GEARMAN_NO_REGISTERED_FUNCTION
204
 
A request for removing a given function from a worker was invalid since that function did not exist.
205
 
.UNINDENT
206
 
.INDENT 0.0
207
 
.TP
208
 
.B GEARMAN_NO_REGISTERED_FUNCTIONS
209
 
The worker has not registered any functions.
210
 
.UNINDENT
211
 
.INDENT 0.0
212
 
.TP
213
 
.B GEARMAN_NO_JOBS
214
 
No jobs were found for the worker.
215
 
.UNINDENT
216
 
.SS WORKER TO CLIENT
217
 
.sp
218
 
Client which have registed a custom \fBgearman_actions_t\fP may use these
219
 
value as return values to the calling client.
220
 
.INDENT 0.0
221
 
.TP
222
 
.B GEARMAN_WORK_DATA
223
 
Worker has sent a chunked piece of data to the client via \fBgearman_job_send_data()\fP
224
 
.UNINDENT
225
 
.INDENT 0.0
226
 
.TP
227
 
.B GEARMAN_WORK_WARNING
228
 
Worker has issued a warning to the client via \fBgearman_job_send_warning()\fP
229
 
.UNINDENT
230
 
.INDENT 0.0
231
 
.TP
232
 
.B GEARMAN_WORK_STATUS
233
 
Status has been updated by the worker via \fBgearman_job_send_status()\fP
234
 
.UNINDENT
235
 
.INDENT 0.0
236
 
.TP
237
 
.B GEARMAN_WORK_EXCEPTION
238
 
Worker has sent an exception the client via \fBgearman_job_send_exception()\fP
239
 
.UNINDENT
240
 
.INDENT 0.0
241
 
.TP
242
 
.B GEARMAN_WORK_FAIL
243
 
A task has failed, and the worker has exited with an error or it called \fBgearman_job_send_fail()\fP
244
 
.UNINDENT
245
 
.INDENT 0.0
246
 
.TP
247
 
.B GEARMAN_WORK_ERROR
248
 
A task has had an error and will be retried.
249
 
.UNINDENT
250
 
.INDENT 0.0
251
 
.TP
252
 
.B GEARMAN_PAUSE
253
 
Used only in custom application for client return based on \fI\%GEARMAN_WORK_DATA\fP, \fI\%GEARMAN_WORK_WARNING\fP, \fI\%GEARMAN_WORK_EXCEPTION\fP, \fI\%GEARMAN_WORK_FAIL\fP, or \fI\%GEARMAN_WORK_STATUS\fP. \fI\%gearman_continue()\fP can be used to check for this value.
254
 
.UNINDENT
255
 
.SS WORKER TO CLIENT
256
 
.sp
257
 
Any function defined by \fBgearman_worker_define_function()\fP may, and can only, return the following \fI\%gearman_return_t\fP values.
258
 
.INDENT 0.0
259
 
.TP
260
 
.B GEARMAN_SUCCESS
261
 
The function successfully completed the job.
262
 
.UNINDENT
263
 
.INDENT 0.0
264
 
.TP
265
 
.B GEARMAN_FATAL
266
 
.UNINDENT
267
 
.INDENT 0.0
268
 
.TP
269
 
.B GEARMAN_FAIL
270
 
The function failed to complete the job. \fI\%GEARMAN_FATAL\fP is the deprecated name for \fI\%GEARMAN_FAIL\fP
271
 
.UNINDENT
272
 
.INDENT 0.0
273
 
.TP
274
 
.B GEARMAN_ERROR
275
 
A task has had an error and will be retried.
276
 
.UNINDENT
277
 
.INDENT 0.0
278
 
.TP
279
 
.B GEARMAN_SHUTDOWN
280
 
\fI\%GEARMAN_SHUTDOWN\fP is a special case. If it is returned the client will be sent \fI\%GEARMAN_SUCCESS\fP, but \fBgearman_worker_work()\fP will exit with \fI\%GEARMAN_SHUTDOWN\fP.
281
 
.UNINDENT
282
 
.SS TASK ONLY
283
 
.INDENT 0.0
284
 
.TP
285
 
.B GEARMAN_NOT_FLUSHING
286
 
\fBgearman_task_send_workload()\fP failed, it was not in the correct state.
287
 
.UNINDENT
288
 
.INDENT 0.0
289
 
.TP
290
 
.B GEARMAN_DATA_TOO_LARGE
291
 
\fBgearman_task_send_workload()\fP failed, the data was too large to be sent.
292
 
.UNINDENT
293
 
.INDENT 0.0
294
 
.TP
295
 
.B GEARMAN_UNKNOWN_OPTION
296
 
Default state of task return value.
297
 
.UNINDENT
298
 
.SS PROTOCOL
299
 
.sp
300
 
If any of these errors occurred the connection will be dropped/reset.
301
 
.INDENT 0.0
302
 
.TP
303
 
.B GEARMAN_INVALID_MAGIC
304
 
.UNINDENT
305
 
.INDENT 0.0
306
 
.TP
307
 
.B GEARMAN_INVALID_COMMAND
308
 
.UNINDENT
309
 
.INDENT 0.0
310
 
.TP
311
 
.B GEARMAN_INVALID_PACKET
312
 
.UNINDENT
313
 
.INDENT 0.0
314
 
.TP
315
 
.B GEARMAN_UNEXPECTED_PACKET
316
 
.UNINDENT
317
 
.INDENT 0.0
318
 
.TP
319
 
.B GEARMAN_TOO_MANY_ARGS
320
 
.UNINDENT
321
 
.SS DEPRECATED
322
 
.INDENT 0.0
323
 
.TP
324
 
.B GEARMAN_IGNORE_PACKET
325
 
.UNINDENT
326
 
.INDENT 0.0
327
 
.TP
328
 
.B GEARMAN_MAX_RETURN
329
 
.UNINDENT
330
 
.SH SEE ALSO
331
 
.sp
332
 
\fIgearmand(8)\fP \fIlibgearman(3)\fP \fIgearman_client_error()\fP or \fIgearman_worker_error()\fP
333
 
.SH AUTHOR
334
 
Data Differential http://www.datadifferential.com/
335
 
.SH COPYRIGHT
336
 
2012, Data Differential, http://www.datadifferential.com/
337
 
.\" Generated by docutils manpage writer.
338
 
.\" 
339
 
.