~vjsamuel/gearmand/fix-bug-868883

« back to all changes in this revision

Viewing changes to docs/man/gearman_failed.3

  • Committer: Brian Aker
  • Date: 2011-06-29 20:30:46 UTC
  • mfrom: (440.1.11 gearmand-trunk)
  • Revision ID: brian@tangent.org-20110629203046-rtwa0eme3360be9i
Updating for release .23

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
.TH "GEARMAN_FAILED" "3" "June 21, 2011" "0.22" "Gearmand"
 
1
.TH "GEARMAN_FAILED" "3" "June 29, 2011" "0.22" "Gearmand"
2
2
.SH NAME
3
3
gearman_failed \- Gearmand Documentation, http://gearman.info/
4
4
.
68
68
.sp
69
69
\fI\%gearman_continue()\fP returns true if any error related to non\-blocking IO
70
70
occurred. This should be used for testing loops.
71
 
.sp
72
 
Possible values of \fI\%gearman_return_t\fP:
 
71
.SS Possible values of \fI\%gearman_return_t\fP:
73
72
.INDENT 0.0
74
73
.TP
75
74
.B GEARMAN_SUCCESS
76
 
.UNINDENT
77
 
.sp
 
75
.
78
76
Success
 
77
.UNINDENT
79
78
.INDENT 0.0
80
79
.TP
81
80
.B GEARMAN_NO_PENDING_TASKS
82
 
.UNINDENT
83
 
.sp
 
81
.
84
82
\fBgearman_client_run_tasks()\fP was called and it has completed all tasks assigned to the client.
 
83
.UNINDENT
85
84
.INDENT 0.0
86
85
.TP
87
86
.B GEARMAN_IO_WAIT
 
87
.
 
88
Blocking IO was found. gearman_continue() can be used to test for this.
88
89
.UNINDENT
89
 
.sp
90
 
Blocking IO was found. gearman_continue() can be used to
91
 
test for this.
92
90
.INDENT 0.0
93
91
.TP
94
92
.B GEARMAN_ERRNO
95
 
.UNINDENT
96
 
.sp
 
93
.
97
94
System error occurred. Use either \fBgearman_client_errno()\fP or \fBgearman_worker_errno()\fP
 
95
.UNINDENT
98
96
.INDENT 0.0
99
97
.TP
100
98
.B GEARMAN_NO_ACTIVE_FDS
101
 
.UNINDENT
102
 
.sp
 
99
.
103
100
No active connections were available.  gearman_continue() can be used to test for this.
 
101
.UNINDENT
104
102
.INDENT 0.0
105
103
.TP
106
104
.B GEARMAN_GETADDRINFO
107
 
.UNINDENT
108
 
.sp
 
105
.
109
106
Name resolution failed for a host.
 
107
.UNINDENT
110
108
.INDENT 0.0
111
109
.TP
112
110
.B GEARMAN_NO_SERVERS
113
 
.UNINDENT
114
 
.sp
 
111
.
115
112
No servers have been provided for the client/worker.
 
113
.UNINDENT
116
114
.INDENT 0.0
117
115
.TP
118
116
.B GEARMAN_LOST_CONNECTION
119
 
.UNINDENT
120
 
.sp
 
117
.
121
118
Connection was lost to the given server.
 
119
.UNINDENT
122
120
.INDENT 0.0
123
121
.TP
124
122
.B GEARMAN_MEMORY_ALLOCATION_FAILURE
125
 
.UNINDENT
126
 
.sp
 
123
.
127
124
Memory allocation failed.
 
125
.UNINDENT
128
126
.INDENT 0.0
129
127
.TP
130
128
.B GEARMAN_SERVER_ERROR
131
 
.UNINDENT
132
 
.sp
 
129
.
133
130
An error occurred on the server.
 
131
.UNINDENT
134
132
.INDENT 0.0
135
133
.TP
136
134
.B GEARMAN_NOT_CONNECTED
 
135
.
 
136
Client/Worker is not currently connected to the server.
137
137
.UNINDENT
138
 
.sp
139
 
Client/Worker is not currently connected to the
140
 
server.
141
138
.INDENT 0.0
142
139
.TP
143
140
.B GEARMAN_COULD_NOT_CONNECT
 
141
.
 
142
Server name was valid, but a connection could not be made.
144
143
.UNINDENT
145
 
.sp
146
 
Server name was valid, but a connection could not
147
 
be made.
148
144
.INDENT 0.0
149
145
.TP
150
146
.B GEARMAN_ECHO_DATA_CORRUPTION
 
147
.
 
148
Either \fBgearman_client_echo()\fP or \fBgearman_work_echo()\fP echo was unsuccessful because the data was returned from \fBgearmand\fP corrupted.
151
149
.UNINDENT
152
 
.sp
153
 
Either \fBgearman_client_echo()\fP or
154
 
\fBgearman_work_echo()\fP echo was unsuccessful because the data was returned from \fBgearmand\fP corrupted.
155
150
.INDENT 0.0
156
151
.TP
157
152
.B GEARMAN_UNKNOWN_STATE
158
 
.UNINDENT
159
 
.sp
 
153
.
160
154
The gearman_return_t was never set.
 
155
.UNINDENT
161
156
.INDENT 0.0
162
157
.TP
163
158
.B GEARMAN_FLUSH_DATA
164
 
.UNINDENT
165
 
.sp
 
159
.
166
160
Internal state, should never be seen by either client or worker.
 
161
.UNINDENT
167
162
.INDENT 0.0
168
163
.TP
169
164
.B GEARMAN_SEND_BUFFER_TOO_SMALL
170
 
.UNINDENT
171
 
.sp
 
165
.
172
166
Send buffer was too small.
 
167
.UNINDENT
173
168
.INDENT 0.0
174
169
.TP
175
170
.B GEARMAN_TIMEOUT
176
 
.UNINDENT
177
 
.sp
 
171
.
178
172
A timeout occurred when making a request to the server.
 
173
.UNINDENT
179
174
.INDENT 0.0
180
175
.TP
181
176
.B GEARMAN_ARGUMENT_TOO_LARGE
182
 
.UNINDENT
183
 
.sp
 
177
.
184
178
Argument was too large for the current buffer.
 
179
.UNINDENT
185
180
.INDENT 0.0
186
181
.TP
187
182
.B GEARMAN_INVALID_ARGUMENT
 
183
.
 
184
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.
188
185
.UNINDENT
189
 
.sp
190
 
One of the arguments to the given API call was invalid. EINVAL will be set
191
 
if \fBgearman_client_error()\fP or \fBgearman_worker_error()\fP were
192
 
not settable. This can also be returned if
193
 
\fBGEARMAN_CLIENT_UNBUFFERED_RESULT\fP was set, but the client is not
194
 
handling the data correctly.
195
186
.SS CLIENT ONLY
196
187
.INDENT 0.0
197
188
.TP
198
189
.B GEARMAN_NEED_WORKLOAD_FN
 
190
.
 
191
A client was asked for work, but no \fBgearman_workload_fn\fP callback was specified. See \fBgearman_client_set_workload_fn()\fP
199
192
.UNINDENT
200
 
.sp
201
 
A client was asked for work, but no \fBgearman_workload_fn\fP callback was
202
 
specified. See \fBgearman_client_set_workload_fn()\fP
203
193
.INDENT 0.0
204
194
.TP
205
195
.B GEARMAN_WORK_FAIL
206
 
.UNINDENT
207
 
.sp
 
196
.
208
197
A task has failed, and the worker has exited with an error or it called \fBgearman_job_send_fail()\fP
 
198
.UNINDENT
209
199
.INDENT 0.0
210
200
.TP
211
201
.B GEARMAN_IN_PROGRESS
212
 
.UNINDENT
213
 
.sp
 
202
.
214
203
\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.
 
204
.UNINDENT
215
205
.INDENT 0.0
216
206
.TP
217
207
.B GEARMAN_JOB_EXISTS
218
 
.UNINDENT
219
 
.sp
 
208
.
220
209
\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.
 
210
.UNINDENT
221
211
.SS WORKER ONLY
222
212
.INDENT 0.0
223
213
.TP
224
214
.B GEARMAN_INVALID_FUNCTION_NAME
225
 
.UNINDENT
226
 
.sp
 
215
.
227
216
A worker was sent a request for a job that it did not have a valid function for.
 
217
.UNINDENT
228
218
.INDENT 0.0
229
219
.TP
230
220
.B GEARMAN_INVALID_WORKER_FUNCTION
231
 
.UNINDENT
232
 
.sp
 
221
.
233
222
No callback was provided by the worker for a given function.
 
223
.UNINDENT
234
224
.INDENT 0.0
235
225
.TP
236
226
.B GEARMAN_NO_REGISTERED_FUNCTION
237
 
.UNINDENT
238
 
.sp
 
227
.
239
228
A request for removing a given function from a worker was invalid since that function did not exist.
 
229
.UNINDENT
240
230
.INDENT 0.0
241
231
.TP
242
232
.B GEARMAN_NO_REGISTERED_FUNCTIONS
243
 
.UNINDENT
244
 
.sp
 
