GEARMAN_CLIENT_SET_TIMEOUT(3)
π GEARMAN_CLIENT_SET_TIMEOUT π
okay bestie, welcome to the Gearmand manual page for gearman_client_set_timeout β¨ β the docs live over at http://gearman.info/ and yes we are reading them together, grab a snack π
β¨ NAME β¨
gearman_client_set_timeout β Gearmand Documentation, http://gearman.info/ π
π¦ SYNOPSIS π¦
#include <libgearman/gearman.h>
type gearman_client_st
type gearman_task_context_free_fn
int gearman_client_timeout(gearman_client_st *client)
void gearman_client_set_timeout(gearman_client_st *client, int timeout)
void *gearman_client_context(const gearman_client_st *client)
void gearman_client_set_context(gearman_client_st *client, void
*context)
void gearman_client_set_workload_malloc_fn(gearman_client_st *client,
gearman_malloc_fn <#c.gearman_malloc_fn> *function, void *context)
Deprecated since version 0.23: Use gearman_allocator_t <#c
.gearman_allocator_t>
void gearman_client_set_workload_free_fn(gearman_client_st *client,
gearman_free_fn <#c.gearman_free_fn> *function, void *context)
Deprecated since version 0.23: Use gearman_allocator_t <#c
.gearman_allocator_t>
void gearman_client_task_free_all(gearman_client_st *client)
void gearman_client_set_task_context_free_fn(gearman_client_st *client,
gearman_task_context_free_fn *function)
and when you link it: -lgearman π
π DESCRIPTION π
so gearman_client_st is the whole vibe for client communication with the server. it's giving main character energy, it's literally how you talk to the server fr fr π«Ά
gearman_client_context() and gearman_client_set_context() are your little storage cubbies β use them to stash an arbitrary object for the user β¨
gearman_client_set_task_context_free_fn() sets a trigger that gets called when a gearman_task_st <#c.gearman_task_st> is released. like a little goodbye party for your task π no cap.
gearman_client_timeout() and gearman_client_set_timeout() get and set the current connection timeout value, in milliseconds, for the client. yep, milliseconds, count them carefully, bestie β±οΈ
normally malloc(3) and free(3) handle allocation and releasing workloads. gearman_client_set_workload_malloc_fn() and gearman_client_set_workload_free_fn() let you swap those out for your own custom functions. BUT β these have been deprecated, please see gearman_allocator_t <#c.gearman_allocator_t> for the updated interface π the new interface ate, the old one is retired periodt.
gearman_client_task_free_all() frees all the current gearman_task_st <#c.gearman_task_st> that were created with the gearman_client_st π§Ήβ¨
β οΈ Warning: β οΈ by callinggearman_client_task_free_all()you can end up with a SEGFAULT π if you try to use anygearman_task_st<#c.gearman_task_st> that you have kept pointers to. dramatic but true, do not do this, i am begging π
π RETURN VALUE π
gearman_client_timeout() returns an integer representing the amount of time in milliseconds to wait for a connection before throwing an error. a value of -1 means an infinite timeout value π (yes king, wait forever)
π HOME π
to find out more information please check: http://gearman.info/ β¨
See also:
π Author π
Data Differential http://www.datadifferential.com/ π«Ά
πΈ Copyright πΈ
2011-2014, Data Differential, http://www.datadifferential.com/ π
and that's the whole page bestie, you ate that π this was version 1.1.21+ds, dated Feb 04, 2026, brought to you by the Gearmand girlies β slay, stay safe, and don't dereference freed task pointers π
β¨π
π¦ where this page comes from
- ubuntu resolute: libgearman-dev 1.1.21+ds-1ubuntu3 Β· BSD-3-Clause
- ubuntu stonking: libgearman-dev 1.1.21+ds-1ubuntu3 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms