5 Analyze server information
11 .. index:: object: memcached_analysis_st
13 #include <libmemcached/memcached.h>
14 Compile and link with -lmemcached
16 .. type:: memcached_analysis_st
18 typedef struct memcached_analysis_st memcached_analysis_st;
20 .. function:: memcached_analysis_st *memcached_analyze(memcached_st *ptr, memcached_stat_st *stat, memcached_return_t *error)
26 `libmemcached` has the ability to query a memcached server (or
27 collection of servers) for their current state. Queries to find state return a
28 :type:`memcached_analysis_st` structure. You are responsible for freeing this structure.
30 :func:`memcached_analyze` analyzes useful information based on the
31 provided servers and sets the result to the :type:`memcached_analysis_st`
32 structure. The return value must be freed by the calling application.
34 A command line tool, :program:`memstat` with the option :option:`memstat --analyze`,
35 is provided so that you do not have to write an application to use this method.
41 A pointer to the allocated :type:`memcached_analysis_st` structure on
42 success and a NULL pointer on failure. You may inspect the error detail by
43 checking the :type:`memcached_return_t` value.
45 Any method returning a :type:`memcached_analysis_st` expects you to free the
46 memory allocated for it.
54 :manpage:`memcached(1)`
55 :manpage:`libmemcached(3)`
56 :manpage:`memcached_strerror(3)`
60 * :manpage:`memcached(1)`
61 * :doc:`../libmemcached`
62 * :doc:`memcached_strerror`