4 <!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
5 <!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
9 <meta name=
"viewport" content=
"width=device-width, initial-scale=1.0">
11 <title>libmemcached Configuration
— libmemcached
1.0.99 documentation
</title>
20 <script type=
"text/javascript" src=
"../_static/js/modernizr.min.js"></script>
23 <script type=
"text/javascript" id=
"documentation_options" data-url_root=
"../" src=
"../_static/documentation_options.js"></script>
24 <script type=
"text/javascript" src=
"../_static/jquery.js"></script>
25 <script type=
"text/javascript" src=
"../_static/underscore.js"></script>
26 <script type=
"text/javascript" src=
"../_static/doctools.js"></script>
27 <script type=
"text/javascript" src=
"../_static/language_data.js"></script>
29 <script type=
"text/javascript" src=
"../_static/js/theme.js"></script>
34 <link rel=
"stylesheet" href=
"../_static/css/theme.css" type=
"text/css" />
35 <link rel=
"stylesheet" href=
"../_static/pygments.css" type=
"text/css" />
36 <link rel=
"index" title=
"Index" href=
"../genindex.html" />
37 <link rel=
"search" title=
"Search" href=
"../search.html" />
38 <link rel=
"copyright" title=
"Copyright" href=
"../copyright.html" />
39 <link rel=
"next" title=
"libmemcached Constants and Defaults" href=
"constants.html" />
40 <link rel=
"prev" title=
"Misc" href=
"index_misc.html" />
43 <body class=
"wy-body-for-nav">
46 <div class=
"wy-grid-for-nav">
48 <nav data-toggle=
"wy-nav-shift" class=
"wy-nav-side">
49 <div class=
"wy-side-scroll">
50 <div class=
"wy-side-nav-search" >
54 <a href=
"../index.html" class=
"icon icon-home"> libmemcached
71 <form id=
"rtd-search-form" class=
"wy-form" action=
"../search.html" method=
"get">
72 <input type=
"text" name=
"q" placeholder=
"Search docs" />
73 <input type=
"hidden" name=
"check_keywords" value=
"yes" />
74 <input type=
"hidden" name=
"area" value=
"default" />
81 <div class=
"wy-menu wy-menu-vertical" data-spy=
"affix" role=
"navigation" aria-label=
"main navigation">
88 <p class=
"caption"><span class=
"caption-text">libmemcached
</span></p>
90 <li class=
"toctree-l1"><a class=
"reference internal" href=
"../libmemcached.html">Introduction
</a></li>
91 <li class=
"toctree-l1"><a class=
"reference internal" href=
"index.html">libmemcached API
</a></li>
92 <li class=
"toctree-l1 current"><a class=
"reference internal" href=
"index_misc.html">Misc
</a><ul class=
"current">
93 <li class=
"toctree-l2 current"><a class=
"current reference internal" href=
"#">Configuration
</a></li>
94 <li class=
"toctree-l2"><a class=
"reference internal" href=
"constants.html">Constants
</a></li>
95 <li class=
"toctree-l2"><a class=
"reference internal" href=
"examples.html">Examples
</a></li>
96 <li class=
"toctree-l2"><a class=
"reference internal" href=
"versioning.html">Versioning
</a></li>
100 <p class=
"caption"><span class=
"caption-text">libmemcachedutil
</span></p>
102 <li class=
"toctree-l1"><a class=
"reference internal" href=
"../libmemcachedutil.html">Introduction
</a></li>
103 <li class=
"toctree-l1"><a class=
"reference internal" href=
"../libmemcachedutil/index.html">libmemcachedutil API
</a></li>
105 <p class=
"caption"><span class=
"caption-text">libhashkit
</span></p>
107 <li class=
"toctree-l1"><a class=
"reference internal" href=
"../libhashkit.html">Introduction
</a></li>
108 <li class=
"toctree-l1"><a class=
"reference internal" href=
"../libhashkit/index.html">libhashkit API
</a></li>
110 <p class=
"caption"><span class=
"caption-text">Client Applications
</span></p>
112 <li class=
"toctree-l1"><a class=
"reference internal" href=
"../bin/index.html">Client Applications
</a></li>
114 <p class=
"caption"><span class=
"caption-text">Copyright
</span></p>
116 <li class=
"toctree-l1"><a class=
"reference internal" href=
"../copyright.html">Copyright
</a></li>
125 <section data-toggle=
"wy-nav-shift" class=
"wy-nav-content-wrap">
128 <nav class=
"wy-nav-top" aria-label=
"top navigation">
130 <i data-toggle=
"wy-nav-top" class=
"fa fa-bars"></i>
131 <a href=
"../index.html">libmemcached
</a>
136 <div class=
"wy-nav-content">
138 <div class=
"rst-content">
156 <div role=
"navigation" aria-label=
"breadcrumbs navigation">
158 <ul class=
"wy-breadcrumbs">
160 <li><a href=
"../index.html">Docs
</a> »</li>
162 <li><a href=
"index_misc.html">Misc
</a> »</li>
164 <li>libmemcached Configuration
</li>
167 <li class=
"wy-breadcrumbs-aside">
178 <div role=
"main" class=
"document" itemscope=
"itemscope" itemtype=
"http://schema.org/Article">
179 <div itemprop=
"articleBody">
181 <div class=
"section" id=
"libmemcached-configuration">
182 <h1>libmemcached Configuration
<a class=
"headerlink" href=
"#libmemcached-configuration" title=
"Permalink to this headline">¶
</a></h1>
183 <div class=
"section" id=
"synopsis">
184 <h2>SYNOPSIS
<a class=
"headerlink" href=
"#synopsis" title=
"Permalink to this headline">¶
</a></h2>
185 <dl class=
"docutils">
186 <dt>#include
<libmemcached-
1.0/memcached.h
></dt>
187 <dd>Compile and link with -lmemcached
</dd>
189 <dl class=
"function">
190 <dt id=
"_CPPv49memcachedPKc6size_t">
191 <span id=
"_CPPv39memcachedPKc6size_t"></span><span id=
"_CPPv29memcachedPKc6size_t"></span><span id=
"memcached__cCP.s"></span><a class=
"reference internal" href=
"memcached_create.html#_CPPv412memcached_st" title=
"memcached_st">memcached_st
</a> *
<code class=
"descname">memcached
</code><span class=
"sig-paren">(
</span><em class=
"property">const
</em> char *
<em>string
</em>, size_t
<em>string_length
</em><span class=
"sig-paren">)
</span><a class=
"headerlink" href=
"#_CPPv49memcachedPKc6size_t" title=
"Permalink to this definition">¶
</a><br /></dt>
192 <dd><table class=
"docutils field-list" frame=
"void" rules=
"none">
193 <col class=
"field-name" />
194 <col class=
"field-body" />
196 <tr class=
"field-odd field"><th class=
"field-name">Parameters:
</th><td class=
"field-body"><ul class=
"first simple">
197 <li><strong>string
</strong> -- configuration string
</li>
198 <li><strong>string_length
</strong> -- length of the configuration string without any terminating zero
</li>
202 <tr class=
"field-even field"><th class=
"field-name">Returns:
</th><td class=
"field-body"><p class=
"first last">allocated and initialized
<a class=
"reference internal" href=
"memcached_create.html#_CPPv412memcached_st" title=
"memcached_st"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_st
</span></code></a> struct
</p>
209 <dl class=
"function">
210 <dt id=
"_CPPv432libmemcached_check_configurationPKc6size_tPc6size_t">
211 <span id=
"_CPPv332libmemcached_check_configurationPKc6size_tPc6size_t"></span><span id=
"_CPPv232libmemcached_check_configurationPKc6size_tPc6size_t"></span><span id=
"libmemcached_check_configuration__cCP.s.cP.s"></span><a class=
"reference internal" href=
"memcached_return_t.html#_CPPv418memcached_return_t" title=
"memcached_return_t">memcached_return_t
</a> <code class=
"descname">libmemcached_check_configuration
</code><span class=
"sig-paren">(
</span><em class=
"property">const
</em> char *
<em>option_string
</em>, size_t
<em>length
</em>, char *
<em>error_buffer
</em>, size_t
<em>error_buffer_size
</em><span class=
"sig-paren">)
</span><a class=
"headerlink" href=
"#_CPPv432libmemcached_check_configurationPKc6size_tPc6size_t" title=
"Permalink to this definition">¶
</a><br /></dt>
212 <dd><table class=
"docutils field-list" frame=
"void" rules=
"none">
213 <col class=
"field-name" />
214 <col class=
"field-body" />
216 <tr class=
"field-odd field"><th class=
"field-name">Parameters:
</th><td class=
"field-body"><ul class=
"first simple">
217 <li><strong>option_string
</strong> -- configuration string
</li>
218 <li><strong>length
</strong> -- length of the configuration string without any terminating zero
</li>
219 <li><strong>error_buffer
</strong> -- buffer used to store any error message
</li>
220 <li><strong>error_buffer_size
</strong> -- available size of the
<a class=
"reference internal" href=
"#_CPPv432libmemcached_check_configurationPKc6size_tPc6size_t" title=
"libmemcached_check_configuration::error_buffer"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">error_buffer
</span></code></a></li>
224 <tr class=
"field-even field"><th class=
"field-name">Returns:
</th><td class=
"field-body"><p class=
"first last"><a class=
"reference internal" href=
"memcached_return_t.html#_CPPv418memcached_return_t" title=
"memcached_return_t"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_return_t
</span></code></a> indicating success
</p>
232 <div class=
"section" id=
"description">
233 <h2>DESCRIPTION
<a class=
"headerlink" href=
"#description" title=
"Permalink to this headline">¶
</a></h2>
234 <p><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">libmemcached
</span></code> implements a custom language for configuring and modifying
235 servers. By passing in an option string you can generate a
<a class=
"reference internal" href=
"memcached_create.html#_CPPv412memcached_st" title=
"memcached_st"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_st
</span></code></a> object
236 that you can use in your application directly.
</p>
237 <div class=
"section" id=
"general-options">
238 <h3>General Options:
<a class=
"headerlink" href=
"#general-options" title=
"Permalink to this headline">¶
</a></h3>
239 <dl class=
"describe">
241 <code class=
"descname">--SERVER=
<servername
>:
<optional_port
>/?
<optional_weight
></code></dt>
242 <dd><p>Provide a servername to be used by the client.
</p>
243 <p>Providing a weight will cause weighting to occur with all hosts with each
244 server getting a default weight of
1.
</p>
247 <dl class=
"describe">
249 <code class=
"descname">--SOCKET=
"<filepath
>/?
<optional_weight
>"</code></dt>
250 <dd><p>Provide a filepath to a UNIX socket file. Providing a weight will cause
251 weighting to occur with all hosts with each server getting a default weight
255 <dl class=
"describe">
257 <code class=
"descname">--VERIFY-KEY
</code></dt>
258 <dd><p>Verify that keys that are being used fit within the design of the protocol
262 <dl class=
"describe">
264 <code class=
"descname">--REMOVE_FAILED_SERVERS
</code></dt>
265 <dd><p>Enable the behavior
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t40MEMCACHED_BEHAVIOR_REMOVE_FAILED_SERVERSE" title=
"MEMCACHED_BEHAVIOR_REMOVE_FAILED_SERVERS"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_REMOVE_FAILED_SERVERS
</span></code></a>.
</p>
268 <dl class=
"describe">
270 <code class=
"descname">--BINARY-PROTOCOL
</code></dt>
271 <dd><p>Force all connections to use the binary protocol.
</p>
274 <dl class=
"describe">
276 <code class=
"descname">--BUFFER-REQUESTS
</code></dt>
277 <dd><p>Please see
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t34MEMCACHED_BEHAVIOR_BUFFER_REQUESTSE" title=
"MEMCACHED_BEHAVIOR_BUFFER_REQUESTS"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_BUFFER_REQUESTS
</span></code></a>.
</p>
280 <dl class=
"describe">
282 <code class=
"descname">--CONFIGURE-FILE=
</code></dt>
283 <dd><p>Provide a configuration file to be used to load requests. Beware that by
284 using a configuration file
<code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">libmemcached
</span></code> will reset
<a class=
"reference internal" href=
"memcached_create.html#_CPPv412memcached_st" title=
"memcached_st"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_st
</span></code></a> based
285 on information only contained in the file.
</p>
288 <dl class=
"describe">
290 <code class=
"descname">--CONNECT-TIMEOUT=
</code></dt>
291 <dd><p>See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t34MEMCACHED_BEHAVIOR_CONNECT_TIMEOUTE" title=
"MEMCACHED_BEHAVIOR_CONNECT_TIMEOUT"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_CONNECT_TIMEOUT
</span></code></a>.
</p>
294 <dl class=
"describe">
296 <code class=
"descname">--DISTRIBUTION=
</code></dt>
297 <dd><p>Set the distribution model used by the client.
298 See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for more details.
</p>
301 <dl class=
"describe">
303 <code class=
"descname">--HASH=
</code></dt>
304 <dd><p>Set the hashing algorithm used for placing keys on servers.
</p>
307 <dl class=
"describe">
309 <code class=
"descname">--HASH-WITH-NAMESPACE
</code></dt>
310 <dd><p>When enabled the prefix key will be added to the key when determining which
311 server to store the data in.
</p>
314 <dl class=
"describe">
316 <code class=
"descname">--NOREPLY
</code></dt>
317 <dd><p>Enable
"no reply
" for all calls that support this. It is highly recommended
318 that you use this option with the binary protocol only.
</p>
321 <dl class=
"describe">
323 <code class=
"descname">--NUMBER-OF-REPLICAS=
</code></dt>
324 <dd><p>Set the number of servers that keys will be replicated to.
</p>
327 <dl class=
"describe">
329 <code class=
"descname">--RANDOMIZE-REPLICA-READ
</code></dt>
330 <dd><p>Select randomly the server within the replication pool to read from.
</p>
333 <dl class=
"describe">
335 <code class=
"descname">--SORT-HOSTS
</code></dt>
336 <dd><p>When adding new servers always calculate their distribution based on sorted
340 <dl class=
"describe">
342 <code class=
"descname">--SUPPORT-CAS
</code></dt>
343 <dd><p>See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t30MEMCACHED_BEHAVIOR_SUPPORT_CASE" title=
"MEMCACHED_BEHAVIOR_SUPPORT_CAS"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_SUPPORT_CAS
</span></code></a></p>
346 <dl class=
"describe">
348 <code class=
"descname">--USE-UDP
</code></dt>
349 <dd><p>See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t26MEMCACHED_BEHAVIOR_USE_UDPE" title=
"MEMCACHED_BEHAVIOR_USE_UDP"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_USE_UDP
</span></code></a></p>
352 <dl class=
"describe">
354 <code class=
"descname">--NAMESPACE=
</code></dt>
355 <dd><p>A namespace is a container that provides context for keys, only other
356 requests that know the namespace can access these values. This is
357 accomplished by prepending the namespace value to all keys.
</p>
361 <div class=
"section" id=
"memcached-pool-options">
362 <h3>Memcached Pool Options:
<a class=
"headerlink" href=
"#memcached-pool-options" title=
"Permalink to this headline">¶
</a></h3>
363 <dl class=
"describe">
365 <code class=
"descname">--POOL-MIN
</code></dt>
366 <dd><p>Initial size of pool.
</p>
369 <dl class=
"describe">
371 <code class=
"descname">--POOL-MAX
</code></dt>
372 <dd><p>Maximize size of the pool.
</p>
376 <div class=
"section" id=
"i-o-options">
377 <h3>I/O Options:
<a class=
"headerlink" href=
"#i-o-options" title=
"Permalink to this headline">¶
</a></h3>
378 <dl class=
"describe">
380 <code class=
"descname">--TCP-NODELAY
</code></dt>
381 <dd><p>See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t30MEMCACHED_BEHAVIOR_TCP_NODELAYE" title=
"MEMCACHED_BEHAVIOR_TCP_NODELAY"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_TCP_NODELAY
</span></code></a></p>
384 <dl class=
"describe">
386 <code class=
"descname">--TCP-KEEPALIVE
</code></dt>
387 <dd><p>See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for
<code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_TCP_KEEPALIVE
</span></code></p>
390 <dl class=
"describe">
392 <code class=
"descname">--RETRY-TIMEOUT=
</code></dt>
393 <dd><p>See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t32MEMCACHED_BEHAVIOR_RETRY_TIMEOUTE" title=
"MEMCACHED_BEHAVIOR_RETRY_TIMEOUT"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_RETRY_TIMEOUT
</span></code></a></p>
396 <dl class=
"describe">
398 <code class=
"descname">--SERVER-FAILURE-LIMIT=
</code></dt>
399 <dd><p>See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t39MEMCACHED_BEHAVIOR_SERVER_FAILURE_LIMITE" title=
"MEMCACHED_BEHAVIOR_SERVER_FAILURE_LIMIT"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_SERVER_FAILURE_LIMIT
</span></code></a></p>
402 <dl class=
"describe">
404 <code class=
"descname">--SND-TIMEOUT=
</code></dt>
405 <dd><p>See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t30MEMCACHED_BEHAVIOR_SND_TIMEOUTE" title=
"MEMCACHED_BEHAVIOR_SND_TIMEOUT"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_SND_TIMEOUT
</span></code></a></p>
408 <dl class=
"describe">
410 <code class=
"descname">--SOCKET-RECV-SIZE=
</code></dt>
411 <dd><p>See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t35MEMCACHED_BEHAVIOR_SOCKET_RECV_SIZEE" title=
"MEMCACHED_BEHAVIOR_SOCKET_RECV_SIZE"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_SOCKET_RECV_SIZE
</span></code></a></p>
414 <dl class=
"describe">
416 <code class=
"descname">--SOCKET-SEND-SIZE=
</code></dt>
417 <dd><p>See
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv422memcached_behavior_setP12memcached_st20memcached_behavior_t8uint64_t" title=
"memcached_behavior_set"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_behavior_set()
</span></code></a> for
<a class=
"reference internal" href=
"memcached_behavior.html#_CPPv4N20memcached_behavior_t35MEMCACHED_BEHAVIOR_SOCKET_SEND_SIZEE" title=
"MEMCACHED_BEHAVIOR_SOCKET_SEND_SIZE"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">MEMCACHED_BEHAVIOR_SOCKET_SEND_SIZE
</span></code></a></p>
420 <dl class=
"describe">
422 <code class=
"descname">--POLL-TIMEOUT=
</code></dt>
423 <dd><p>Set the timeout used by
<em class=
"manpage"><a class=
"manpage reference external" href=
"https://linux.die.net/man/3/poll">poll(
3)
</a></em>.
</p>
426 <dl class=
"describe">
428 <code class=
"descname">--IO-BYTES-WATERMARK=
</code></dt>
431 <dl class=
"describe">
433 <code class=
"descname">--IO-KEY-PREFETCH=
</code></dt>
436 <dl class=
"describe">
438 <code class=
"descname">--IO-MSG-WATERMARK=
</code></dt>
441 <dl class=
"describe">
443 <code class=
"descname">--TCP-KEEPIDLE
</code></dt>
446 <dl class=
"describe">
448 <code class=
"descname">--RCV-TIMEOUT=
</code></dt>
452 <div class=
"section" id=
"other-options">
453 <h3>Other Options:
<a class=
"headerlink" href=
"#other-options" title=
"Permalink to this headline">¶
</a></h3>
454 <dl class=
"describe">
456 <code class=
"descname">INCLUDE
</code></dt>
457 <dd><p>Include a file in configuration.
458 Unlike
<code class=
"docutils literal notranslate"><span class=
"pre">--CONFIGURE-FILE=
</span></code> this will not reset
<a class=
"reference internal" href=
"memcached_create.html#_CPPv412memcached_st" title=
"memcached_st"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_st
</span></code></a>.
</p>
461 <dl class=
"describe">
463 <code class=
"descname">RESET
</code></dt>
464 <dd><p>Reset
<a class=
"reference internal" href=
"memcached_create.html#_CPPv412memcached_st" title=
"memcached_st"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_st
</span></code></a> and continue to process.
</p>
467 <dl class=
"describe">
469 <code class=
"descname">END
</code></dt>
470 <dd><p>End configuration processing.
</p>
473 <dl class=
"describe">
475 <code class=
"descname">ERROR
</code></dt>
476 <dd><p>End configuration processing and throw an error.
</p>
481 <div class=
"section" id=
"environment">
482 <h2>ENVIRONMENT
<a class=
"headerlink" href=
"#environment" title=
"Permalink to this headline">¶
</a></h2>
484 <dt id=
"envvar-LIBMEMCACHED">
485 <code class=
"descname">LIBMEMCACHED
</code><a class=
"headerlink" href=
"#envvar-LIBMEMCACHED" title=
"Permalink to this definition">¶
</a></dt>
489 <div class=
"section" id=
"return-value">
490 <h2>RETURN VALUE
<a class=
"headerlink" href=
"#return-value" title=
"Permalink to this headline">¶
</a></h2>
491 <p><a class=
"reference internal" href=
"#_CPPv49memcachedPKc6size_t" title=
"memcached"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached()
</span></code></a> returns a pointer to the
<a class=
"reference internal" href=
"memcached_create.html#_CPPv412memcached_st" title=
"memcached_st"><code class=
"xref cpp cpp-any docutils literal notranslate"><span class=
"pre">memcached_st
</span></code></a> that was created (or
492 initialized). On an allocation failure, it returns NULL.
</p>
494 <div class=
"section" id=
"example">
495 <h2>EXAMPLE
<a class=
"headerlink" href=
"#example" title=
"Permalink to this headline">¶
</a></h2>
496 <div class=
"highlight-c notranslate"><div class=
"highlight"><pre><span></span><span class=
"k">const
</span> <span class=
"kt">char
</span> <span class=
"o">*
</span><span class=
"n">config_string
</span><span class=
"o">=
</span>
497 <span class=
"s">"--SERVER=host10.example.com
"</span>
498 <span class=
"s">"--SERVER=host11.example.com
"</span>
499 <span class=
"s">"--SERVER=host10.example.com
"</span><span class=
"p">;
</span>
500 <span class=
"n">memcached_st
</span> <span class=
"o">*
</span><span class=
"n">memc
</span><span class=
"o">=
</span> <span class=
"n">memcached
</span><span class=
"p">(
</span><span class=
"n">config_string
</span><span class=
"p">,
</span> <span class=
"n">strlen
</span><span class=
"p">(
</span><span class=
"n">config_string
</span><span class=
"p">));
</span>
501 <span class=
"p">{
</span>
502 <span class=
"c1">// ...
</span>
503 <span class=
"p">}
</span>
504 <span class=
"n">memcached_free
</span><span class=
"p">(
</span><span class=
"n">memc
</span><span class=
"p">);
</span>
508 <div class=
"section" id=
"see-also">
509 <h2>SEE ALSO
<a class=
"headerlink" href=
"#see-also" title=
"Permalink to this headline">¶
</a></h2>
511 <li><em class=
"manpage"><a class=
"manpage reference external" href=
"https://linux.die.net/man/1/memcached">memcached(
1)
</a></em></li>
512 <li><a class=
"reference internal" href=
"../libmemcached.html"><span class=
"doc">C/C++ Client Library for memcached
</span></a></li>
513 <li><a class=
"reference internal" href=
"memcached_strerror.html"><span class=
"doc">Converting Error Codes to Messages
</span></a></li>
524 <div class=
"rst-footer-buttons" role=
"navigation" aria-label=
"footer navigation">
526 <a href=
"constants.html" class=
"btn btn-neutral float-right" title=
"libmemcached Constants and Defaults" accesskey=
"n" rel=
"next">Next
<span class=
"fa fa-arrow-circle-right"></span></a>
529 <a href=
"index_misc.html" class=
"btn btn-neutral float-left" title=
"Misc" accesskey=
"p" rel=
"prev"><span class=
"fa fa-arrow-circle-left"></span> Previous
</a>
536 <div role=
"contentinfo">
538 © <a href=
"../copyright.html">Copyright
</a>
542 Built with
<a href=
"http://sphinx-doc.org/">Sphinx
</a> using a
<a href=
"https://github.com/rtfd/sphinx_rtd_theme">theme
</a> provided by
<a href=
"https://readthedocs.org">Read the Docs
</a>.
555 <script type=
"text/javascript">
557 SphinxRtdTheme.Navigation.enable(true);