---
name: "gearman_client_set_options"
section: "3"
platform: "linux"
package: "gearmand"
version: "2.2.0-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/gearman_client_set_options"
---

# gearman\_client\_set\_options(3)

Gearmand Documentation, https://gearman.org/gearmand/

## NAME

gearman\_client\_set\_options - Gearmand Documentation, https://gearman.org/gearmand/

## SYNOPSIS

\#include \<libgearman/gearman.h\>

- **type gearman\_client\_options\_t**

  - ***gearman\_client\_options\_t* gearman\_client\_options(const *gearman\_client\_st* \*client)**

  - **void gearman\_client\_set\_options(*gearman\_client\_st* \*client, *gearman\_client\_options\_t* options)**

  - **void gearman\_client\_add\_options(*gearman\_client\_st* \*client, *gearman\_client\_options\_t* options)**

  - **void gearman\_client\_remove\_options(*gearman\_client\_st* \*client, *gearman\_client\_options\_t* options)**

  - ***bool* gearman\_client\_has\_option(*gearman\_client\_st* \*client, *gearman\_client\_options\_t* option)**

  Link with -lgearman

## DESCRIPTION

*gearman\_client\_options()* returns the *gearman\_client\_options\_t* for *gearman\_client\_st*. You enable options via *gearman\_client\_add\_options()* and disable options via *gearman\_client\_remove\_options()*.

*gearman\_client\_set\_options()* has been DEPRECATED.

The currently supported options are:

- **type GEARMAN\_CLIENT\_NON\_BLOCKING**

  Run the cient in a non-blocking mode.

- **type GEARMAN\_CLIENT\_STOP\_WAIT\_ON\_SIGNAL**

  Return *GEARMAN\_IO\_WAIT* from **gearman\_wait()** when a signal interrupts the wait.

- **type GEARMAN\_CLIENT\_FREE\_TASKS**

  Automatically free task objects once they are complete.

- **type GEARMAN\_CLIENT\_UNBUFFERED\_RESULT**

  Allow the client to read data in chunks rather than have the library buffer the entire data result and pass that back.

- **type GEARMAN\_CLIENT\_GENERATE\_UNIQUE**

  Generate a unique id for each task created by generating a UUID.

- **type GEARMAN\_CLIENT\_SERVER\_SELECTION\_BY\_UNIQUE**

  Choose the server a job is submitted to by hashing its unique, instead of using the first idle server. Equivalent to *gearman\_client\_set\_server\_selection\_by\_unique()*, which describes the behavior in detail.

## RETURN VALUE

Various

## HOME

To find out more information please check: *https://gearman.org/gearmand/*

**SEE ALSO:**

**[gearmand(8)](/gearmand/8.md)** **[libgearman(3)](/libgearman/3.md)**

## AUTHOR

Data Differential http://www.datadifferential.com/

## COPYRIGHT

2011-2014, Data Differential, http://www.datadifferential.com/
