Merge in docs.
authorBrian Aker <brian@tangent.org>
Sun, 19 Jun 2011 08:25:48 +0000 (01:25 -0700)
committerBrian Aker <brian@tangent.org>
Sun, 19 Jun 2011 08:25:48 +0000 (01:25 -0700)
42 files changed:
ChangeLog
docs/conf.py.in
docs/hashkit_create.rst
docs/index.rst
docs/libhashkit.rst
docs/libmemcached.rst
docs/libmemcached/memcached_return_t.rst [new file with mode: 0644]
docs/memaslap.rst
docs/memcached_behavior.rst
docs/memcached_callback.rst
docs/memcached_cas.rst
docs/memcached_create.rst
docs/memcached_delete.rst
docs/memcached_dump.rst
docs/memcached_flush.rst
docs/memcached_flush_buffers.rst
docs/memcached_generate_hash_value.rst
docs/memcached_get.rst
docs/memcached_memory_allocators.rst
docs/memcached_pool.rst
docs/memcached_quit.rst
docs/memcached_result_st.rst
docs/memcached_sasl.rst
docs/memcached_server_st.rst
docs/memcached_servers.rst
docs/memcached_set.rst
docs/memcached_stats.rst
docs/memcached_strerror.rst
docs/memcached_user_data.rst
docs/memcached_verbosity.rst
docs/memcached_version.rst
docs/memcapable.rst
docs/memcat.rst
docs/memcp.rst
docs/memdump.rst
docs/memerror.rst
docs/memflush.rst
docs/memrm.rst
docs/memslap.rst
docs/memstat.rst
libmemcached/hosts.cc
libmemcached/server.h

index 2589ceb7d160e145a055dc138bb29ab9497f7948..3e7cc6392890b5f11dda22fc35cbc7eb48d92ea6 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -11,8 +11,9 @@
   * New error system.
   * New flow control for messages means faster get/set calls.
   * Added new documentation system.
+  * A behavior change has been now made that if you specify a weight for any
+  server, we enable the weight flag and do weight balancing.
   * A behavior change has been now made that if you specify a weight for any server, we enable the weight flag and do weight balancing.  
-  
   * Added MEMCACHED_BEHAVIOR_REMOVE_FAILED_SERVERS to simplify the setting of AUTO REJECT for servers.
 
 0.48 Tue Mar 15 23:05:18 PDT 2011
