=head1 SYNOPSIS
-#include <memcached.h>
+ #include <memcached.h>
=head1 DESCRIPTION
"Memcached is a high-performance, distributed memory object caching
system, generic in nature, but intended for use in speeding up dynamic web
-applications by alleviating database load." (http://danga.com/memcached/)
+applications by alleviating database load." L<http://danga.com/memcached/>
-libmemcached has the aim of being a small, thread safe client library for
-memcached. The code has all been written with an eye to allow for both web
-and embedded usage. It handles the work behind route particular keys to
-specifc servers that you specify (and values are matched based on server
-order as supplied by you). See more about this via X.
+B<libmemcached> is a small, thread-safe client library for the
+memcached protocol. The code has all been written with an eye to allow
+for both web and embedded usage. It handles the work behind routing
+particular keys to specific servers that you specify (and values are
+matched based on server order as supplied by you).
The aim is to support multiple routing and hashing methods. Currently only
-two hashing methods are supported, a built quick routine, and MD5. For
-routing a simple modulous method is used currently.
+two hashing methods are supported, a quick built-in routine, and MD5. For
+routing, a simple modulus method is currently used.
-All operations are performance against memcached_st structure. These
-can either be dynamically allocated or statically allocated and initializd
-by memcached_create(3). Functions have been written in order to encapsulate
-the memcached_st (it is not recommended that you operate directly against
-the structure).
+All operations are performed against a C<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 C<memcached_st>. It is not
+recommended that you operate directly against the structure.
-Nearly all functions return a memcached_return value. This is documented in
-memcached_strerr(3).
+Nearly all functions return a C<memcached_return> value.
+This value can be translated to a printable string with memcached_strerr(3).
-memcached_st structures are thread safe, but each thread must contain its own structure (aka if you want to share these among threads you must provide your own locking). No global variables are used in this library.
+C<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.
-Some features of the library must be enabled through memcached_behavior_set(3).
+Some features of the library must be enabled through memcached_behavior_set().
Hope you enjoy it!
-
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 DESCRIPTION
-For full example, example test cases found in tests/*.c in the main
+For full examples, test cases are found in tests/*.c in the main
distribution. These are always up to date, and are used for each test run of
the library.
-=item Creating and Freeing structure
+=head2 Creating and Freeing structure
-memcached_st *memc;
-memcached_return rc;
-struct timeval start_time, end_time;
+ memcached_st *memc;
+ memcached_return rc;
-memc= memcached_create(NULL);
-...do stuff...
-memcached_free(memc);
+ memc= memcached_create(NULL);
+ ...do stuff...
+ memcached_free(memc);
The above code would create a connection and then free the connection when
finished.
-=item Connecting to servers
+=head2 Connecting to servers
-memcached_server_st *servers;
-memcached_st *memc= memcached_create(NULL);
-char servername[]= "0.example.com";
+ memcached_server_st *servers;
+ memcached_st *memc= memcached_create(NULL);
+ char servername[]= "0.example.com";
-servers= memcached_server_list_append(NULL, servername, 400, &rc);
+ servers= memcached_server_list_append(NULL, servername, 400, &rc);
-for (x= 0; x < 20; x++)
-{
- char buffer[SMALL_STRING_LEN];
+ for (x= 0; x < 20; x++)
+ {
+ char buffer[SMALL_STRING_LEN];
- snprintf(buffer, SMALL_STRING_LEN, "%u.example.com", 400+x);
- servers= memcached_server_list_append(servers, buffer, 401,
- &rc);
-}
-rc= memcached_server_push(memc, servers);
-memcached_server_free(servers);
-memcached_free(memc);
+ snprintf(buffer, SMALL_STRING_LEN, "%u.example.com", 400+x);
+ servers= memcached_server_list_append(servers, buffer, 401, &rc);
+ }
+ rc= memcached_server_push(memc, servers);
+ memcached_server_free(servers);
+ memcached_free(memc);
-In the above code we create a memc object that we then feed in a single
-hosts into. In the for loop we build a memcached_server_st* that we then
-later feed via memcached_server_push(3) into the memcached_st structure.
+In the above code you create a C<memcached_st> object that you then feed in a
+single host into. In the for loop you build a C<memcached_server_st>
+pointer that you then later feed via memcached_server_push() into the
+C<memcached_st> structure.
-We can reuse the memcached_server_st() object with multile memcached_st
+You can reuse the C<memcached_server_st> object with multile C<memcached_st>
structures.
-=item Adding a value to the server
+=head2 Adding a value to the server
char *key= "foo";
char *value;
It is best practice to always look at the return value of any operation.
-=item Fetching multiple values
+=head2 Fetching multiple values
memcached_return rc;
char *keys[]= {"fudge", "son", "food"};
x++;
}
-Notice that we freed values returned fromm memcached_fetch(3). The define
-MEMCACHED_MAX_KEY is provided for usage.
+Notice that you freed values returned from memcached_fetch(). The define
+C<MEMCACHED_MAX_KEY> is provided for usage.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
-memcached(1).
+memcached(1)
=cut
=head1 SYNOPSIS
-#include <memcached.h>
-
-memcached_return memcached_increment(memcached_st *ptr,
- char *key, size_t key_length,
- unsigned int offset,
- unsigned int *value);
-memcached_return memcached_decrement(memcached_st *ptr,
- char *key, size_t key_length,
- unsigned int offset,
- unsigned int *value);
+ #include <memcached.h>
+
+ memcached_return
+ memcached_increment (memcached_st *ptr,
+ char *key, size_t key_length,
+ unsigned int offset,
+ unsigned int *value);
+
+ memcached_return
+ memcached_decrement (memcached_st *ptr,
+ char *key, size_t key_length,
+ unsigned int offset,
+ unsigned int *value);
+
=head1 DESCRIPTION
memcached(1) servers have the ability to increment and decrement keys
(overflow and underflow are not detected). This gives you the ability to use
-servers to generate sequences of values.
+memcached to generate shared sequences of values.
memcached_increment() takes a key and keylength and increments the value by
the offset passed to it. The value is then returned via the unsigned int
=head1 RETURN
-memcached_increment() and memcached_decrement() return a memcached_return
-value. For information on this value see memcached_strerr(3).
+A value of type C<memcached_return> is returned.
+On success that value will be C<MEMCACHED_SUCCESS>.
+Use memcached_strerror() to translate this value to a printable string.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
+ #include <memcached.h>
-unsigned long long memcached_behavior_get(memcached_st *ptr, memcached_behavior flag);
-memcached_return memcached_behavior_set(memcached_st *ptr, memcached_behavior flag, void *data);
+ unsigned long long
+ memcached_behavior_get (memcached_st *ptr,
+ memcached_behavior flag);
-=head1 DESCRIPTION
+ memcached_return
+ memcached_behavior_set (memcached_st *ptr,
+ memcached_behavior flag,
+ void *data);
+=head1 DESCRIPTION
libmemcached(3) behavior can be modified by use memcached_behavior_set().
Default behavior is the library strives to be quick and accurate. Some
-behavior, like , while being faster can also result in not entirely accurate
-behavior (for instance memcached_set will always respond with
-MEMCACHED_SUCCES).
+behavior, while being faster, can also result in not entirely accurate
+behavior (for instance, memcached_set() will always respond with
+C<MEMCACHED_SUCCESS>).
memcached_behavior_get() takes a behavior flag and returns whether or not
that behavior is currently enabled in the client.
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.
-=item MEMCACHED_BEHAVIOR_NO_BLOCK,
+=over 4
-Causes libmemcached(3) to use asycronous IO. This is the fastest transport
+=item MEMCACHED_BEHAVIOR_NO_BLOCK
+
+Causes libmemcached(3) to use asychronous IO. This is the fastest transport
available.
-=item MEMCACHED_BEHAVIOR_TCP_NODELAY,
+=item MEMCACHED_BEHAVIOR_TCP_NODELAY
Turns on the no-delay feature for connecting sockets (may be faster in some
-setups).
+environments).
+
+=item MEMCACHED_BEHAVIOR_MD5_HASHING
-=item MEMCACHED_BEHAVIOR_MD5_HASHING,
+Makes the default hashing algorithm for keys use MD5.
-Makes the default hashing algorithm for keys use RSA's MD5.
+=back
=head1 RETURN
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
-memcached_st *memcached_create(memcached_st *ptr);
-void memcached_free(memcached_st *ptr);
+ #include <memcached.h>
-=head1 DESCRIPTION
+ memcached_st *memcached_create (memcached_st *ptr);
+
+ void memcached_free (memcached_st *ptr);
+=head1 DESCRIPTION
-memcached_create() is used to create a memcached_st structure that will then
-be used by other libmemcached functions to communicate with the server. You
-should either pass a statically declared memcached_st to memcached_create or
+memcached_create() is used to create a C<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<memcached_st> to memcached_create() or
a NULL. If a NULL passed in then a structure is allocated for you.
-To clean up memory associated with a memcached_st structure you should pass
+To clean up memory associated with a C<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.
=head1 RETURN
memcached_create() returns a pointer to the memcached_st that was created
-(or initialized). On an allocation failure, it returns null.
+(or initialized). On an allocation failure, it returns NULL.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
+ #include <memcached.h>
-memcached_return memcached_delete(memcached_st *ptr, char *key, size_t key_length,
- time_t expiration);
+ memcached_return
+ memcached_delete (memcached_st *ptr,
+ char *key, size_t key_length,
+ time_t expiration);
=head1 DESCRIPTION
memcached_delete() is used to delete a particular key. An expiration value
-can be applied so that the key is deleted after a set number of seconds.
+can be applied so that the key is deleted after that many seconds.
=head1 RETURN
-memcached_delete() returns memcached_return. The value on success will be MEMCACHED_SUCCESS. For all errors check with memcached_strerror().
-If you are using the non-blocking mode of the library, success only means
-that the message was queued for delivery.
+A value of type C<memcached_return> is returned
+On success that value will be C<MEMCACHED_SUCCESS>.
+Use 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.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
-memcached_return memcached_flush(memcached_st *ptr, time_t expiration);
+ #include <memcached.h>
-=head1 DESCRIPTION
+ memcached_return
+ memcached_flush (memcached_st *ptr,
+ time_t expiration);
+=head1 DESCRIPTION
-memcached_flush() is used to wipe clean the contents of memcached servers.
-It will either do this immediatly or expire the content based on the
+memcached_flush() is used to wipe clean the contents of memcached(1) 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
-single server. Aka it will flush the servers in the order that they were
+single server. That is, it will flush the servers in the order that they were
added.
=head1 RETURN
-memcached_flush() returns memcached_return. The value on success will be MEMCACHED_SUCCESS. For all errors check with memcached_strerror().
+A value of type C<memcached_return> is returned
+On success that value will be C<MEMCACHED_SUCCESS>.
+Use memcached_strerror() to translate this value to a printable string.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
-char *memcached_get(memcached_st *ptr, char *key, size_t key_length,
- size_t *value_length,
- uint16_t *flags,
- memcached_return *error);
-memcached_return memcached_mget(memcached_st *ptr,
- char **keys, size_t *key_length,
- unsigned int number_of_keys);
-char *memcached_fetch(memcached_st *ptr, char *key, size_t *key_length,
- size_t *value_length, uint16_t *flags,
- memcached_return *error);
+ #include <memcached.h>
-=head1 DESCRIPTION
+ char *memcached_get (memcached_st *ptr,
+ char *key, size_t key_length,
+ size_t *value_length,
+ uint16_t *flags,
+ memcached_return *error);
+
+ memcached_return
+ memcached_mget (memcached_st *ptr,
+ char **keys, size_t *key_length,
+ unsigned int number_of_keys);
+ char *memcached_fetch (memcached_st *ptr,
+ char *key, size_t *key_length,
+ size_t *value_length,
+ uint16_t *flags,
+ memcached_return *error);
+
+=head1 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
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 asyncronously. memcached_fetch() is then used to retrieve any keys
+works asynchronously. memcached_fetch() is then used to retrieve any keys
found. No error is given on keys that are not found.
memcached_fetch() is used to fetch an individual value from the server.
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.
+look at the value of error to determine what the actual error was.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
-void memcached_quit(memcached_st *ptr);
+ #include <memcached.h>
-=head1 DESCRIPTION
+ void memcached_quit (memcached_st *ptr);
+=head1 DESCRIPTION
memcached_quit() will disconnect you from all currently connected servers.
-It will also reset the state of the connection (aka any memcached_fetch you
+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.
+automatically when you call memcached_free() on the C<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
=head1 RETURN
-memcached_quit() returns memcached_return. The value on success will be MEMCACHED_SUCCESS. For all errors check with memcached_strerror().
+A value of type C<memcached_return> is returned
+On success that value will be C<MEMCACHED_SUCCESS>.
+Use memcached_strerror() to translate this value to a printable string.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
+ #include <memcached.h>
-void memcached_server_list_free(memcached_server_st *ptr);
-memcached_server_st *memcached_server_list_append(memcached_server_st *ptr,
- char *hostname, unsigned int port,
- memcached_return *error);
-unsigned int memcached_server_list_count(memcached_server_st *ptr);
-memcached_server_st *memcached_servers_parse(char *server_strings);
+ void memcached_server_list_free (memcached_server_st *ptr);
-=head1 DESCRIPTION
+ memcached_server_st *
+ memcached_server_list_append (memcached_server_st *ptr,
+ char *hostname,
+ unsigned int port,
+ memcached_return *error);
+
+ unsigned int memcached_server_list_count (memcached_server_st *ptr);
+ memcached_server_st *memcached_servers_parse (char *server_strings);
+
+=head1 DESCRIPTION
libmemcached(3) operates on a list of hosts which are stored in
memcached_server_st structures. You should not modify these structures
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
+ #include <memcached.h>
-unsigned int memcached_server_count(memcached_st *ptr);
-memcached_server_st *memcached_server_list(memcached_st *ptr);
-memcached_return memcached_server_add(memcached_st *ptr, char *hostname, unsigned int port);
-memcached_return memcached_server_push(memcached_st *ptr, memcached_server_st *list);
+ unsigned int memcached_server_count (memcached_st *ptr);
-=head1 DESCRIPTION
+ memcached_server_st *
+ memcached_server_list (memcached_st *ptr);
+
+ memcached_return
+ memcached_server_add (memcached_st *ptr,
+ char *hostname,
+ unsigned int port);
+ memcached_return
+ memcached_server_push (memcached_st *ptr,
+ memcached_server_st *list);
+
+=head1 DESCRIPTION
libmemcached(3) 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 server_st(3).
+memcached_st structures. To manipulate lists of servers see
+memcached_server_st(3).
memcached_server_count() provides you a count of the current number of
-servers being used by a memcached_st structure.
+servers being used by a C<memcached_st> structure.
memcached_server_list() is used to provide an array of all connected hosts.
You are responsible for freeing this list (aka it is not a pointer to the
currently used structure).
-memcached_server_add() pushes a single server into the memcached_st
+memcached_server_add() pushes a single server into the C<memcached_st>
structure. This server will be placed at the end. Duplicate servers are
allowed, so duplication is not checked.
-memcached_server_push() pushes an array of memcached_server_st into the 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.
+memcached_server_push() pushes an array of C<memcached_server_st> into
+the C<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.
=head1 RETURN
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
-memcached_return memcached_set(memcached_st *ptr, char *key, size_t key_length,
- char *value, size_t value_length,
- time_t expiration,
- uint16_t flags);
-memcached_return memcached_add(memcached_st *ptr, char *key, size_t key_length,
- char *value, size_t value_length,
- time_t expiration,
- uint16_t flags);
-memcached_return memcached_replace(memcached_st *ptr, char *key, size_t key_length,
- char *value, size_t value_length,
- time_t expiration,
- uint16_t flags);
+ #include <memcached.h>
+
+ memcached_return
+ memcached_set (memcached_st *ptr,
+ char *key, size_t key_length,
+ char *value, size_t value_length,
+ time_t expiration,
+ uint16_t flags);
+
+ memcached_return
+ memcached_add (memcached_st *ptr,
+ char *key, size_t key_length,
+ char *value, size_t value_length,
+ time_t expiration,
+ uint16_t flags);
+
+ memcached_return
+ memcached_replace (memcached_st *ptr,
+ char *key, size_t key_length,
+ char *value, size_t value_length,
+ time_t expiration,
+ uint16_t flags);
=head1 DESCRIPTION
-memcached_set() , memcached_add(), and memcached_replace() are all used to
+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 charcterss by the
-memcached server. You must also supply a value and a length. Optionally you
+store the object. Keys are currently limited to 250 characters by the
+memcached(1) server. You must also supply a value and a length. Optionally you
may support an expiration time for the object and a 16 byte value (it is
meant to be used as a bitmap).
=head1 RETURN
-All methods return a memcached_return value. On success the value will be
-MEMCACHED_SUCCESS (see memcached_strerror() for more information on this).
-For memcached_replace() and memcached_add() MEMCACHED_NOTSTORED is a
+All methods return a value of type C<memcached_return>.
+On success the value will be C<MEMCACHED_SUCCESS>.
+Use memcached_strerror() to translate this value to a printable string.
+
+For memcached_replace() and memcached_add(), C<MEMCACHED_NOTSTORED> is a
legitmate error in the case of a collision.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
-memcached_stat_st *memcached_stat(memcached_st *ptr, char *args, memcached_return *error);
-memcached_return memcached_stat_servername(memcached_stat_st *stat, char *args,
- char *hostname, unsigned int port);
-char *memcached_stat_get_value(memcached_st *ptr, memcached_stat_st *stat,
- char *key, memcached_return *error);
-char ** memcached_stat_get_keys(memcached_st *ptr, memcached_stat_st *stat,
- memcached_return *error);
+ #include <memcached.h>
+
+ memcached_stat_st *memcached_stat (memcached_st *ptr,
+ char *args,
+ memcached_return *error);
+
+ memcached_return memcached_stat_servername (memcached_stat_st *stat,
+ char *args,
+ char *hostname,
+ unsigned int port);
+
+ char *memcached_stat_get_value (memcached_st *ptr,
+ memcached_stat_st *stat,
+ char *key,
+ memcached_return *error);
+
+ char ** memcached_stat_get_keys (memcached_st *ptr,
+ memcached_stat_st *stat,
+ memcached_return *error);
=head1 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.
+C<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(3) has been provided to query the structure.
+<memcached_stat_get_value() has been provided to query the structure.
-memcached_stat() fetches an array of memcached_stat_st structures containing
+memcached_stat() fetches an array of C<memcached_stat_st> structures containing
the state of all available memcached servers. The return value must be freed
by the calling application.
-memcached_stat_servername() can be used standalone without a memcached_st to
+memcached_stat_servername() can be used standalone without a C<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 memcached_stat_get_keys call nor are they defined in the memcached
-protocol). You must specify the hostname and port fo the server you want to
-obtain information on
+the 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 (this key must be null terminated).
+specify the key you wish to obtain. The key must be null terminated.
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
+A command line tool, memstat(1), is provided so that you do not have to write
an application to do this.
=head1 RETURN
-memcached_stat() returns memcached_return. The value on success will be MEMCACHED_SUCCESS. For all errors check with memcached_strerror().
-Any method returning a memcached_stat_st expects you to free the memory
-allocated for it.
+Varies, see particular functions.
+
+Any method returning a C<memcached_stat_st> expects you to free the
+memory allocated for it.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
-char *memcached_strerror(memcached_st *ptr, memcached_return rc);
+ #include <memcached.h>
+
+ char *memcached_strerror (memcached_st *ptr,
+ memcached_return rc);
=head1 DESCRIPTION
+memcached_strerror() takes a C<memcached_return> value and returns a string
+describing the error.
+
+This string must not be modified by the application.
-memcached_strerror() takes a memcached_return value and returns a string
-describing the error. memcahed_return values are returned from nearly all
-libmemcached functions. They are a set of ENUM values describing all
-possibly success and failure operations possible in the library.
+C<memcached_return> values are returned from nearly all libmemcached(3) functions.
-memcached_return values are of an ENUM type so that you can set up responses
+C<memcached_return> 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.
=head1 RETURN
-memcached_strerror() returns a string describing a memcached_return value.
+memcached_strerror() returns a string describing a C<memcached_return> value.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-#include <memcached.h>
-memcached_return memcached_verbosity(memcached_st *ptr, unsigned int verbosity);
+ #include <memcached.h>
-=head1 DESCRIPTION
+ memcached_return memcached_verbosity (memcached_st *ptr,
+ unsigned int verbosity);
+=head1 DESCRIPTION
-memcached_verbosity() is used to modify the "verbosity" of all memcached servers.
+memcached_verbosity() modifies the "verbosity" of the
+memcached(1) servers referenced in the C<memcached_st> parameter.
=head1 RETURN
-memcached_verbosity() returns memcached_return. The value on success will be MEMCACHED_SUCCESS. For all errors check with memcached_strerror().
+A value of type C<memcached_return> is returned
+On success that value will be C<MEMCACHED_SUCCESS>.
+Use memcached_strerror() to translate this value to a printable string.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-memcat [options] key key ...
+ memcat [options] key key ...
=head1 DESCRIPTION
-memcat is a tool designed to copy to stdout a single or mutiple set of keys.
-It is designed to work similar to the standard UNIX cat utility.
+B<memcat> outputs to stdout the value a single or mutiple set of keys
+stored in a memcached(1) server.
-You can specify servers via the --servers option or memcat will use the
-environmental variable MEMCACHED_SERVERS.
+It is similar to the standard UNIX cat(1) utility.
-For a full list of its operations run the tool with the --help option.
+You can specify servers via the B<--servers> option or via the
+environment variable C<MEMCACHED_SERVERS>.
+
+For a full list of operations run the tool with the B<--help> option.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
+
+Mark Atwood E<lt>mark@fallenpegasus.comE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-memcp [options] file file <servers>
+ memcp [options] file file <servers>
=head1 DESCRIPTION
-memcp operates similar to the standard unix cp command. Files will be stored
-in the collection of memcached servers specified. Key names will be based on
-the name of the file (which does not include its directory path).
+B<memcp> copies one or more files into memcached(1) servers.
+It is similar to the standard UNIX cp(1) command.
-You can specify servers via the --servers option or memcat will use the
-environmental variable MEMCACHED_SERVERS. If you specify neither of these
-memcp will expect that the final value in the list passed to it is the name
-of a server(s).
+The key names will be the names of the files,
+without any directory path part.
-For a full list of its operations run the tool with the --help option.
+You can specify servers via the B<--servers> option or via the
+environment variable C<MEMCACHED_SERVERS>. If you specify neither of
+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 B<--help> option.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
+
+Mark Atwood, E<lt>mark@fallenpegasus.comE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-memflush [options]
+ memflush [options]
=head1 DESCRIPTION
-memflush will reset the contents of a server or group of servers. This means
-all data in these servers will be deleted.
+B<memflush> resets the contents of memcached(1) servers.
+This means all data in these servers will be deleted.
-You can specify servers via the --servers option or memcat will use the
-environmental variable MEMCACHED_SERVERS.
+You can specify servers via the B<--servers> option or via the
+environment variable C<MEMCACHED_SERVERS>.
-For a full list of its operations run the tool with the --help option.
+For a full list of operations run the tool with the B<--help> option.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
+
+Mark Atwood E<lt>mark@fallenpegasus.comE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-memrm [options] key key ...
+ memrm [options] key key ...
=head1 DESCRIPTION
-memrm is a tool designed to allow you to remove keys from a collection of
-memcached servers.
+B<memrm> removes items, specified by key, from memcached(1) servers.
-You can specify servers via the --servers option or memcat will use the
-environmental variable MEMCACHED_SERVERS.
+You can specify servers via the B<--servers> option or via the
+environment variable C<MEMCACHED_SERVERS>.
-For a full list of its operations run the tool with the --help option.
+For a full list of operations run the tool with the B<--help> option.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
+
+Mark Atwood, E<lt>mark@fallenpegasus.comE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-memslap [options]
+ memslap [options]
=head1 DESCRIPTION
-memslap is a load generation and benchmark tool for the memcached server. It
-can be used to simualte loads on memcached server clusters.
+B<memslap> is a load generation and benchmark tool for memcached(1)
+servers. It simulates loads on memcached server clusters.
-You can specify servers via the --servers option or memcat will use the
-environmental variable MEMCACHED_SERVERS.
+You can specify servers via the B<--servers> option or via the
+environment variable C<MEMCACHED_SERVERS>.
-For a full list of its operations run the tool with the --help option.
+For a full list of operations run the tool with the B<--help> option.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
=head1 SEE ALSO
=head1 SYNOPSIS
-memstat [options]
+ memstat [options]
=head1 DESCRIPTION
-memstat dumps the state of memcached servers. It displays all data to
-stdout.
+B<memstat> dumps the state of memcached(1) servers.
+It displays all data to stdout.
-You can specify servers via the --servers option or memcat will use the
-environmental variable MEMCACHED_SERVERS.
+You can specify servers via the B<--servers> option or via the
+environment variable C<MEMCACHED_SERVERS>.
-For a full list of its operations run the tool with the --help option.
+For a full list of operations run the tool with the B<--help> option.
=head1 HOME
-To find out more information please check: http://tangent.org/552/libmemcached.html
+To find out more information please check:
+L<http://tangent.org/552/libmemcached.html>
=head1 AUTHOR
-Brian Aker, brian@tangent.org
+Brian Aker, E<lt>brian@tangent.orgE<gt>
+
+Mark Atwood, E<lt>mark@fallenpegasus.comE<gt>
=head1 SEE ALSO