.\" Man page generated from reStructuredText. . .TH "GEARMAN_CLIENT_DO_HIGH_BACKGROUND" "3" "Mar 29, 2020" "1.1.19.1+ds" "Gearmand" .SH NAME gearman_client_do_high_background \- 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 .. .SH SYNOPSIS .sp #include .INDENT 0.0 .TP .B gearman_priority_t .UNINDENT .INDENT 0.0 .TP .B gearman_return_t gearman_client_do_background(gearman_client_st\fI\ *client\fP, const char\fI\ *function_name\fP, const char\fI\ *unique\fP, const void\fI\ *workload\fP, size_t\fI\ workload_size\fP, char\fI\ *job_handle\fP) .UNINDENT .sp Changed in version 0.21: \fBGEARMAN_PAUSE\fP will no longer be returned. A do operation will now run until it has been submitted. .INDENT 0.0 .TP .B gearman_return_t gearman_client_do_high_background(gearman_client_st\fI\ *client\fP, const char\fI\ *function_name\fP, const char\fI\ *unique\fP, const void\fI\ *workload\fP, size_t\fI\ workload_size\fP, gearman_job_handle_t\fI\ job_handle\fP) .UNINDENT .INDENT 0.0 .TP .B gearman_return_t gearman_client_do_low_background(gearman_client_st\fI\ *client\fP, const char\fI\ *function_name\fP, const char\fI\ *unique\fP, const void\fI\ *workload\fP, size_t\fI\ workload_size\fP, gearman_job_handle_t\fI\ job_handle\fP) .UNINDENT .SH DESCRIPTION .sp \fI\%gearman_client_do_background()\fP executes a single request to the gearmand server and returns the status via \fBgearman_return_t\fP\&. .sp \fBgearman_client_add_task_high_background()\fP and \fBgearman_client_add_task_low_background()\fP are identical to \fI\%gearman_client_do_background()\fP, only they set the \fI\%gearman_priority_t\fP to either high or low. .sp If job_handle is not NULL, it will be populated with the name of the job_handle for the task created. The job handle needs to be the size of \fBGEARMAN_JOB_HANDLE_SIZE\fP\&. Please see \fBgearman_job_handle_t\fP for more information. .SH RETURN VALUE .sp \fBgearman_return_t\fP .SH EXAMPLE .INDENT 0.0 .INDENT 3.5 .sp .nf .ft C /* # Gearman server and library # Copyright (C) 2012 Data Differential, http://datadifferential.com/ # All rights reserved. # # Use and distribution licensed under the BSD license. See # the COPYING file in this directory for full text. */ #include #include #include #include int main(void) { gearman_client_st *client= gearman_client_create(NULL); gearman_return_t ret= gearman_client_add_server(client, "localhost", 0); if (gearman_failed(ret)) { return EXIT_FAILURE; } gearman_job_handle_t job_handle; gearman_return_t rc= gearman_client_do_background(client, "reverse_function", "unique_value", "my string to reverse", strlen("my string to reverse"), job_handle); if (gearman_success(rc)) { // Make use of value printf("%s\en", job_handle); } gearman_client_free(client); return 0; } .ft P .fi .UNINDENT .UNINDENT .SH HOME .sp To find out more information please check: \fI\%http://gearman.info/\fP .sp \fBSEE ALSO:\fP .INDENT 0.0 .INDENT 3.5 \fBgearmand(8)\fP \fBlibgearman(3)\fP \fBgearman_strerror(3)\fP .UNINDENT .UNINDENT .SH AUTHOR Data Differential http://www.datadifferential.com/ .SH COPYRIGHT 2011-2020, Data Differential, http://www.datadifferential.com/ .\" Generated by docutils manpage writer. .