index 84d6eccb4b8c2c1a264c5b312058db382093d9ff..a6a1dfb7eb76d823ad2eff098f880735c289c701 100644 (file)
@@ -301,6 +301,7 @@ man_pages = [
   ('memcached_result_st', 'memcached_result_length', u'Working with result sets', [u'Brian Aker'], 3),
   ('memcached_result_st', 'memcached_result_st', u'Working with result sets', [u'Brian Aker'], 3),
   ('memcached_result_st', 'memcached_result_value', u'Working with result sets', [u'Brian Aker'], 3),
+  ('libmemcached/memcached_return_t', 'memcached_return_t', u'Return type values ', [u'Brian Aker'], 3),
   ('memcached_sasl', 'memcached_destroy_sasl_auth_data', u'libmemcached Documentation', [u'Brian Aker'], 3),
   ('memcached_sasl', 'memcached_get_sasl_callbacks', u'libmemcached Documentation', [u'Brian Aker'], 3),
   ('memcached_sasl', 'memcached_sasl', u'libmemcached Documentation', [u'Brian Aker'], 3),
index f7aabac5313b42bc9747f195ef7caed90aa7db0d..8935b2d096f9d1c8eaca73bc58117604e0542ab8 100644 (file)
@@ -10,6 +10,8 @@ SYNOPSIS
 
 #include <libhashkit/hashkit.h>
  
+.. c:type:: hashkit_st
+
 .. c:function:: hashkit_st *hashkit_create(hashkit_st *hash);
  
 .. c:function:: hashkit_st *hashkit_clone(hashkit_st *destination, const hashkit_st *ptr);
@@ -20,25 +22,24 @@ SYNOPSIS
 
 Compile and link with -lhashkit
 
-
 -----------
 DESCRIPTION
 -----------
 
 
-The hashkit_create() function initializes a hashkit object for use. If
+The :c:func:`hashkit_create()` function initializes a hashkit object for use. If
 you pass a NULL argument for hash, then the memory for the object is
 allocated. If you specify a pre-allocated piece of memory, that is
 initialized for use.
 
-The hashkit_clone() function initializes a hashkit object much like
-hashkit_create(), but instead of using default settings it will use
+The :c:func:`hashkit_clone()` function initializes a hashkit object much like
+:c:func:`hashkit_create()`, but instead of using default settings it will use
 the settings of the ptr hashkit object.
 
-The hashkit_free() frees any resources being consumed by the hashkit
-objects that were initialized with hashkit_create() or hashkit_clone().
+The :c:func:`hashkit_free()` frees any resources being consumed by the hashkit
+objects that were initialized with :c:func:`hashkit_create()` or :c:func:`hashkit_clone()`.
 
-The hashkit_is_allocated() reports where the memory was allocated 
+The :c:func:`hashkit_is_allocated()` reports where the memory was allocated 
 for a hashkit object.
 
 
@@ -47,11 +48,11 @@ RETURN VALUE
 ------------
 
 
-hashkit_create() and hashkit_clone() will return NULL on failure or
+:c:func:`hashkit_create()` and :c:func:`hashkit_clone()` will return NULL on failure or
 non-NULL on success.
 
-hashkit_is_allocated() returns true if the memory for the hashkit
-object was allocated inside of hashkit_create() or hashkit_clone(),
+:c:func:`hashkit_is_allocated()` returns true if the memory for the hashkit
+object was allocated inside of :c:func:`hashkit_create()` or :c:func:`hashkit_clone()`,
 otherwise it is false and was user-supplied memory.
 
 
index cef0830dbd9e078b84a9ea59c5bd031ff4e1b584..77b5060020a7f8c89ae4a74fbf303f38b2e92d21 100644 (file)
@@ -53,6 +53,7 @@ Advanced Topics
    memcached_generate_hash_value
    memcached_memory_allocators
    memcached_quit
+   libmemcached/memcached_return_t
    memcached_sasl
    memcached_server_st
    memcached_servers
index 5f31f69bcecff06b645e76eb474526a86631e7d4..d13b875752406ca8ed2a121b1ed6571f56ac5321 100644 (file)
@@ -15,8 +15,7 @@ Introducing libhashkit
 DESCRIPTION
 -----------
 
-
-\ **libhashkit**\  is a small and thread-safe client library that provides a collection of useful hashing algorithm. libhashkit is distributed with libmemcached.
+:program:'libhashkit'  is a small and thread-safe client library that provides a collection of useful hashing algorithm. libhashkit is distributed with libmemcached.
 
 
 ----
index 23ec93b49a9974e6b0b7646d00b96a6f747d1a62..78af3e320feea0159212dc740c62081ea6cf9ffa 100644 (file)
@@ -10,6 +10,8 @@ SYNOPSIS
 
 Compile and link with -lmemcached
 
+=======
+
 libMemcached is an open source C/C++ client library and tools for the memcached server (http://danga.com/memcached). It has been designed to be light on memory usage, thread safe, and provide full access to server side methods.
 
 libMemcached was designed to provide the greatest number of options to use Memcached. Some of the features provided:
@@ -41,13 +43,13 @@ a modular and consistent method of object distribution.
 There are multiple implemented routing and hashing methods. See the
 memcached_behavior_set() manpage for more information.
 
-All operations are performed against a \ ``memcached_st``\  structure.
+All operations are performed against a :c:type:`memcached_st`  structure.
 These structures can either be dynamically allocated or statically
 allocated and then initialized by memcached_create(). Functions have been
-written in order to encapsulate the \ ``memcached_st``\ . It is not
+written in order to encapsulate the :c:type:`memcached_st` . It is not
 recommended that you operate directly against the structure.
 
-Nearly all functions return a \ ``memcached_return_t``\  value.
+Nearly all functions return a :c:type:`memcached_return_t`\  value.
 This value can be translated to a printable string with memcached_strerror(3).
 
 Objects are stored on servers by hashing keys. The hash value maps the key to a particular server. All clients understand how this hashing works, so it is possibly to reliably both push data to a server and retrieve data from a server.
@@ -56,7 +58,7 @@ Group keys can be optionally used to group sets of objects with servers.
 
 Namespaces are supported, and can be used to partition caches so that multiple applications can use the same memcached servers.
 
-\ ``memcached_st``\  structures are thread-safe, but each thread must
+:c:type:`memcached_st`  structures are thread-safe, but each thread must
 contain its own structure (that is, if you want to share these among
 threads you must provide your own locking). No global variables are
 used in this library.
@@ -129,9 +131,9 @@ THREADS AND PROCESSES
 
 
 When using threads or forked processes it is important to keep one instance
-of \ ``memcached_st``\  per process or thread. Without creating your own locking
-structures you can not share a single \ ``memcached_st``\ . However, you can call
-memcached_quit(3) on a \ ``memcached_st``\  and then use the resulting cloned
+of :c:type:`memcached_st`  per process or thread. Without creating your own locking
+structures you can not share a single :c:type:`memcached_st`. However, you can call
+memcached_quit(3) on a :c:type:`memcached_st`  and then use the resulting cloned
 structure.
 
 
diff --git a/docs/libmemcached/memcached_return_t.rst b/docs/libmemcached/memcached_return_t.rst
new file mode 100644 (file)
index 0000000..3663c6d
--- /dev/null
@@ -0,0 +1,133 @@
+================================
+Error Codes (memcached_return_t)
+================================
+
+--------
+SYNOPSIS
+--------
+
+#include <libmemcached/memcached.h>
+
+.. c:type:: memcached_return_t
+
+.. c:function:: const char *libmemcached_strerror(libmemcached_return_t rc)
+
+.. c:function:: bool libmemcached_success(libmemcached_return_t rc)
+
+.. c:function:: bool libmemcached_failure(libmemcached_return_t rc)
+
+.. c:function:: bool libmemcache_continue(libmemcached_return_t rc)
+
+
+
+:c:func:`memcached_success()` return true if :c:type:`MEMCACHED_SUCCESS` tested true.
+
+:c:func:`memcached_failure()` return true if any value other then :c:type:`MEMCACHED_SUCCESS` was provided.
+
+
+
+
+.. c:type:: MEMCACHED_SUCCESS,
+
+Success
+
+.. c:type:: MEMCACHED_FAILURE,
+
+.. c:type:: MEMCACHED_HOST_LOOKUP_FAILURE, // getaddrinfo() only
+
+.. c:type:: MEMCACHED_CONNECTION_FAILURE,  // DEPRECATED
+
+.. c:type:: MEMCACHED_CONNECTION_BIND_FAILURE,  // DEPRECATED
+
+.. c:type:: MEMCACHED_WRITE_FAILURE,
+
+.. c:type:: MEMCACHED_READ_FAILURE,
+
+.. c:type:: MEMCACHED_UNKNOWN_READ_FAILURE,
+
+.. c:type:: MEMCACHED_PROTOCOL_ERROR,
+
+.. c:type:: MEMCACHED_CLIENT_ERROR,
+
+.. c:type:: MEMCACHED_SERVER_ERROR,
+
+.. c:type:: MEMCACHED_CONNECTION_SOCKET_CREATE_FAILURE, // DEPRECATED
+
+.. c:type:: MEMCACHED_DATA_EXISTS,
+
+.. c:type:: MEMCACHED_DATA_DOES_NOT_EXIST,
+
+.. c:type:: MEMCACHED_NOTSTORED,
+
+.. c:type:: MEMCACHED_STORED,
+
+.. c:type:: MEMCACHED_NOTFOUND,
+
+.. c:type:: MEMCACHED_MEMORY_ALLOCATION_FAILURE,
+
+.. c:type:: MEMCACHED_PARTIAL_READ,
+
+.. c:type:: MEMCACHED_SOME_ERRORS,
+
+.. c:type:: MEMCACHED_NO_SERVERS,
+
+.. c:type:: MEMCACHED_END,
+
+.. c:type:: MEMCACHED_DELETED,
+
+.. c:type:: MEMCACHED_VALUE,
+
+.. c:type:: MEMCACHED_STAT,
+
+.. c:type:: MEMCACHED_ITEM,
+
+.. c:type:: MEMCACHED_ERRNO,
+
+.. c:type:: MEMCACHED_FAIL_UNIX_SOCKET, // DEPRECATED
+
+.. c:type:: MEMCACHED_NOT_SUPPORTED,
+
+.. c:type:: MEMCACHED_NO_KEY_PROVIDED, /* Deprecated. Use MEMCACHED_BAD_KEY_PROVIDED! */
+
+.. c:type:: MEMCACHED_FETCH_NOTFINISHED,
+
+.. c:type:: MEMCACHED_TIMEOUT,
+
+Connection to server timed out.
+
+.. c:type:: MEMCACHED_BUFFERED,
+
+.. c:type:: MEMCACHED_BAD_KEY_PROVIDED,
+
+.. c:type:: MEMCACHED_INVALID_HOST_PROTOCOL,
+
+.. c:type:: MEMCACHED_SERVER_MARKED_DEAD,
+
+.. c:type:: MEMCACHED_UNKNOWN_STAT_KEY,
+
+.. c:type:: MEMCACHED_E2BIG,
+
+.. c:type:: MEMCACHED_INVALID_ARGUMENTS,
+
+.. c:type:: MEMCACHED_KEY_TOO_BIG,
+
+.. c:type:: MEMCACHED_AUTH_PROBLEM,
+
+.. c:type:: MEMCACHED_AUTH_FAILURE,
+
+.. c:type:: MEMCACHED_AUTH_CONTINUE,
+
+.. c:type:: MEMCACHED_PARSE_ERROR,
+
+.. c:type:: MEMCACHED_PARSE_USER_ERROR,
+
+.. c:type:: MEMCACHED_DEPRECATED,
+
+.. c:type:: MEMCACHED_MAXIMUM_RETURN /* Always add new error code before */
+   
+--------
+SEE ALSO
+--------
+
+:manpage:`memcached(8)` :manpage:`libmemcached(3)` :manpage:`memcached_client_error()` or :manpage:`memcached_worker_error()`
+
index 02e2ab26cdfc5b86b3b1a4fab51df7e8e12ae306..3f9e62dd09536237a9c2b78bbd176086e394b299 100644 (file)
@@ -18,10 +18,8 @@ DESCRIPTION
 -----------
 
 
-\ **memaslap**\  is a load generation and benchmark tool for memcached(1)
-servers. It generates configurable workload such as threads, concurrencies, connections,
-run time, overwrite, miss rate, key size, value size, get/set proportion,
-expected throughput, and so on. Furthermore, it also testss data
+memaslap is a load generation and benchmark tool for :program:`memcached()`
+servers. It generates configurable workload such as threads, concurrencies, connections, run time, overwrite, miss rate, key size, value size, get/set proportion, expected throughput, and so on. Furthermore, it also testss data
 verification, expire-time verification, UDP, binary protocol, facebook test,
 replication test, multi-get and reconnection, etc.
 
@@ -31,8 +29,8 @@ the threads don't communicate with each other, and there are several socket
 connections in each thread. Each connection keeps key size distribution,
 value size distribution, and command distribution by itself.
 
-You can specify servers via the \ **--servers**\  option or via the
-environment variable \ ``MEMCACHED_SERVERS``\ .
+You can specify servers via the :option:`--servers` option or via the
+environment variable :envvar:`MEMCACHED_SERVERS`.
 
 
 --------
index 0a8314d9ae48d821f024122e0d27dc1cc51d9ce1..f7acb2971b92221db1a9a5747a4ae4a5a5b627fa 100644 (file)
@@ -26,19 +26,17 @@ Compile and link with -lmemcached
 DESCRIPTION
 -----------
 
-:manpage:`libmemcached(3)` behavior can be modified by use memcached_behavior_set().
-Default behavior is the library strives to be quick and accurate. Some
-behavior, while being faster, can also result in not entirely accurate
-behavior (for instance, memcached_set() will always respond with
-\ ``MEMCACHED_SUCCESS``\ ).
+:manpage:`libmemcached(3)` behavior can be modified by using :c:func:`memcached_behavior_set()`. Default behavior is the library strives to be quick and 
+accurate. Some behavior, while being faster, can also result in not entirely 
+accurate behavior (for instance, :c:func:`memcached_set()` will always respond 
+with :c:type:`MEMCACHED_SUCCESS`).
 
-memcached_behavior_get() takes a behavior flag and returns whether or not
-that behavior is currently enabled in the client.
+:c:func:`memcached_behavior_get()` takes a behavior flag and returns whether or not that behavior is currently enabled in the client.
 
-memcached_behavior_set() changes the value of a particular option of the
-client. It takes both a flag (listed below) and a value. For simple on or
-off options you just need to pass in a value of 1. Calls to
-memcached_behavior_set() will flush and reset all connections.
+:c:func:`memcached_behavior_set()` changes the value of a particular option 
+of the client. It takes both a flag (listed below) and a value. For simple 
+on or off options you just need to pass in a value of 1. Calls to
+:c:func:`memcached_behavior_set()` will flush and reset all connections.
 
 
 .. c:var:: MEMCACHED_BEHAVIOR_USE_UDP
@@ -46,27 +44,24 @@ memcached_behavior_set() will flush and reset all connections.
 Causes :manpage:`libmemcached(3)` to use the UDP transport when communicating
 with a memcached server. Not all I/O operations are testsed
 when this behavior is enababled. The following operations will return
-\ ``MEMCACHED_NOT_SUPPORTED``\  when executed with the MEMCACHED_BEHAVIOR_USE_UDP
-enabled: memcached_version(), memcached_stat(), memcached_get(),
-memcached_get_by_key(), memcached_mget(), memcached_mget_by_key(),
-memcached_fetch(), memcached_fetch_result(), memcached_value_fetch().
+:c:type:`MEMCACHED_NOT_SUPPORTED` when executed with the :c:type:`MEMCACHED_BEHAVIOR_USE_UDP` enabled: :c:func:`memcached_version()`, :c:func:`memcached_stat()`, :c:func:`memcached_get()`, :c:func:`memcached_get_by_key()`, :c:func:`memcached_mget()`, :c:func:`memcached_mget_by_key()`, :c:func:`memcached_fetch()`, :c:func:`memcached_fetch_result()`, :c:func:`memcached_value_fetch()`.
 
 All other operations are testsed but are executed in a 'fire-and-forget'
 mode, in which once the client has executed the operation, no attempt
 will be made to ensure the operation has been received and acted on by the
 server.
 
-:manpage:`libmemcached(3)` does not allow TCP and UDP servers to be shared within
-the same libmemached(3) client 'instance'. An attempt to add a TCP server
-when this behavior is enabled will result in a \ ``MEMCACHED_INVALID_HOST_PROTOCOL``\ ,
-as will attempting to add a UDP server when this behavior has not been enabled.
+:manpage:`libmemcached(3)` does not allow TCP and UDP servers to be shared 
+within the same libmemached(3) client 'instance'. An attempt to add a TCP 
+server when this behavior is enabled will result in a :c:type:`MEMCACHED_INVALID_HOST_PROTOCOL`, as will attempting to add a UDP server when this behavior has 
+not been enabled.
 
 
 
 .. c:var:: MEMCACHED_BEHAVIOR_NO_BLOCK
 
-Causes :manpage:`libmemcached(3)` to use asychronous IO. This is the fastest transport
-available for storage functions.
+Causes :manpage:`libmemcached(3)` to use asychronous IO. This is the fastest 
+transport available for storage functions.
 
 
 .. c:var:: MEMCACHED_BEHAVIOR_SND_TIMEOUT
@@ -91,11 +86,12 @@ environments).
 
 .. c:var:: MEMCACHED_BEHAVIOR_HASH
 
-Makes the default hashing algorithm for keys use MD5. The value can be set to either MEMCACHED_HASH_DEFAULT, MEMCACHED_HASH_MD5, MEMCACHED_HASH_CRC, MEMCACHED_HASH_FNV1_64, MEMCACHED_HASH_FNV1A_64, MEMCACHED_HASH_FNV1_32, MEMCACHED_HASH_FNV1A_32, MEMCACHED_HASH_JENKINS, MEMCACHED_HASH_HSIEH, and MEMCACHED_HASH_MURMUR.  
+Makes the default hashing algorithm for keys use MD5. The value can be set to either :c:type:`MEMCACHED_HASH_DEFAULT`, :c:type:`MEMCACHED_HASH_MD5`, :c:type:`MEMCACHED_HASH_CRC`, :c:type:`MEMCACHED_HASH_FNV1_64`, :c:type:`MEMCACHED_HASH_FNV1A_64`, :c:type:`MEMCACHED_HASH_FNV1_32`, :c:type:`MEMCACHED_HASH_FNV1A_32`, :c:type:`MEMCACHED_HASH_JENKINS`, :c:type:`MEMCACHED_HASH_HSIEH`, and :c:type:`MEMCACHED_HASH_MURMUR`.  
 
-Each hash has it's advantages and it's weaknesses. If you don't know or don't care, just go with the default.
+Each hash has it's advantages and it's weaknesses. If you don't know or don't 
+care, just go with the default.
 
-Support for MEMCACHED_HASH_HSIEH is a compile time option that is disabled by default. To enable tests for this hashing algorithm, configure and build libmemcached with the --enable-hash_hsieh.
+Support for :c:type:`MEMCACHED_HASH_HSIEH` is a compile time option that is disabled by default. To enable tests for this hashing algorithm, configure and build libmemcached with the --enable-hash_hsieh.
 
 
 
index bec57f8168bd9f9c00a376bd2171903f914850db..3cdd5adba1fe508516f6f0a524d5c156f9375c9a 100644 (file)
@@ -30,34 +30,40 @@ libmemcached(3) can have callbacks set key execution points. These either
 provide function calls at points in the code, or return pointers to
 structures for particular usages.
 
-memcached_callback_get() takes a callback flag and returns the structure or
-function set by memcached_callback_set().
+:c:func:`memcached_callback_get()` takes a callback flag and returns the 
+structure or function set by :c:func:`memcached_callback_set()`.
 
-memcached_callback_set() changes the function/structure assigned by a
+:c:func:`memcached_callback_set()` changes the function/structure assigned by a
 callback flag. No connections are reset.
 
-You can use MEMCACHED_CALLBACK_USER_DATA to provide custom context if required for any of the callbacks.
+You can use :c:type:`MEMCACHED_CALLBACK_USER_DATA` to provide custom context 
+if required for any of the callbacks.
 
 
 .. c:var:: MEMCACHED_CALLBACK_CLEANUP_FUNCTION
  
-When memcached_delete() is called this function will be excuted. At the point of its execution all connections are closed.
+When :c:func:`memcached_delete()` is called this function will be excuted. At 
+the point of its execution all connections are closed.
  
 
 
 .. c:var:: MEMCACHED_CALLBACK_CLONE_FUNCTION
  
-When memcached_delete() is called this function will be excuted. At the
-point of its execution all connections are closed.
+When :c:func:`memcached_delete()` is called this function will be excuted. 
+At the point of its execution all connections are closed.
  
 
 
 .. c:var:: MEMCACHED_CALLBACK_PREFIX_KEY
  
 You can set a value which will be used to create a domain for your keys.
-The value specified here will be prefixed to each of your keys. The value can not be greater then MEMCACHED_PREFIX_KEY_MAX_SIZE - 1 and will reduce MEMCACHED_MAX_KEY by the value of your key. 
+The value specified here will be prefixed to each of your keys. The value can 
+not be greater then :c:type:`MEMCACHED_PREFIX_KEY_MAX_SIZE - 1` and will 
+reduce :c:type:`MEMCACHED_MAX_KEY` by the value of your key. 
 
-The prefix key is only applied to the primary key, not the master key. MEMCACHED_FAILURE will be returned if no key is set. In the case of a key which is too long, MEMCACHED_BAD_KEY_PROVIDED will be returned.
+The prefix key is only applied to the primary key, not the master key. 
+:c:type:`MEMCACHED_FAILURE` will be returned if no key is set. In the case of 
+a key which is too long, :c:type:`MEMCACHED_BAD_KEY_PROVIDED` will be returned.
  
 If you set a value with the value being NULL then the prefix key is disabled.
 
@@ -65,26 +71,26 @@ If you set a value with the value being NULL then the prefix key is disabled.
 .. c:var:: MEMCACHED_CALLBACK_USER_DATA
  
 This allows you to store a pointer to a specifc piece of data. This can be
-retrieved from inside of memcached_fetch_execute(). Cloning a memcached_st
-will copy the pointer to the clone.
+retrieved from inside of :c:func:`memcached_fetch_execute()`. Cloning a 
+:c:type:`memcached_st` will copy the pointer to the clone.
  
 
 
 .. c:var:: MEMCACHED_CALLBACK_MALLOC_FUNCTION
  
-DEPRECATED: use memcached_set_memory_allocators instead.
+DEPRECATED: use :c:type:`memcached_set_memory_allocators` instead.
  
 
 
 .. c:var:: MEMCACHED_CALLBACK_REALLOC_FUNCTION
  
-DEPRECATED: use memcached_set_memory_allocators instead.
+DEPRECATED: use :c:type:`memcached_set_memory_allocators` instead.
  
 
 
 .. c:var:: MEMCACHED_CALLBACK_FREE_FUNCTION
  
-DEPRECATED: use memcached_set_memory_allocators instead.
+DEPRECATED: use :c:type:`memcached_set_memory_allocators` instead.
  
 
 
@@ -94,13 +100,16 @@ This function implements the read through cache behavior. On failure of retrieva
 
 You are responsible for populating the result object provided. This result object will then be stored in the server and returned to the calling process. 
 
-You must clone the memcached_st in order to
+You must clone the :c:type:`memcached_st` in order to
 make use of it. The value will be stored only if you return
-MEMCACHED_SUCCESS or MEMCACHED_BUFFERED. Returning MEMCACHED_BUFFERED will
-cause the object to be buffered and not sent immediatly (if this is the default behavior based on your connection setup this will happen automatically).
+:c:type:`MEMCACHED_SUCCESS` or :c:type:`MEMCACHED_BUFFERED`. Returning 
+:c:type:`MEMCACHED_BUFFERED` will cause the object to be buffered and not sent 
+immediatly (if this is the default behavior based on your connection setup 
+this will happen automatically).
  
 The prototype for this is:
-memcached_return_t (\*memcached_trigger_key)(memcached_st \*ptr, char \*key, size_t key_length, memcached_result_st \*result);
+
+.. c:function:: memcached_return_t (\*memcached_trigger_key)(memcached_st \*ptr, char \*key, size_t key_length, memcached_result_st \*result);
  
 
 
@@ -108,7 +117,9 @@ memcached_return_t (\*memcached_trigger_key)(memcached_st \*ptr, char \*key, siz
  
 This function implements a trigger upon successful deletion of a key. The memcached_st structure will need to be cloned in order to make use of it.
  
-The prototype for this is: typedef memcached_return_t (\*memcached_trigger_delete_key)(memcached_st \*ptr, char \*key, size_t key_length);
+The prototype for this is: 
+
+.. c:function:: typedef memcached_return_t (\*memcached_trigger_delete_key)(memcached_st \*ptr, char \*key, size_t key_length);
  
 
 
@@ -118,12 +129,12 @@ RETURN
 ------
 
 
-memcached_callback_get() return the function or structure that was provided.
-Upon error, nothing is set, null is returned, and the memcached_return_t
-argument is set to MEMCACHED_FAILURE.
+:c:func:`memcached_callback_get()` return the function or structure that was 
+provided. Upon error, nothing is set, null is returned, and the 
+:c:type:`memcached_return_t` argument is set to :c:type:`MEMCACHED_FAILURE`.
 
-memcached_callback_set() returns MEMCACHED_SUCCESS upon successful setting,
-otherwise MEMCACHED_FAILURE on error.
+:c:func:`memcached_callback_set()` returns :c:type:`MEMCACHED_SUCCESS` upon 
+successful setting, otherwise :c:type:`MEMCACHED_FAILURE` on error.
 
 
 ----
index 9d2188a6c4857d6ea238dd9e5888609ce5507401..c2138bc8979d18263acd91a46321bbfa6a17a2f5 100644 (file)
@@ -23,33 +23,30 @@ Compile and link with -lmemcached
 DESCRIPTION
 -----------
 
-memcached_cas() overwrites data in the server as long as the "cas" value is 
-still the same in the server. You can get the cas value of a result by 
-calling memcached_result_cas() on a memcached_result_st(3) structure. At the point 
-that this note was written cas is still buggy in memached. Turning on tests
-for it in libmemcached(3) is optional. Please see memcached_set() for 
-information on how to do this.
-
-memcached_cas_by_key() method behaves in a similar method as the non key 
-methods. The difference is that it uses the group_key parameter to map
-objects to particular servers.
-
-memcached_cas() is testsed with the \ ``MEMCACHED_BEHAVIOR_USE_UDP``\ 
-behavior enabled. However, when using these operations with this behavior on, there 
-are limits to the size of the payload being sent to the server.  The reason for 
-these limits is that the Memcached Server does not allow multi-datagram requests
-and the current server implementation sets a datagram size to 1400 bytes. Due 
-to protocol overhead, the actual limit of the user supplied data is less than 
-1400 bytes and depends on the protocol in use as, well as the operation being 
-executed. When running with the binary protocol, \ `` MEMCACHED_BEHAVIOR_BINARY_PROTOCOL``\ , 
-the size of the key,value, flags and expiry combined may not exceed 1368 bytes. 
-When running with the ASCII protocol, the exact limit fluctuates depending on 
-which function is being executed and whether the function is a cas operation 
-or not. For non-cas ASCII set operations, there are at least 1335 bytes available 
-to split among the key, key_prefix, and value; for cas ASCII operations there are 
-at least 1318 bytes available to split among the key, key_prefix and value. If the
-total size of the command, including overhead, exceeds 1400 bytes, a \ ``MEMCACHED_WRITE_FAILURE``\ 
-will be returned.
+:c:func:`memcached_cas()` overwrites data in the server as long as the "cas" 
+value is still the same in the server. You can get the cas value of a result 
+by calling :c:func:`memcached_result_cas()` on a memcached_result_st(3) 
+structure. At the point that this note was written cas is still buggy in memached. Turning on tests for it in libmemcached(3) is optional. Please see 
+:c:func:`memcached_set()` for information on how to do this.
+
+:c:func:`memcached_cas_by_key()` method behaves in a similar method as the non 
+key methods. The difference is that it uses the :c:type:`group_key` parameter 
+to map objects to particular servers.
+
+:c:func:`memcached_cas()` is testsed with the :c:type:`MEMCACHED_BEHAVIOR_USE_UDP` behavior enabled. However, when using these operations with this behavior 
+on, there are limits to the size of the payload being sent to the server.  The 
+reason for these limits is that the Memcached Server does not allow 
+multi-datagram requests and the current server implementation sets a datagram 
+size to 1400 bytes. Due to protocol overhead, the actual limit of the user 
+supplied data is less than 1400 bytes and depends on the protocol in use as, 
+well as the operation being executed. When running with the binary protocol, 
+:c:type:`MEMCACHED_BEHAVIOR_BINARY_PROTOCOL`, the size of the key,value, 
+flags and expiry combined may not exceed 1368 bytes. When running with the 
+ASCII protocol, the exact limit fluctuates depending on which function is 
+being executed and whether the function is a cas operation or not. For 
+non-cas ASCII set operations, there are at least 1335 bytes available to 
+split among the key, key_prefix, and value; for cas ASCII operations there 
+are at least 1318 bytes available to split among the key, key_prefix and value. If the total size of the command, including overhead, exceeds 1400 bytes, a :c:type:`MEMCACHED_WRITE_FAILURE` will be returned.
 
 
 ------
@@ -57,9 +54,10 @@ RETURN
 ------
 
 
-All methods return a value of type \ ``memcached_return_t``\ .
-On success the value will be \ ``MEMCACHED_SUCCESS``\ .
-Use memcached_strerror() to translate this value to a printable string.
+All methods return a value of type :c:type:`memcached_return_t`.
+On success the value will be :c:type:`MEMCACHED_SUCCESS`.
+Use :c:func:`memcached_strerror()` to translate this value to a printable 
+string.
 
 
 ----
@@ -76,5 +74,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemached(3) memcached_strerror(3) memcached_set(3) memcached_append(3) memcached_add(3) memcached_prepend(3) memcached_replace(3)
+:manpage:`memcached(1)` :manpage:`libmemached(3)` :manpage:`memcached_strerror(3)` :manpage:`memcached_set(3)` :manpage:`memcached_append(3)` :manpage:`memcached_add(3)` :manpage:`memcached_prepend(3)` :manpage:`memcached_replace(3)`
 
index 12bf92c5e5afdb8485ec75b2e9d4e428f50d6dbe..782b1a06b9682d5606d2c5d3250f959905cf8127 100644 (file)
@@ -25,25 +25,30 @@ Compile and link with -lmemcached
 DESCRIPTION
 -----------
 
-memcached_create() is used to create a \ ``memcached_st``\  structure that will then
-be used by other libmemcached(3) functions to communicate with the server. You
-should either pass a statically declared \ ``memcached_st``\  to memcached_create() or
+:c:func:`memcached_create()` is used to create a :c:type:`memcached_st` 
+structure that will then be used by other libmemcached(3) functions to 
+communicate with the server. You should either pass a statically declared 
+:c:type:`memcached_st` to :c:func:`memcached_create()` or
 a NULL. If a NULL passed in then a structure is allocated for you.
 
-Please note, when you write new application use memcached_create_with_options() over memcached_create().
+Please note, when you write new application use 
+:c:func:`memcached_create_with_options()` over 
+:c:func:`memcached_create()`.
 
-memcached_clone() is similar to memcached_create(3) but it copies the
-defaults and list of servers from the source \ ``memcached_st``\ . If you pass a null as
-the argument for the source to clone, it is the same as a call to memcached_create().
-If the destination argument is NULL a \ ``memcached_st``\  will be allocated for you.
+:c:func:`memcached_clone()` is similar to :c:func:`memcached_create()` but 
+it copies the defaults and list of servers from the source 
+:c:type:`memcached_st`. If you pass a null as the argument for the source 
+to clone, it is the same as a call to :c:func:`memcached_create()`.
+If the destination argument is NULL a :c:type:`memcached_st` will be allocated 
+for you.
 
-memcached_servers_reset() allows you to zero out the list of servers that
-the memcached_st has.
+:c:func:`memcached_servers_reset()` allows you to zero out the list of 
+servers that the :c:type:`memcached_st` has.
 
-To clean up memory associated with a \ ``memcached_st``\  structure you should pass
-it to memcached_free() when you are finished using it. memcached_free() is
-the only way to make sure all memory is deallocated when you finish using
-the structure.
+To clean up memory associated with a :c:type:`memcached_st` structure you 
+should pass it to :c:func:`memcached_free()` when you are finished using it. 
+:c:func:`memcached_free()` is the only way to make sure all memory is 
+deallocated when you finish using the structure.
 
 You may wish to avoid using memcached_create(3) or memcached_clone(3) with a
 stack based allocation. The most common issues related to ABI safety involve
@@ -55,11 +60,11 @@ RETURN
 ------
 
 
-memcached_create() returns a pointer to the memcached_st that was created
-(or initialized). On an allocation failure, it returns NULL.
+:c:func:`memcached_create()` returns a pointer to the :c:type:`memcached_st` 
+that was created (or initialized). On an allocation failure, it returns NULL.
 
-memcached_clone() returns a pointer to the memcached_st that was created
-(or initialized). On an allocation failure, it returns NULL.
+:c:func:`memcached_clone()` returns a pointer to the :c:type:`memcached_st` 
+that was created (or initialized). On an allocation failure, it returns NULL.
 
 
 ----
index 5c373b0847b7a0e9d68cc579faf808595e1acc44..acea40fafcd7de40f523cd48de891afb776fdae4 100644 (file)
@@ -22,9 +22,9 @@ DESCRIPTION
 -----------
 
 
-memcached_delete() is used to delete a particular key. 
-memcached_delete_by_key() works the same, but it takes a master key to
-find the given value.
+:c:func:`memcached_delete()` is used to delete a particular key. 
+:c:func:`memcached_delete_by_key()` works the same, but it takes a master key 
+to find the given value.
 
 Expiration works by placing the item into a delete queue, which means that
 it won't be possible to retrieve it by the "get" command. The "add" and 
@@ -40,9 +40,10 @@ RETURN
 ------
 
 
-A value of type \ ``memcached_return_t``\  is returned
-On success that value will be \ ``MEMCACHED_SUCCESS``\ .
-Use memcached_strerror() to translate this value to a printable string.
+A value of type :c:type:`memcached_return_t` is returned
+On success that value will be :c:type:`MEMCACHED_SUCCESS`.
+Use :c:func:`memcached_strerror()` to translate this value to a printable 
+string.
 
 If you are using the non-blocking mode of the library, success only
 means that the message was queued for delivery.
index 08c21c464d50f8434aa206bb0eb603ea3a5c6ae1..3ef1c43c0ec97decceaf425563678e4b9d1ef165 100644 (file)
@@ -28,9 +28,9 @@ DESCRIPTION
 -----------
 
 
-memcached_dump() is used to get a list of keys found in memcached(1) servers.
-Because memcached(1) does not guarentee to dump all keys you can not assume
-you have fetched all keys from the server. The function takes an array
+:c:func:`memcached_dump()` is used to get a list of keys found in memcached(1) 
+servers. Because memcached(1) does not guarentee to dump all keys you can not 
+assume you have fetched all keys from the server. The function takes an array
 of callbacks that it will use to execute on keys as they are found.
 
 Currently the binary protocol is not testsed.
@@ -41,9 +41,10 @@ RETURN
 ------
 
 
-A value of type \ ``memcached_return_t``\  is returned
-On success that value will be \ ``MEMCACHED_SUCCESS``\ .
-Use memcached_strerror() to translate this value to a printable string.
+A value of type :c:type:`memcached_return_t` is returned
+On success that value will be :c:type:`MEMCACHED_SUCCESS`.
+Use :c:func:`memcached_strerror()` to translate this value to a printable 
+string.
 
 
 ----
index 42453b355c6ad79b0b96ba221ce2ce83bb6e4803..a5c273de8730dfa9e1f2e45292f26252a12d7d02 100644 (file)
@@ -24,7 +24,7 @@ DESCRIPTION
 -----------
 
 
-:c:func::`memcached_flush()` is used to wipe clean the contents of memcached(1) servers.
+:c:func::`memcached_flush()` is used to wipe clean the contents of :program:`memcached` servers.
 It will either do this immediately or expire the content based on the
 expiration time passed to the method (a value of zero causes an immediate
 flush). The operation is not atomic to multiple servers, just atomic to a
@@ -37,11 +37,10 @@ RETURN
 ------
 
 
-A value of type :c:type:`memcached_return_t`  is returned
+A value of type :c:type:`memcached_return_t` is returned 
 On success that value will be :c:type:`MEMCACHED_SUCCESS`.
 Use :c:type:`memcached_strerror()` to translate this value to a printable string.
 
-
 ----
 HOME
 ----
index 5419c9008daecde62850de8429ea8547d26333f8..1a6088c26cf307f7d1fc6631d033efbef5852472 100644 (file)
@@ -23,9 +23,8 @@ DESCRIPTION
 -----------
 
 
-memcached_flush_buffers() is used in conjunction with 
-MEMCACHED_BEHAVIOR_BUFFER_REQUESTS (see memcached_behavior(3)) to flush
-all buffers by sending the buffered commands to the server for processing.
+:c:func:`memcached_flush_buffers()` is used in conjunction with 
+:c:type:`MEMCACHED_BEHAVIOR_BUFFER_REQUESTS` (see memcached_behavior(3)) to flush all buffers by sending the buffered commands to the server for processing.
 
 
 ------
@@ -33,9 +32,10 @@ RETURN
 ------
 
 
-A value of type \ ``memcached_return_t``\  is returned
-On success that value will be \ ``MEMCACHED_SUCCESS``\ .
-Use memcached_strerror() to translate this value to a printable string.
+A value of type :c:type:`memcached_return_t` is returned
+On success that value will be :c:type:`MEMCACHED_SUCCESS`.
+Use :c:func:`memcached_strerror()` to translate this value to a printable 
+string.
 
 
 ----
index 4bfe2f0781e95b678e1015dde907f0bd05e52a9c..3da05dfd87a7f48551af4986c1a88ebb3cc02797 100644 (file)
@@ -26,17 +26,17 @@ DESCRIPTION
 -----------
 
 
-memcached_generate_hash_value() allows you to hash a key using one of
+:c:func:`memcached_generate_hash_value()` allows you to hash a key using one of
 the hash functions defined in the library. This method is provided for
 the convenience of higher-level language bindings and is not necessary
 for normal memcache operations.
 
 The allowed hash algorithm constants are listed in the manpage for
-memcached_behavior_set().
+:c:func:`memcached_behavior_set()`.
 
-memcached_generate_hash() takes a memcached_st struture and produces
-the hash value that would have been generated based on the defaults
-of the memcached_st structure.
+:c:func:`memcached_generate_hash()` takes a :c:type:`memcached_st` struture 
+and produces the hash value that would have been generated based on the 
+defaults of the :c:type:`memcached_st structure`.
 
 As of version 0.36 all hash methods have been placed into the library
 libhashkit(3) which is linked with libmemcached(3). For more information please see its documentation.
index 2a87e9138042aa5e4c66a4ffc9780882043992a8..d3f5806ff1e6fef62889e13a98009269040f39a8 100644 (file)
@@ -37,75 +37,67 @@ DESCRIPTION
 -----------
 
 
-memcached_get() is used to fetch an individual value from the server. You
-must pass in a key and its length to fetch the object. You must supply
+:c:func:`memcached_get()` is used to fetch an individual value from the server. 
+You must pass in a key and its length to fetch the object. You must supply
 three pointer variables which will give you the state of the returned
-object.  A uint32_t pointer to contain whatever flags you stored with the value,
-a size_t pointer which will be filled with size of of the object, and a
-memcached_return_t pointer to hold any error. The object will be returned
-upon success and NULL will be returned on failure. Any object returned by
-memcached_get() must be released by the caller application.
-
-memcached_mget() is used to select multiple keys at once. For multiple key
-operations it is always faster to use this function. This function always
-works asynchronously. memcached_fetch() is then used to retrieve any keys
-found. No error is given on keys that are not found. You must call either
-memcached_fetch() or memcached_fetch_result() after a successful call to
-memcached_mget(). You should continue to call these functions until they
-return NULL (aka no more values). If you need to quit in the middle of a
-memcached_get() call, execute a memcached_quit(). After you do this, you can
-issue new queries against the server.
-
-memcached_fetch() is used to fetch an individual value from the server.
-memcached_mget() must always be called before using this method.  You
-must pass in a key and its length to fetch the object. You must supply
+object.  A :c:type:`uint32_t` pointer to contain whatever flags you stored with the value, a :c:type:`size_t` pointer which will be filled with size of of 
+the object, and a :c:type:`memcached_return_t` pointer to hold any error. The 
+object will be returned upon success and NULL will be returned on failure. Any 
+object returned by :c:func:`memcached_get()` must be released by the caller 
+application.
+
+:c:func:`memcached_mget()` is used to select multiple keys at once. For 
+multiple key operations it is always faster to use this function. This function always works asynchronously. :c:func:`memcached_fetch()` is then used to 
+retrieve any keys found. No error is given on keys that are not found. You 
+must call either :c:func:`memcached_fetch()` or 
+:c:func:`memcached_fetch_result()` after a successful call to
+:c:func:`memcached_mget()`. You should continue to call these functions until 
+they return NULL (aka no more values). If you need to quit in the middle of a
+:c:func:`memcached_get()` call, execute a :c:func:`memcached_quit()`. After you do this, you can issue new queries against the server.
+
+:c:func:`memcached_fetch()` is used to fetch an individual value from the server. :c:func:`memcached_mget()` must always be called before using this method.  
+You must pass in a key and its length to fetch the object. You must supply
 three pointer variables which will give you the state of the returned
-object.  A uint32_t pointer to contain whatever flags you stored with the value,
-a size_t pointer which will be filled with size of of the object, and a
-memcached_return_t pointer to hold any error. The object will be returned
-upon success and NULL will be returned on failure. :c:type:`MEMCACHD_END` is
-returned by the \*error value when all objects that have been found are
-returned.  The final value upon :c:type:`MEMCACHED_END` is null. Values
-returned by memcached_fetch() must be freed by the caller. memcached_fetch()
-will be DEPRECATED in the near future, memcached_fetch_result() should be
-used instead.
-
-memcached_fetch_result() is used to return a memcached_result_st(3) structure
-from a memcached server. The result object is forward compatible with changes
-to the server. For more information please refer to the memcached_result_st(3)
-help. This function will dynamically allocate a result structure for you
-if you do not pass one to the function.
-
-memcached_fetch_execute() is a callback function for result sets. Instead
-of returning the results to you for processing, it passes each of the
+object.  A :c:type:`uint32_t` pointer to contain whatever flags you stored with the value, a :c:type:`size_t` pointer which will be filled with size of of the 
+object, and a :c:type:`memcached_return_t` pointer to hold any error. The 
+object will be returned upon success and NULL will be returned on failure. :c:type:`MEMCACHD_END` is returned by the \*error value when all objects that have been found are returned. The final value upon :c:type:`MEMCACHED_END` is null. 
+Values returned by :c:func:`memcached_fetch()` must be freed by the caller. 
+:c:func:`memcached_fetch()` will be DEPRECATED in the near future, 
+c:func:`memcached_fetch_result()` should be used instead.
+
+:c:func:`memcached_fetch_result()` is used to return a :c:type:`memcached_result_st` structure from a memcached server. The result object is forward compatible 
+with changes to the server. For more information please refer to the 
+:c:type:`memcached_result_st` help. This function will dynamically allocate a 
+result structure for you if you do not pass one to the function.
+
+:c:func:`memcached_fetch_execute()` is a callback function for result sets. 
+Instead of returning the results to you for processing, it passes each of the
 result sets to the list of functions you provide. It passes to the function
-a memcached_st that can be cloned for use in the called function (it can not
-be used directly). It also passes a result set which does not need to be freed.
-Finally it passes a "context". This is just a pointer to a memory reference
-you supply the calling function. Currently only one value is being passed
-to each function call. In the future there will be an option to allow this
-to be an array.
-
-memcached_mget_execute() and memcached_mget_execute_by_key() is
-similar to memcached_mget(), but it may trigger the supplied callbacks
-with result sets while sending out the queries. If you try to perform
-a really large multiget with memcached_mget() you may encounter a
-deadlock in the OS kernel (it will fail to write data to the socket because
-the input buffer is full). memcached_mget_execute() solves this
-problem by processing some of the results before continuing sending
-out requests. Please note that this function is only available in the
-binary protocol.
-
-memcached_get_by_key() and memcached_mget_by_key() behave in a similar nature
-as memcached_get() and memcached_mget(). The difference is that they take
-a master key that is used for determining which server an object was stored
-if key partitioning was used for storage.
-
-All of the above functions are not tested when the \ ``MEMCACHED_BEHAVIOR_USE_UDP``\ 
-has been set. Executing any of these functions with this behavior on will result in
-\ ``MEMCACHED_NOT_SUPPORTED``\  being returned, or for those functions which do not return
-a \ ``memcached_return_t``\ , the error function parameter will be set to
-\ ``MEMCACHED_NOT_SUPPORTED``\ .
+a :c:type:`memcached_st` that can be cloned for use in the called 
+function (it can not be used directly). It also passes a result set which does 
+not need to be freed. Finally it passes a "context". This is just a pointer to 
+a memory reference you supply the calling function. Currently only one value 
+is being passed to each function call. In the future there will be an option 
+to allow this to be an array.
+
+:c:func:`memcached_mget_execute()` and :c:func:`memcached_mget_execute_by_key()`
+is similar to :c:func:`memcached_mget()`, but it may trigger the supplied 
+callbacks with result sets while sending out the queries. If you try to 
+perform a really large multiget with :c:func:`memcached_mget()` you may 
+encounter a deadlock in the OS kernel (it will fail to write data to the 
+socket because the input buffer is full). :c:func:`memcached_mget_execute()` 
+solves this problem by processing some of the results before continuing 
+sending out requests. Please note that this function is only available in 
+the binary protocol.
+
+:c:func:`memcached_get_by_key()` and :c:func:`memcached_mget_by_key()` behave 
+in a similar nature as :c:func:`memcached_get()` and :c:func:`memcached_mget()`.
+The difference is that they take a master key that is used for determining 
+which server an object was stored if key partitioning was used for storage.
+
+All of the above functions are not tested when the 
+:c:type:`MEMCACHED_BEHAVIOR_USE_UDP` has been set. Executing any of these 
+functions with this behavior on will result in :c:type:`MEMCACHED_NOT_SUPPORTED` being returned, or for those functions which do not return a :c:type:`memcached_return_t`, the error function parameter will be set to :c:type:`MEMCACHED_NOT_SUPPORTED`.
 
 
 ------
@@ -114,8 +106,9 @@ RETURN
 
 
 All objects returned must be freed by the calling application.
-memcached_get() and memcached_fetch() will return NULL on error. You must
-look at the value of error to determine what the actual error was.
+:c:func:`memcached_get()` and :c:func:`memcached_fetch()` will return NULL on 
+error. You must look at the value of error to determine what the actual error 
+was.
 
 :c:func:`memcached_fetch_execute()` return :c:type:`MEMCACHED_SUCCESS` if
 all keys were successful. :c:type:`MEMCACHED_NOTFOUND` will be return if no
@@ -125,8 +118,8 @@ keys at all were found.
 to :c:type:`MEMCACHED_END` upon successful conclusion.
 :c:type:`MEMCACHED_NOTFOUND` will be return if no keys at all were found.
 
-MEMCACHED_KEY_TOO_BIG is set to error whenever memcached_fetch() was used
-and the key was set larger then MEMCACHED_MAX_KEY, which was the largest
+:c:type:`MEMCACHED_KEY_TOO_BIG` is set to error whenever :c::func:`memcached_fetch()` was used
+and the key was set larger then :c:type:`MEMCACHED_MAX_KEY`, which was the largest
 key allowed for the original memcached ascii server.
 
 
index 33f3d3a72596ae6b6fa045af7594aae3ea4fb135..ce8af386d65baa587b44945d0c9012cc8e32a9bc 100644 (file)
@@ -39,18 +39,18 @@ DESCRIPTION
 libmemcached(3) allows you to specify your own memory allocators, optimized
 for your application. This enables libmemcached to be used inside of applications that have their own malloc implementation.
 
-memcached_set_memory_allocators() is used to set the memory allocators used
-by the memcached instance specified by ptr. Please note that you cannot
-override only one of the memory allocators, you have to specify a complete
-new set if you want to override one of them. All of the memory allocation
-functions should behave as specified in the C99 standard. Specify NULL as
-all functions to reset them to the default values.
+:c:func:`memcached_set_memory_allocators()` is used to set the memory 
+allocators used by the memcached instance specified by ptr. Please note that 
+you cannot override only one of the memory allocators, you have to specify a 
+complete new set if you want to override one of them. All of the memory 
+allocation functions should behave as specified in the C99 standard. Specify 
+NULL as all functions to reset them to the default values.
 
-memcached_get_memory_allocators() is used to get the currently used memory
-allocators by a mamcached handle.
+:c:func:`memcached_get_memory_allocators()` is used to get the currently used 
+memory allocators by a mamcached handle.
 
-memcached_get_memory_allocators_context() returns the void \* that was
-passed in during the call to memcached_set_memory_allocators().
+:c:func:`memcached_get_memory_allocators_context()` returns the void \* that 
+was passed in during the call to :c:func:`memcached_set_memory_allocators()`.
 
 The first argument to the memory allocator functions is a pointer to a
 memcached structure, the is passed as const and you will need to clone
@@ -72,8 +72,9 @@ RETURN
 ------
 
 
-memcached_set_memory_allocators() return MEMCACHED_SUCCESS upon success,
-and MEMCACHED_FAILURE if you don't pass a complete set of function pointers.
+:c:func:`memcached_set_memory_allocators()` return :c:type:`MEMCACHED_SUCCESS` 
+upon success, and :c:type:`MEMCACHED_FAILURE` if you don't pass a complete set 
+of function pointers.
 
 
 ----
index aa914e50ecd06b8f58a0cba4a733a2f42f3f9406..38d2b3a73137757d594bec0876205ce968b23176 100644 (file)
@@ -34,38 +34,35 @@ DESCRIPTION
 -----------
 
 
-memcached_pool() is used to create a connection pool of objects you may use
-to remove the overhead of using memcached_clone for short lived
-\ ``memcached_st``\ objects. Please see :manpage:`libmemcached_configuration` for details on the format of the configuration string.
-
-DEPRECATED memcached_pool_create() is used to create a connection pool of
-objects you may use to remove the overhead of using memcached_clone for
-short lived \ ``memcached_st``\ objects. The mmc argument should be an
-initialised \ ``memcached_st``\ structure, and a successfull invocation of
-memcached_pool_create takes full ownership of the variable (until it is
-released by memcached_pool_destroy).  The \ ``initial``\  argument specifies
-the initial size of the connection pool, and the \ ``max``\ argument
+:c:func:`memcached_pool()` is used to create a connection pool of objects you 
+may use to remove the overhead of using memcached_clone for short lived
+:c:type:`memcached_st` objects. Please see :manpage:`libmemcached_configuration` for details on the format of the configuration string.
+
+DEPRECATED :c:func:`memcached_pool_create()` is used to create a connection pool of objects you may use to remove the overhead of using 
+:c:type:`memcached_clone` for short lived :c:type:`memcached_st` objects. 
+The mmc argument should be an initialised :c:type:`memcached_st` structure, 
+and a successfull invocation of :c:type:`memcached_pool_create` takes full 
+ownership of the variable (until it is released by 
+:c:type:`memcached_pool_destroy`).  The :c:type:`initial` argument specifies 
+the  initial size of the connection pool, and the :c:type:`max` argument
 specifies the maximum size the connection pool should grow to. Please note
 that the library will allocate a fixed size buffer scaled to the max size of
 the connection pool, so you should not pass MAXINT or some other large
 number here.
 
-memcached_pool_destroy() is used to destroy the connection pool
-created with memcached_pool_create() and release all allocated
-resources. It will return the pointer to the \ ``memcached_st``\  structure
-passed as an argument to memcached_pool_create(), and returns the ownership
-of the pointer to the caller when created with memcached_pool_create,
-otherwise NULL is returned..
+:c:func:`memcached_pool_destroy()` is used to destroy the connection pool
+created with :c:func:`memcached_pool_create()` and release all allocated
+resources. It will return the pointer to the :c:type:`memcached_st` structure
+passed as an argument to :c:func:`memcached_pool_create()`, and returns the ownership of the pointer to the caller when created with :c:func:`memcached_pool_create()`, otherwise NULL is returned..
 
-memcached_pool_pop() is used to grab a connection structure from the
+:c:func:`memcached_pool_pop()` is used to grab a connection structure from the
 connection pool. The block argument specifies if the function should
 block and wait for a connection structure to be available if we try
 to exceed the maximum size.
 
-memcached_pool_push() is used to return a connection structure back to the pool.
+:c:func:`memcached_pool_push()` is used to return a connection structure back to the pool.
 
-memcached_pool_behavior_set() and memcached_pool_behagior_get() is
-used to get/set behavior flags on all connections in the pool.
+:c:func:`memcached_pool_behavior_set()` and :c:func:`memcached_pool_behagior_get()` is used to get/set behavior flags on all connections in the pool.
 
 
 ------
@@ -73,21 +70,19 @@ RETURN
 ------
 
 
-memcached_pool_create() returns a pointer to the newly created
-memcached_pool_st structure. On an allocation failure, it returns
+:c:func:`memcached_pool_create()` returns a pointer to the newly created
+:c:type:`memcached_pool_st` structure. On an allocation failure, it returns
 NULL.
 
-memcached_pool_destroy() returns the pointer (and ownership) to the
-memcached_st structure used to create the pool. If connections are in
+:c:func:`memcached_pool_destroy()` returns the pointer (and ownership) to the
+:c:type:`memcached_st` structure used to create the pool. If connections are in
 use it returns NULL.
 
-memcached_pool_pop() returns a pointer to a memcached_st structure
-from the pool (or NULL if an allocation cannot be satisfied).
+:c:func:`memcached_pool_pop()` returns a pointer to a :c:type:`memcached_st structure` from the pool (or NULL if an allocation cannot be satisfied).
 
-memcached_pool_push() returns MEMCACHED_SUCCESS upon success.
+:c:func:`memcached_pool_push()` returns :c:type:`MEMCACHED_SUCCESS` upon success.
 
-memcached_pool_behavior_get() and memcached_pool_behavior_get()
-returns MEMCACHED_SUCCESS upon success.
+:c:func:`memcached_pool_behavior_get()` and :c:func:`memcached_pool_behavior_get()` returns :c:type:`MEMCACHED_SUCCESS` upon success.
 
 
 ----
index 06e98e8fa856661edb4e8ffad16d5dc332624bcd..8377f63ce51c0c98abf4fd1b3fc68ef3ea5ce0c3 100644 (file)
@@ -19,15 +19,14 @@ DESCRIPTION
 -----------
 
 
-memcached_quit() will disconnect you from all currently connected servers.
-It will also reset the state of the connection (ie, any memcached_fetch() you
-are in the middle of will be terminated). This function is called
-automatically when you call memcached_free() on the \ ``memcached_st``\  structure.
+:c:func:`memcached_quit()` will disconnect you from all currently connected 
+servers. It will also reset the state of the connection (ie, any :c:func:`memcached_fetch()` you are in the middle of will be terminated). This function is 
+called automatically when you call :c:func:`memcached_free()` on the :c:type:`memcached_st` structure.
 
 You do not need to call this on your own. All operations to change server
 hashes and parameters will handle connections to the server for you. This
 function is provided mainly so that you can timeout your connections or
-reset connections during the middle of a memcached_fetch().
+reset connections during the middle of a :c:func:`memcached_fetch()`.
 
 
 ------
@@ -35,9 +34,9 @@ RETURN
 ------
 
 
-A value of type \ ``memcached_return``\  is returned
-On success that value will be \ ``MEMCACHED_SUCCESS``\ .
-Use memcached_strerror() to translate this value to a printable string.
+A value of type :c:type:`memcached_return` is returned
+On success that value will be :c:type:`MEMCACHED_SUCCESS`.
+Use :c:func:`memcached_strerror()` to translate this value to a printable string.
 
 
 ----
index dbbbfd20c36037b3aa98285a3b081985c34eb686..295b2229ebb669a2ede77e227de2a8d7723e50da 100644 (file)
@@ -41,51 +41,50 @@ DESCRIPTION
 -----------
 
 
-libmemcached(3) can optionally return a memcached_result_st which acts as a
-result object. The result objects have added benefits over the character
-pointer returns, in that they are forward compatible with new return items
-that future memcached servers may implement (the best current example of
-this is the CAS return item). The structures can also be reused, which will
-save on calls to malloc(3). It is suggested that you use result objects over
-char \* return functions.
+libmemcached(3) can optionally return a :c:type:`memcached_result_st` which 
+acts as a result object. The result objects have added benefits over the 
+character pointer returns, in that they are forward compatible with new 
+return items that future memcached servers may implement (the best current 
+example of this is the CAS return item). The structures can also be reused, 
+which will save on calls to malloc(3). It is suggested that you use result 
+objects over char \* return functions.
 
-The structure of memcached_result_st has been encapsulated, you should not
-write code to directly access members of the structure.
+The structure of :c:type:`memcached_result_st` has been encapsulated, you should
+not write code to directly access members of the structure.
 
-memcached_result_create() will either allocate memory for a
-memcached_result_st or will initialize a structure passed to it.
+:c:func:`memcached_result_create()` will either allocate memory for a
+:c:type:`memcached_result_st` or will initialize a structure passed to it.
 
-memcached_result_free() will deallocate any memory attached to the
+:c:func:`memcached_result_free()` will deallocate any memory attached to the
 structure. If the structure was also allocated, it will deallocate it.
 
-memcached_result_key_value() returns the key value associated with the
+:c:func:`memcached_result_key_value()` returns the key value associated with the
 current result object.
 
-memcached_result_key_length() returns the key length associated with the
-current result object.
+:c:func:`memcached_result_key_length()` returns the key length associated with 
+the current result object.
 
-memcached_result_value() returns the result value associated with the
+:c:func:`memcached_result_value()` returns the result value associated with the
 current result object.
 
-memcached_result_length() returns the result length associated with the
-current result object.
+:c:func:`memcached_result_length()` returns the result length associated with 
+the current result object.
 
-memcached_result_flags() returns the flags associated with the
+:c:func:`memcached_result_flags()` returns the flags associated with the
 current result object.
 
-memcached_result_cas() returns the cas associated with the
+:c:func:`memcached_result_cas()` returns the cas associated with the
 current result object. This value will only be available if the server
 tests it.
 
-memcached_result_set_value() takes a byte array and a size and sets
+:c:func:`memcached_result_set_value()` takes a byte array and a size and sets
 the result to this value. This function is used for trigger responses.
 
-void memcached_result_set_flags() takes a result structure and stores
+:c:func:`void memcached_result_set_flags()` takes a result structure and stores
 a new value for the flags field.
 
-void memcached_result_set_expiration(A) takes a result structure and stores
-a new value for the expiration field (this is only used by read through
-triggers).
+:c:func:`void memcached_result_set_expiration(A)` takes a result structure and stores a new value for the expiration field (this is only used by read 
+through triggers).
 
 You may wish to avoid using memcached_result_create(3) with a
 stack based allocation. The most common issues related to ABI safety involve
@@ -98,8 +97,8 @@ RETURN
 
 
 Varies, see particular functions. All structures must have
-memcached_result_free() called on them for cleanup purposes. Failure to
-do this will result in leaked memory.
+:c:func:`memcached_result_free()` called on them for cleanup purposes. Failure 
+to do this will result in leaked memory.
 
 
 ----
index 4dc4039c4f0aec375e754116b7cab5b8a1a36d1f..bd51348bff8d3df3e0f6a612e07f37c4af50bb68 100644 (file)
@@ -34,16 +34,16 @@ libsasl to perform SASL authentication.
 Please note that SASL requires the memcached binary protocol, and you have
 to specify the callbacks before you connect to the server.
 
-memcached_set_sasl_auth_data() is a helper function defining
+:c:func:`memcached_set_sasl_auth_data()` is a helper function defining
 the basic functionality for you, but it will store the username and password
 in memory. If you choose to use this method you have to call
-memcached_destroy_sasl_auth_data before calling memcached_free to avoid
-a memory leak. You should NOT call memcached_destroy_sasl_auth_data if you
-specify your own callback function with memcached_set_sasl_callbacks().
+:c:type:`memcached_destroy_sasl_auth_data` before calling 
+:c:type:`memcached_free` to avoid a memory leak. You should NOT call 
+:c:type:`memcached_destroy_sasl_auth_data` if you specify your own callback 
+function with :c:func:`memcached_set_sasl_callbacks()`.
 
-You as a client user have to initialize libsasl by using sasl_client_init
-before enabling it in libmemcached, and you have to shut down libsasl by
-calling sasl_done() when you are done using SASL from libmemcached.
+You as a client user have to initialize libsasl by using :c:type:`sasl_client_init` before enabling it in libmemcached, and you have to shut down libsasl by
+calling :c:func:`sasl_done()` when you are done using SASL from libmemcached.
 
 
 ------
@@ -51,9 +51,8 @@ RETURN
 ------
 
 
-memcached_get_sasl_callbacks() returns the callbacks currently used
-by this memcached handle.
-memcached_get_sasl_set_auth_data() returns MEMCACHED_SUCCESS upon success.
+:c:func:`memcached_get_sasl_callbacks()` returns the callbacks currently used
+by this memcached handle. :c:func:`memcached_get_sasl_set_auth_data()` returns :c:type:`MEMCACHED_SUCCESS` upon success.
 
 
 ----
index e7ec65c97ac938d225080299f79dbdd5046e4750..9a8c8fc2d1d1a27bc2f9f62c41586e5473779fc2 100644 (file)
@@ -36,30 +36,25 @@ DESCRIPTION
 
 
 libmemcached(3) operates on a list of hosts which are stored in
-memcached_server_st structures. You should not modify these structures
+:c:type:`memcached_server_st` structures. You should not modify these structures
 directly. Functions are provided to modify these structures (and more can be
 added, just ask!).
 
-:c:func:`memcached_server_list()` is used to provide an array of all defined hosts.
-This was incorrectly documented as "requiring free()" up till version 0.39.
+:c:func:`memcached_server_list()` is used to provide an array of all defined hosts. This was incorrectly documented as "requiring free()" up till version 0.39.
 
-:c:func:`memcached_server_list_free()` deallocates all memory associated with the array
-of memcached_server_st that you passed to it.
+:c:func:`memcached_server_list_free()` deallocates all memory associated with the array of :c:type:`memcached_server_st` that you passed to it.
 
 :c:func:`memcached_server_list_append()` adds a server to the end of a
-memcached_server_st array. On error null will be returned and the
-memcached_return_t pointer you passed into the function will be set with the
-appropriate error. If the value of port is zero, it is set to the default
+:c:type:`memcached_server_st` array. On error null will be returned and the
+:c:type:`memcached_return_t` pointer you passed into the function will be set with the appropriate error. If the value of port is zero, it is set to the default
 port of a memcached server.
 
 DEPRECATED :c:func:`memcached_servers_parse()`, please see :c:func:`memcached()`
 
-:c:func:`memcached_server_error()` can be used to look at the text of the last error 
-message sent by the server to to the client.
+:c:func:`memcached_server_error()` can be used to look at the text of the last error message sent by the server to to the client.
 
-Before version 0.39 these functions used a memcache_server_st \*. In 0.39
-memcached_server_st \* was aliased to :c:type:`memcached_server_list_st`. This was
-done for a style reason/to help clean up some concepts in the code.
+Before version 0.39 theses functions used a memcache_server_st \*. In 0.39
+memcached_server_st \* was aliased to :c:type:`memcached_server_list_st`. This was done for a style reason to help clean up some concepts in the code.
 
 
 ------
index e280071d56467e0e93775e16beb4db16e19481dc..72da276496b5db9be99e7b3500d11066e27c4c95 100644 (file)
@@ -38,52 +38,43 @@ DESCRIPTION
 :doc:`libmemcached` performs operations on a list of hosts. The order of
 these hosts determine routing to keys. Functions are provided to add keys to
 memcached_st structures. To manipulate lists of servers see
-:c:type:`memcached_server_st()`.
-
-:c:func:`memcached_server_count()` provides you a count of the current
-number of servers being used by a :c:type:`memcached_st`  structure.
-
-:c:func:`memcached_server_add()` pushes a single TCP server into the
-:c:type:`memcached_st` structure. This server will be placed at the end.
-Duplicate servers are allowed, so duplication is not checked. Executing this
-function with the :c:type:`MEMCACHED_BEHAVIOR_USE_UDP`  behavior set will
-result in a :c:type:`MEMCACHED_INVALID_HOST_PROTOCOL`.
-
-:c:func:`memcached_server_add_udp()` pushes a single UDP server into the
-:c:type:`memcached_st` structure. This server will be placed at the end.
-Duplicate servers are allowed, so duplication is not checked. Executing this
-function with out setting the :c:type:`MEMCACHED_BEHAVIOR_USE_UDP` behavior
-will result in a :c:type:`MEMCACHED_INVALID_HOST_PROTOCOL`.
-
-:c:func:`memcached_server_add_unix_socket()` pushes a single UNIX socket
-into the :c:type:`memcached_st`  structure. This UNIX socket will be placed
-at the end.  Duplicate servers are allowed, so duplication is not checked.
-The length of the filename must be one character less then
-:c:macro:`MEMCACHED_MAX_HOST_LENGTH`.
-
-:c:func:`memcached_server_push()` pushes an array of
-:c:type:`memcached_server_st` into the :c:type:`memcached_st` structure.
-These servers will be placed at the end.  Duplicate servers are allowed, so
-duplication is not checked. A copy is made of structure so the list provided
-(and any operations on the list) are not saved.
-
-:c:func:`memcached_server_by_key()` allows you to provide a key and retrieve
-the server which would be used for assignment. This structure is cloned from
-its original structure and must be freed. If NULL is returned you should
-consult \*error. The returning structure should be freed with
+memcached_server_st(3).
+
+:c:func:`memcached_server_count()` provides you a count of the current number of
+servers being used by a :c:type:`memcached_st` structure.
+
+:c:func:`memcached_server_add()` pushes a single TCP server into the :c:type:`memcached_st` structure. This server will be placed at the end. Duplicate servers
+ are allowed, so duplication is not checked. Executing this function with the :c:type:`MEMCACHED_BEHAVIOR_USE_UDP` behavior set will result in a :c:type:`MEMCACHED_INVALID_HOST_PROTOCOL`.
+
+:c:func:`memcached_server_add_udp()` pushes a single UDP server into the :c:type:`memcached_st` structure. This server will be placed at the end. Duplicate 
+servers are allowed, so duplication is not checked. Executing this function with out setting the :c:type:`MEMCACHED_BEHAVIOR_USE_UDP` behavior will result in a
+:c:type:`MEMCACHED_INVALID_HOST_PROTOCOL`.
+
+:c:func:`memcached_server_add_unix_socket()` pushes a single UNIX socket into the :c:type:`memcached_st` structure. This UNIX socket will be placed at the end.
+Duplicate servers are allowed, so duplication is not checked. The length
+of the filename must be one character less than :c:type:`MEMCACHED_MAX_HOST_LENGTH`.
+
+:c:func:`memcached_server_push()` pushes an array of :c:type:`memcached_server_st` into the :c:type:`memcached_st` structure. These servers will be placed at 
+the end. Duplicate servers are allowed, so duplication is not checked. A
+copy is made of structure so the list provided (and any operations on
+the list) are not saved.
+
+:c:func:`memcached_server_by_key()` allows you to provide a key and retrieve the
+server which would be used for assignment. This structure is cloned
+from its original structure and must be freed. If NULL is returned you
+should consult \*error. The returning structure should be freed with
 :c:func:`memcached_server_free()`.
 
-:c:func:`memcached_server_get_last_disconnect()` returns a pointer to the
-last server for which there was a connection problem. It does not mean this
-particular server is currently dead but if the library is reporting a server
+:c:func:`memcached_server_get_last_disconnect()` returns a pointer to the last 
+server for which there was a connection problem. It does not mean this 
+particular server is currently dead but if the library is reporting a server 
 is, the returned server is a very good candidate.
 
-:c:func:`memcached_server_cursor()` takes a memcached_st and loops through
-the list of hosts currently in the cursor calling the list of callback
-functions provided. You can optionally pass in a value via context which
-will be provided to each callback function. An error return from any
-callback will terminate the loop. :c:func:`memcached_server_cursor()` is
-passed the original caller memcached_st in its current state.
+:c:func:`memcached_server_cursor()` takes a memcached_st and loops through the 
+list of hosts currently in the cursor calling the list of callback 
+functions provided. You can optionally pass in a value via 
+context which will be provided to each callback function. An error
+return from any callback will terminate the loop. :c:func:`memcached_server_cursor()` is passed the original caller :c:type:`memcached_st` in its current state.
 
 
 ------
index db668b22c7439a028d28cf2514176362d8a7490b..29d8d24176aa6a744394d6c411a1564fd71387ae 100644 (file)
@@ -32,55 +32,43 @@ DESCRIPTION
 -----------
 
 
-memcached_set(), memcached_add(), and memcached_replace() are all used to
-store information on the server. All methods take a key, and its length to
-store the object. Keys are currently limited to 250 characters when using either a version of memcached(1) which is 1.4 or below, or when using the text protocol.
-You must supply both a value and a length. Optionally you
-may test an expiration time for the object and a 16 byte value (it is
-meant to be used as a bitmap). "flags" is a 4byte space that is stored alongside of the main value. Many sub libraries make use of this field, so in most cases users should avoid making use of it.
-
-memcached_set() will write an object to the server. If an object already
-exists it will overwrite what is in the server. If the object does not exist
-it will be written. If you are using the non-blocking mode this function
+:c:func:`memcached_set()`, :c:func:`memcached_add()`, and :c:func:`memcached_replace()` are all used to store information on the server. All methods take a key, and its length to store the object. Keys are currently limited to 250 characters when using either a version of memcached(1) which is 1.4 or below, or when using the text protocol. You must supply both a value and a length. Optionally you
+store the object. Keys are currently limited to 250 characters by the
+memcached(1) server. You must supply both a value and a length. Optionally you
+may test an expiration time for the object and a 16 byte value (it is meant to be used as a bitmap). "flags" is a 4byte space that is stored alongside of the main value. Many sub libraries make use of this field, so in most cases users should avoid making use of it.
+
+:c:func:`memcached_set()` will write an object to the server. If an object 
+already exists it will overwrite what is in the server. If the object does not 
+exist it will be written. If you are using the non-blocking mode this function
 will always return true unless a network error occurs.
 
-memcached_replace() replaces an object on the server. If the object is not
-found on the server an error occurs.
+:c:func:`memcached_replace()` replaces an object on the server. If the object is not found on the server an error occurs.
 
-memcached_add() adds an object to the server. If the object is found on the
-server an error occurs, otherwise the value is stored.
+:c:func:`memcached_add()` adds an object to the server. If the object is found on the server an error occurs, otherwise the value is stored.
 
-memcached_cas() overwrites data in the server as long as the "cas" value is 
-still the same in the server. You can get the cas value of a result by 
-calling memcached_result_cas() on a memcached_result_st(3) structure. At the point 
+:c:func:`memcached_cas()` overwrites data in the server as long as the "cas" 
+value is still the same in the server. You can get the cas value of a result by 
+calling :c:func:`memcached_result_cas()` on a memcached_result_st(3) structure. At the point 
 that this note was written cas is still buggy in memached. Turning on tests
 for it in libmemcached(3) is optional. Please see memcached_set() for 
 information on how to do this.
 
-memcached_set_by_key(), memcached_add_by_key(), and memcached_replace_by_key() 
-methods all behave in a similar method as the non key 
-methods. The difference is that they use their group_key parameter to map
+:c:func:`memcached_set_by_key()`, :c:func:`memcached_add_by_key()`, and :c:func:`memcached_replace_by_key()` methods all behave in a similar method as the non 
+key methods. The difference is that they use their group_key parameter to map
 objects to particular servers.
 
-If you are looking for performance, memcached_set() with non-blocking IO is 
-the fastest way to store data on the server.
-
-All of the above functions are testsed with the \ ``MEMCACHED_BEHAVIOR_USE_UDP``\ 
-behavior enabled. However, when using these operations with this behavior on, there 
-are limits to the size of the payload being sent to the server.  The reason for 
-these limits is that the Memcached Server does not allow multi-datagram requests
-and the current server implementation sets a datagram size to 1400 bytes. Due 
-to protocol overhead, the actual limit of the user supplied data is less than 
-1400 bytes and depends on the protocol in use as, well as the operation being 
-executed. When running with the binary protocol, \ `` MEMCACHED_BEHAVIOR_BINARY_PROTOCOL``\ , 
-the size of the key,value, flags and expiry combined may not exceed 1368 bytes. 
-When running with the ASCII protocol, the exact limit fluctuates depending on 
-which function is being executed and whether the function is a cas operation 
-or not. For non-cas ASCII set operations, there are at least 1335 bytes available 
-to split among the key, key_prefix, and value; for cas ASCII operations there are 
-at least 1318 bytes available to split among the key, key_prefix and value. If the
-total size of the command, including overhead, exceeds 1400 bytes, a \ ``MEMCACHED_WRITE_FAILURE``\ 
-will be returned.
+If you are looking for performance, :c:func:`memcached_set()` with non-blocking IO is the fastest way to store data on the server.
+
+All of the above functions are testsed with the :c:type:`MEMCACHED_BEHAVIOR_USE_UDP` behavior enabled. However, when using these operations with this behavior 
+on, there are limits to the size of the payload being sent to the server.  
+The reason for these limits is that the Memcached Server does not allow 
+multi-datagram requests and the current server implementation sets a datagram 
+size to 1400 bytes. Due to protocol overhead, the actual limit of the user supplied data is less than 1400 bytes and depends on the protocol in use as, well as the operation being 
+executed. When running with the binary protocol, :c:type:`MEMCACHED_BEHAVIOR_BINARY_PROTOCOL`, the size of the key,value, flags and expiry combined may not 
+exceed 1368 bytes. When running with the ASCII protocol, the exact limit fluctuates depending on which function is being executed and whether the function is a cas operation or not. For non-cas ASCII set operations, there are at least 
+1335 bytes available to split among the key, key_prefix, and value; for cas 
+ASCII operations there are at least 1318 bytes available to split among the key, key_prefix and value. If the total size of the command, including overhead, 
+exceeds 1400 bytes, a :c:type:`MEMCACHED_WRITE_FAILURE` will be returned.
 
 
 ------
@@ -88,12 +76,11 @@ RETURN
 ------
 
 
-All methods return a value of type \ ``memcached_return_t``\ .
-On success the value will be \ ``MEMCACHED_SUCCESS``\ .
-Use memcached_strerror() to translate this value to a printable string.
+All methods return a value of type :c:type:`memcached_return_t`.
+On success the value will be :c:type:`MEMCACHED_SUCCESS`.
+Use :c:func:`memcached_strerror()` to translate this value to a printable string.
 
-For memcached_replace() and memcached_add(), \ ``MEMCACHED_NOTSTORED``\  is a
-legitmate error in the case of a collision.
+For :c:func:`memcached_replace()` and :c:func:`memcached_add()`, :c:type:`MEMCACHED_NOTSTORED` is a legitmate error in the case of a collision.
 
 
 ----
@@ -110,5 +97,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemached(3) memcached_strerror(3) memcached_prepend(3) memcached_cas(3) memcached_append(3)
+:manpage:`memcached(1)` :manpage:`libmemached(3)` :manpage:`memcached_strerror(3)` :manpage:`memcached_prepend(3)` :manpage:`memcached_cas(3)` :manpage:`memcached_append(3)`
 
index 56cce256f856c676aa9540896cee34fd9c6f042d..2cd36b6b5cdbe49ddfad1feec9f57fe0d3bea07d 100644 (file)
@@ -33,34 +33,20 @@ DESCRIPTION
 
 libmemcached(3) has the ability to query a memcached server (or collection
 of servers) for their current state. Queries to find state return a
-\ ``memcached_stat_st``\  structure. You are responsible for freeing this structure.
-While it is possible to access the structure directly it is not advisable.
-<memcached_stat_get_value() has been provided to query the structure.
-
-memcached_stat_execute() uses the servers found in \ ``memcached_stat_st``\  and 
-executes a "stat" command on each server. args is an optional argument that 
-can be passed in to modify the behavior of "stats". You will need to supply
-a callback function that will be supplied each pair of values returned by
+:c:type:`memcached_stat_st` structure. You are responsible for freeing this structure. While it is possible to access the structure directly it is not advisable. :c:func:`memcached_stat_get_value()` has been provided to query the structure.
+
+:c:func:`memcached_stat_execute()` uses the servers found in :c:type:`memcached_stat_st` and executes a "stat" command on each server. args is an optional argument that can be passed in to modify the behavior of "stats". You will need to supply a callback function that will be supplied each pair of values returned by
 the memcached server.
 
-memcached_stat() fetches an array of \ ``memcached_stat_st``\  structures containing
-the state of all available memcached servers. The return value must be freed
-by the calling application. If called with the \ ``MEMCACHED_BEHAVIOR_USE_UDP``\ 
-behavior set, a NULL value is returned and the error parameter is set to 
-\ ``MEMCACHED_NOT_SUPPORTED``\ .
+:c:func:`memcached_stat()` fetches an array of :c:type:`memcached_stat_st` structures containing the state of all available memcached servers. The return value must be freed by the calling application. If called with the :c:type:`MEMCACHED_BEHAVIOR_USE_UDP` behavior set, a NULL value is returned and the error parameter is set to :c:type:`MEMCACHED_NOT_SUPPORTED`.
 
-memcached_stat_servername() can be used standalone without a \ ``memcached_st``\  to
-obtain the state of a particular server.  "args" is used to define a
-particular state object (a list of these are not provided for by either the
-:c:func:`memcached_stat_get_keys()` call nor are they defined in the
-memcached protocol). You must specify the hostname and port of the server
-you want to obtain information on.
+:c:func:`memcached_stat_servername()` can be used standalone without a :c:type:`memcached_st` to obtain the state of a particular server.  "args" is used to define a particular state object (a list of these are not provided for by either
+the :c:func:`memcached_stat_get_keys()` call nor are they defined in the memcached protocol). You must specify the hostname and port of the server you want to
+obtain information on.
 
-memcached_stat_get_value() returns the value of a particular state key. You
-specify the key you wish to obtain.  The key must be null terminated.
+:c:func:`memcached_stat_get_value()` returns the value of a particular state key. You specify the key you wish to obtain.  The key must be null terminated.
 
-:c:func:`memcached_stat_get_keys()` returns a list of keys that the server
-has state objects on. You are responsible for freeing this list.
+:c:func:`memcached_stat_get_keys()` returns a list of keys that the server has state objects on. You are responsible for freeing this list.
 
 A command line tool, memstat(1), is provided so that you do not have to write
 an application to do this.
@@ -73,7 +59,7 @@ RETURN
 
 Varies, see particular functions.
 
-Any method returning a \ ``memcached_stat_st``\  expects you to free the
+Any method returning a :c:type:`memcached_stat_st` expects you to free the
 memory allocated for it.
 
 
@@ -99,5 +85,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemcached(3) memcached_strerror(3)
+:manpage:`memcached(1)` :manpage:`libmemcached(3)` :manpage:`memcached_strerror(3)`
 
index ce5b1fa0b9bbbd7440b1c1ee76a2ed4c3fecc3a9..6f8f78214a2124d7f025fedcb0c376400916bc52 100644 (file)
@@ -21,15 +21,13 @@ DESCRIPTION
 -----------
 
 
-memcached_strerror() takes a \ ``memcached_return_t``\  value and returns a string
-describing the error.
+:c:func:`memcached_strerror()` takes a :c:type:`memcached_return_t` value and returns a string describing the error.
 
 This string must not be modified by the application.
 
-\ ``memcached_return_t``\  values are returned from nearly all libmemcached(3) functions.
+:c:type:`memcached_return_t` values are returned from nearly all libmemcached(3) functions.
 
-\ ``memcached_return_t``\  values are of an enum type so that you can set up responses
-with switch/case and know that you are capturing all possible return values.
+:c:type:`memcached_return_t` values are of an enum type so that you can set up responses with switch/case and know that you are capturing all possible return values.
 
 
 ------
@@ -37,7 +35,7 @@ RETURN
 ------
 
 
-memcached_strerror() returns a string describing a \ ``memcached_return_t``\  value.
+:c:func:`memcached_strerror()` returns a string describing a :c:type:`memcached_return_t` value.
 
 
 ----
@@ -55,5 +53,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemcached(3)
+:manpage:`memcached(1)` :manpage:`libmemcached(3)`
 
index 107d04752913796cb5d6cdb724841ad67f54b845..45482f70da4ae97315fb27b293659cca61b16fae 100644 (file)
@@ -39,11 +39,10 @@ DESCRIPTION
 libmemcached(3) allows you to store a pointer to a user specific data inside
 the memcached_st structure.
 
-memcached_set_user_data() is used to set the user specific data in the
-memcached_st structure.
+:c:func:`memcached_set_user_data()` is used to set the user specific data in the
+:c:type:`memcached_st` structure.
 
-memcached_get_user_data() is used to retrieve the user specific data in
-the memcached_st structure.
+:c:func:`memcached_get_user_data()` is used to retrieve the user specific data in the :c:type:`memcached_st` structure.
 
 
 ------
@@ -51,11 +50,9 @@ RETURN
 ------
 
 
-memcached_set_user_data() returns the previous value of the user specific 
-data.
+:c:func:`memcached_set_user_data()` returns the previous value of the user specific data.
 
-memcached_get_user_data() returns the current value uf the user specific
-data.
+:c:func:`memcached_get_user_data()` returns the current value uf the user specific data.
 
 
 ----
@@ -72,5 +69,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemcached(3)
+:manpage:`memcached(1)` :manpage:`libmemcached(3)`
 
index e90febb446eebb119e4a37493e4afb1a39b3d38e..1266660b6b87ae00bfe96e84aec8f570f811fb6c 100644 (file)
@@ -22,8 +22,8 @@ DESCRIPTION
 -----------
 
 
-memcached_verbosity() modifies the "verbosity" of the
-memcached(1) servers referenced in the \ ``memcached_st``\  parameter.
+:c:func:`memcached_verbosity()` modifies the "verbosity" of the
+memcached(1) servers referenced in the :c:type:`memcached_st`  parameter.
 
 
 ------
@@ -31,9 +31,11 @@ RETURN
 ------
 
 
-A value of type \ ``memcached_return_t``\  is returned
-On success that value will be \ ``MEMCACHED_SUCCESS``\ .
-Use memcached_strerror() to translate this value to a printable string.
+A value of type :c:type:`memcached_return_t` is returned.
+
+On success that value will be :c:type:`MEMCACHED_SUCCESS`.
+
+Use :c:func:`memcached_strerror()` to translate this value to a printable string.
 
 
 ----
@@ -50,5 +52,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemcached(3) memcached_strerror(3)
+:manpage:`memcached(1)` :manpage:`libmemcached(3)` :manpage:`memcached_strerror(3)`
 
index ae983f4c49d81adbb2abeec9dbbf0ef9506bbf09..6d81f5ea16158e10c40b0fe980fd1b9c45c9d654 100644 (file)
@@ -23,12 +23,9 @@ DESCRIPTION
 -----------
 
 
-memcached_lib_version() is used to return a simple version string representing
-the libmemcached version (client library version, not server version)
+:c:func:`memcached_lib_version()` is used to return a simple version string representing the libmemcached version (client library version, not server version)
 
-memcached_version() is used to set the major, minor, and micro versions of each
-memcached server being used by the memcached_st connection structure. It returns the 
-memcached server return code.
+:c:func:`memcached_version()` is used to set the major, minor, and micro versions of each memcached server being used by the memcached_st connection structure. It returns the memcached server return code.
 
 
 ------
@@ -36,13 +33,15 @@ RETURN
 ------
 
 
-A string with the version of libmemcached driver is returned from
-memcached_lib_version()
+:c:func:`memcached_lib_version()` returns a string with the version of the libmemcached driver.
 
-A value of type \ ``memcached_return_t``\  is returned from memcached_version()
-On success that value will be \ ``MEMCACHED_SUCCESS``\ . If called with the
-\ ``MEMCACHED_BEHAVIOR_USE_UDP``\  behavior set, the value \ ``MEMCACHED_NOT_SUPPORTED``\  
-will be returned. Use memcached_strerror() to translate this value to 
+A value of :c:type:`memcached_return_t` is returned from :c:func:'memcached_version()'
+
+On success that value will be :c:type:`MEMCACHED_SUCCESS`. 
+
+If called with the :c:func:`MEMCACHED_BEHAVIOR_USE_UDP` behavior set, the value :c:type:`MEMCACHED_NOT_SUPPORTED` will be returned. 
+
+Use :c:func:`memcached_strerror()` to translate this value to 
 a printable string.
 
 
@@ -60,5 +59,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemcached(3) memcached_strerror(3)
+:manpage:`memcached(1)` :manpage:`libmemcached(3)` :manpage:`memcached_strerror(3)`
 
index 63e878456ea0fdbecd6d4bb348204305a4002186..28988046301bf36fc1a1323a0a85339180d0128c 100644 (file)
@@ -15,6 +15,28 @@ SYNOPSIS
 
 .. program:: memcapable
 
+-----------
+DESCRIPTION
+-----------
+
+:program:`memcapable` connects to the specified memcached server and tries to
+determine its capabilities by running the various commands and verifying
+the response.
+
+
+-----------
+LIMITATIONS
+-----------
+
+
+The current version of memcapable will only verify the binary protocol.
+
+
+-------
+OPTIONS
+-------
+
+
 .. option:: -h hostname
  
 Specify the hostname to connect to. The default is \ *localhost*\ 
@@ -23,40 +45,18 @@ Specify the hostname to connect to. The default is \ *localhost*\
  
 Specify the port number to connect to. The default is \ *11211*\ 
  
-
-
 .. option:: -c
  
 Generate a coredump when it detects an error from the server.
  
-
-
 .. option:: -v
  
 Print out the comparison when it detects an error from the server.
  
-
-
 .. option:: -t n
  
 Set the timeout from an IO operation to/from the server to \ *n*\  seconds.
  
------------
-DESCRIPTION
------------
-
-\ **memcapable**\  connects to the specified memcached server and tries to
-determine its capabilities by running the various commands and verifying
-the response.
-
-
------------
-LIMITATIONS
------------
-
-
-The current version of memcapable will only verify the binary protocol.
-
 
 ----
 HOME
index 8fa8268a4d9bb9d5b5dd407695f3b530e01d513d..5c10220750f3e4d608fb6b7b33dcf6132a1bdd77 100644 (file)
@@ -15,23 +15,34 @@ SYNOPSIS
 
 .. program:: memcat
 
-.. option:: --help
-
 
 -----------
 DESCRIPTION
 -----------
 
 
-\ **memcat**\  outputs to stdout the value a single or multiple set of keys
+:program:`memcat` outputs to stdout the value a single or multiple set of keys
 stored in a memcached(1) server. If any key is not found an error is returned.
 
 It is similar to the standard UNIX cat(1) utility.
 
-You can specify servers via the \ **--servers**\  option or via the
-environment variable \ ``MEMCACHED_SERVERS``\ .
 
-For a full list of operations run the tool with the \ **--help**\  option.
+-------
+OPTIONS
+-------
+
+
+You can specify servers via the option:
+
+.. option:: --servers
+
+or via the environment variable:
+
+.. envvar:: `MEMCACHED_SERVERS`
+
+For a full list of operations run the tool with the option:
+
+.. option:: --help
 
 
 ----
@@ -58,5 +69,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemcached(3)
+:manpage:`memcached(1)` :manpage:`libmemcached(3)`
 
index 7e620ccaf10fc3e5a6595311ca9cfd19060a0700..1ae451147206e7b4c121e5f44a789b35e0f6125c 100644 (file)
@@ -14,25 +14,37 @@ SYNOPSIS
 
 .. program:: memcp
 
-.. option:: --help
-
 
 -----------
 DESCRIPTION
 -----------
 
 
-\ **memcp**\  copies one or more files into memcached(1) servers.
+:program:`memcp` copies one or more files into memcached(1) servers.
 It is similar to the standard UNIX cp(1) command.
 
 The key names will be the names of the files,
 without any directory path.
 
-You can specify servers via the \ **--servers**\  option or via the
-environment variable \ ``MEMCACHED_SERVERS``\. If you do not specify either these, the final value in the command line list is the name of a
-server(s).
 
-For a full list of operations run the tool with the \ **--help**\  option.
+-------
+OPTIONS
+-------
+
+
+You can specify servers via the option:
+
+.. option:: --servers
+
+or via the environment variable:
+
+.. envvar:: `MEMCACHED_SERVERS`
+
+If you do not specify either these, the final value in the command line list is the name of a server(s).
+
+For a full list of operations run the tool with the option:
+
+.. option:: --help
 
 
 ----
@@ -59,5 +71,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemcached(3)
+:manpage:`memcached(1)` :manpage:`libmemcached(3)`
 
index fbdb8c1c163df162f1f17368af9279f9f1f5bdce..ab7bd02e57c4fb0016ac1c641bd5811be98bc999 100644 (file)
@@ -14,18 +14,24 @@ SYNOPSIS
 
 .. program:: memdump
 
-.. option:: --help
-
 -----------
 DESCRIPTION
 -----------
 
 
-\ **memdump**\  dumps a list of "keys" from all servers that 
+:program:`memdump`  dumps a list of "keys" from all servers that 
 it is told to fetch from. Because memcached does not guarentee to
 provide all keys it is not possible to get a complete "dump".
 
-For a full list of operations run the tool with the \ **--help**\  option.
+
+-------
+OPTIONS
+-------
+
+
+For a full list of operations run the tool with option:
+
+.. option:: --help
 
 
 ----
@@ -37,6 +43,14 @@ To find out more information please check:
 `http://libmemcached.org/ <http://libmemcached.org/>`_
 
 
+------
+AUTHOR
+------
+
+
+Brian Aker, <brian@tangent.org>
+
+
 --------
 SEE ALSO
 --------
index 16ee6147352d01c61774fe888eac8a42c8fbf801..aa298993b5fb1a1466746e25bb18ce5d2715a723 100644 (file)
@@ -14,17 +14,23 @@ SYNOPSIS
 
 .. program:: memerror
 
-.. option:: --help
-
 -----------
 DESCRIPTION
 -----------
 
 
-\ **memerror**\  translate an error code from libmemcached(3) into a human
+:program:`memerror` translates an error code from libmemcached(3) into a human
 readable string.
 
-For a full list of operations run the tool with the \ **--help**\  option.
+
+-------
+OPTIONS
+-------
+
+
+For a full list of operations run the tool with option:
+
+.. option:: --help
 
 
 ----
@@ -36,10 +42,17 @@ To find out more infoerroration please check:
 `http://libmemcached.org/ <http://libmemcached.org/>`_
 
 
+------
+AUTHOR
+------
+
+
+Brian Aker, <brian@tangent.org>
+
+
 --------
 SEE ALSO
 --------
 
 
-memcached(1) libmemcached(3)
-
+:manpage:`memcached(1)` :manpage:`libmemcached(3)`
index e02969bd2106e26127bc2b413669ddbf7ba537cb..d2cb644fd2b6b85fe125e172f0388851d940e7b7 100644 (file)
@@ -14,20 +14,31 @@ SYNOPSIS
 
 .. program:: memflush
 
-.. option:: --help
-
 -----------
 DESCRIPTION
 -----------
 
 
-\ **memflush**\  resets the contents of memcached(1) servers.
+:program:`memflush`  resets the contents of memcached(1) servers.
 This means that all data in the specified servers will be deleted.
 
-You can specify servers via the \ **--servers**\  option or via the
-environment variable \ ``MEMCACHED_SERVERS``\ .
 
-For a full list of operations run the tool with the \ **--help**\  option.
+-------
+OPTIONS
+-------
+
+
+You can specify servers via the option:
+
+.. option:: --servers
+
+or via the environment variable:
+
+.. envvar:: `MEMCACHED_SERVERS`
+
+For a full list of operations run the tool with option:
+
+.. option:: --help
 
 
 ----
@@ -53,4 +64,4 @@ Mark Atwood <mark@fallenpegasus.com>
 SEE ALSO
 --------
 
-memcached(1) libmemcached(3)
+:manpage:`memcached(1)` :manpage:`libmemcached(3)`
index 4dad9f75a190d7e20c7d1cce815eed7fa28c7c60..7b34b029a4a71ed18178f406efc8bc2941f35ef8 100644 (file)
@@ -14,21 +14,33 @@ SYNOPSIS
 
 .. program:: memrm
 
-.. option:: --help
-
-
 
 -----------
 DESCRIPTION
 -----------
 
 
-\ **memrm**\  removes items, specified by key, from memcached(1) servers.
+:program:`memrm`  removes items, specified by key, from memcached(1) servers.
+
+
+-------
+OPTIONS
+-------
+
+
+You can specify servers via the option:
+
+.. option:: --servers
+
+or via the environment variable:
+
+.. envvar:: `MEMCACHED_SERVERS`
+
+For a full list of operations run the tool with the
+
+.. option:: --help
 
-You can specify servers via the \ **--servers**\  option or via the
-environment variable \ ``MEMCACHED_SERVERS``\ .
 
-For a full list of operations run the tool with the \ **--help**\  option.
 
 
 ----
@@ -55,5 +67,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemcached(3)
+:manpage:`memcached(1)` :manpage:`libmemcached(3)`
 
index 1996b99f779b4cf4f6b03622994244bfb32f9963..c99abd774d9113eede45c386e3834d9744f085f0 100644 (file)
@@ -12,17 +12,48 @@ SYNOPSIS
 
 .. program::  memslap
 
-.. option:: --help
-
 -----------
 DESCRIPTION
 -----------
 
 
-\ **memslap**\  is a load generation and benchmark tool for memcached(1)
+:program:`memslap` is a load generation and benchmark tool for memcached(1)
 servers. It generates configurable workload such as threads, concurrencies, connections, run time, overwrite, miss rate, key size, value size, get/set proportion, expected throughput, and so on. 
 
-You can specify servers via the \ **--servers**\  option or via the environment variable \ ``MEMCACHED_SERVERS``\ .
+
+-------
+OPTIONS
+-------
+
+
+You can specify servers via the option:
+
+.. option:: --servers  
+
+or via the environment variable:
+
+.. envvar:: `MEMCACHED_SERVERS`
+
+For a full list of operations run the tool with:
+
+.. option:: --help
+
+
+----
+HOME
+----
+
+
+To find out more information please check:
+'http://libmemcached.org/ <http://libmemcached.org/>'_
+
+
+------
+AUTHOR
+------
+
+
+Brian Aker, <brian@tangent.org>
 
 
 --------
index e5aa0e0640d2a64e2e94f7af08ca16fd7f3d6b6a..550c346f35057d3f88b2963be9f5f7ea557d3a00 100644 (file)
@@ -14,22 +14,33 @@ SYNOPSIS
 
 .. program:: memstat
 
-.. option:: --help
-
 -----------
 DESCRIPTION
 -----------
 
 
-\ **memstat**\  dumps the state of memcached(1) servers.
+:program:`memstat`  dumps the state of memcached(1) servers.
 It displays all data to stdout.
 
-You can specify servers via the \ **--servers**\  option or via the
-environment variable \ ``MEMCACHED_SERVERS``\ . \ **--args**\  can be used
-to specify the "argument" sent to the stats command (ie slab, size, items,
-etc..).
 
-For a full list of operations run the tool with the \ **--help**\  option.
+-------
+OPTIONS
+-------
+
+
+You can specify servers via the option:
+
+.. option:: --servers  
+
+or via the environment variable:
+
+.. envvar:: 'MEMCACHED_SERVERS, --args'
+
+which can be used to specify the "argument" sent to the stats command (ie slab, size, items, etc..).
+
+For a full list of operations run the tool with:
+
+.. option:: --help
 
 
 ----
@@ -46,5 +57,5 @@ SEE ALSO
 --------
 
 
-memcached(1) libmemcached(3)
+:manpage:`memcached(1)` :manpage:`libmemcached(3)`
 
index 7dfd9d71034bfd79e893ef1b31778e0b97813f5e..32bf8ce37d9301bd6139feb77aecb041e1e3a07b 100644 (file)
@@ -186,7 +186,7 @@ static memcached_return_t update_continuum(memcached_st *ptr)
     memcached_continuum_item_st *new_ptr;
 
     new_ptr= static_cast<memcached_continuum_item_st*>(libmemcached_realloc(ptr, ptr->ketama.continuum,
-                                                                           sizeof(memcached_continuum_item_st) * (live_servers + MEMCACHED_CONTINUUM_ADDITION) * points_per_server));
+                                                                            sizeof(memcached_continuum_item_st) * (live_servers + MEMCACHED_CONTINUUM_ADDITION) * points_per_server));
 
     if (new_ptr == 0)
       return MEMCACHED_MEMORY_ALLOCATION_FAILURE;