233
.
245
234
The worker has not registered any functions.
 
235
.UNINDENT
246
236
.INDENT 0.0
247
237
.TP
248
238
.B GEARMAN_NO_JOBS
249
 
.UNINDENT
250
 
.sp
 
239
.
251
240
No jobs were found for the worker.
 
241
.UNINDENT
252
242
.SS WORKER TO CLIENT
253
243
.sp
254
244
Client which have registed a custom \fBgearman_actions_t\fP may use these
256
246
.INDENT 0.0
257
247
.TP
258
248
.B GEARMAN_WORK_DATA
259
 
.UNINDENT
260
 
.sp
 
249
.
261
250
Worker has sent a chunked piece of data to the client via \fBgearman_job_send_data()\fP
 
251
.UNINDENT
262
252
.INDENT 0.0
263
253
.TP
264
254
.B GEARMAN_WORK_WARNING
265
 
.UNINDENT
266
 
.sp
 
255
.
267
256
Worker has issued a warning to the client via \fBgearman_job_send_warning()\fP
 
257
.UNINDENT
268
258
.INDENT 0.0
269
259
.TP
270
260
.B GEARMAN_WORK_STATUS
271
 
.UNINDENT
272
 
.sp
 
261
.
273
262
Status has been updated by the worker via \fBgearman_job_send_status()\fP
 
263
.UNINDENT
274
264
.INDENT 0.0
275
265
.TP
276
266
.B GEARMAN_WORK_EXCEPTION
277
 
.UNINDENT
278
 
.sp
 
267
.
279
268
Worker has sent an exception the client via \fBgearman_job_send_exception()\fP
 
269
.UNINDENT
280
270
.INDENT 0.0
281
271
.TP
282
272
.B GEARMAN_WORK_FAIL
283
 
.UNINDENT
284
 
.sp
 
273
.
285
274
A task has failed, and the worker has exited with an error or it called \fBgearman_job_send_fail()\fP
 
275
.UNINDENT
286
276
.INDENT 0.0
287
277
.TP
288
278
.B GEARMAN_WORK_ERROR
 
279
.
 
280
A task has had an error and will be retried.
289
281
.UNINDENT
290
 
.sp
291
 
A task has had an error and will be retried.
292
282
.INDENT 0.0
293
283
.TP
294
284
.B GEARMAN_PAUSE
295
 
.UNINDENT
296
 
.sp
 
285
.
297
286
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.
 
287
.UNINDENT
298
288
.SS WORKER TO CLIENT
299
289
.sp
300
290
Any function defined by \fBgearman_worker_define_function()\fP may, and can only, return the following \fI\%gearman_return_t\fP values.
301
291
.INDENT 0.0
302
292
.TP
303
293
.B GEARMAN_SUCCESS
304
 
.UNINDENT
305
 
.sp
 
294
.
306
295
The function successfully completed the job.
 
296
.UNINDENT
307
297
.INDENT 0.0
308
298
.TP
309
299
.B GEARMAN_FATAL
310
 
.UNINDENT
311
 
.sp
 
300
.
312
301
The function failed to complete the job.
 
302
.UNINDENT
313
303
.INDENT 0.0
314
304
.TP
315
305
.B GEARMAN_ERROR
 
306
.
 
307
A task has had an error and will be retried.
316
308
.UNINDENT
317
 
.sp
318
 
A task has had an error and will be retried.
319
309
.INDENT 0.0
320
310
.TP
321
311
.B GEARMAN_SHUTDOWN
 
312
.
 
313
\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.
322
314
.UNINDENT
323
 
.sp
324
 
\fI\%GEARMAN_SHUTDOWN\fP is a special case. If it is returned the client
325
 
will be sent \fI\%GEARMAN_SUCCESS\fP, but \fBgearman_worker_work()\fP
326
 
will exit with \fI\%GEARMAN_SHUTDOWN\fP.
327
315
.SS TASK ONLY
328
316
.INDENT 0.0
329
317
.TP
330
318
.B GEARMAN_NOT_FLUSHING
331
 
.UNINDENT
332
 
.sp
 
319
.
333
320
\fBgearman_task_send_workload()\fP failed, it was not in the correct state.
 
321
.UNINDENT
334
322
.INDENT 0.0
335
323
.TP
336
324
.B GEARMAN_DATA_TOO_LARGE
337
 
.UNINDENT
338
 
.sp
 
325
.
339
326
\fBgearman_task_send_workload()\fP failed, the data was too large to be sent.
 
327
.UNINDENT
340
328
.SS PROTOCOL
341
329
.sp
342
330
If any of these errors occurred the connection will be dropped/reset.