@@ -259,8 +259,8 @@ static memcached_return_t update_continuum(memcached_st *ptr)
           for (uint32_t x= 0; x < pointer_per_hash; x++)
           {
             uint32_t value= ketama_server_hash(sort_host, (size_t)sort_host_length, x);
-             ptr->ketama.continuum[continuum_index].index= host_index;
-             ptr->ketama.continuum[continuum_index++].value= value;
+            ptr->ketama.continuum[continuum_index].index= host_index;
+            ptr->ketama.continuum[continuum_index++].value= value;
           }
         }
         else
@@ -307,9 +307,9 @@ static memcached_return_t update_continuum(memcached_st *ptr)
         {
           for (uint32_t x = 0; x < pointer_per_hash; x++)
           {
-             uint32_t value= ketama_server_hash(sort_host, (size_t)sort_host_length, x);
-             ptr->ketama.continuum[continuum_index].index= host_index;
-             ptr->ketama.continuum[continuum_index++].value= value;
+            uint32_t value= ketama_server_hash(sort_host, (size_t)sort_host_length, x);
+            ptr->ketama.continuum[continuum_index].index= host_index;
+            ptr->ketama.continuum[continuum_index++].value= value;
           }
         }
         else
@@ -494,3 +494,20 @@ static memcached_return_t server_add(memcached_st *ptr, const char *hostname,
 
   return run_distribution(ptr);
 }
+
+memcached_return_t memcached_server_add_parsed(memcached_st *ptr,
+                                               const char *hostname,
+                                               size_t hostname_length,
+                                               in_port_t port,
+                                               uint32_t weight)
+{
+  char buffer[NI_MAXHOST];
+
+  memcpy(buffer, hostname, hostname_length);
+  buffer[hostname_length]= 0;
+
+  return server_add(ptr, buffer,
+                    port,
+                    weight,
+                    MEMCACHED_CONNECTION_TCP);
+}
index d5b5684f5fb1b703aba0ca19e6a28a91b6e7f5dd..9000454988f7ac99dbc2d27e7c8df0b955139e6d 100644 (file)
@@ -126,6 +126,13 @@ LIBMEMCACHED_API
 memcached_return_t memcached_server_add(memcached_st *ptr,
                                         const char *hostname, in_port_t port);
 
+LIBMEMCACHED_LOCAL
+  memcached_return_t memcached_server_add_parsed(memcached_st *ptr,
+                                                 const char *hostname,
+                                                 size_t hostname_length,
+                                                 in_port_t port,
+                                                 uint32_t weight);
+
 LIBMEMCACHED_API
 memcached_return_t memcached_server_add_udp_with_weight(memcached_st *ptr,
                                                         const char *hostname,