2 * Copyright (C) 2006-2009 Brian Aker
5 * Use and distribution licensed under the BSD license. See
6 * the COPYING file in the parent directory for full text.
8 * Summary: Collect up the stats for a memcached server.
12 #ifndef __LIBMEMCACHED_STATS_H__
13 #define __LIBMEMCACHED_STATS_H__
15 struct memcached_stat_st
{
16 uint32_t connection_structures
;
17 uint32_t curr_connections
;
20 uint32_t pointer_size
;
21 uint32_t rusage_system_microseconds
;
22 uint32_t rusage_system_seconds
;
23 uint32_t rusage_user_microseconds
;
24 uint32_t rusage_user_seconds
;
27 uint32_t total_connections
;
32 uint64_t bytes_written
;
38 uint64_t limit_maxbytes
;
39 char version
[MEMCACHED_VERSION_STRING_LENGTH
];
48 void memcached_stat_free(memcached_st
*, memcached_stat_st
*);
51 memcached_stat_st
*memcached_stat(memcached_st
*ptr
, char *args
, memcached_return_t
*error
);
54 memcached_return_t
memcached_stat_servername(memcached_stat_st
*memc_stat
, char *args
,
55 const char *hostname
, in_port_t port
);
58 char *memcached_stat_get_value(memcached_st
*ptr
, memcached_stat_st
*memc_stat
,
59 const char *key
, memcached_return_t
*error
);
62 char ** memcached_stat_get_keys(memcached_st
*ptr
, memcached_stat_st
*memc_stat
,
63 memcached_return_t
*error
);
69 #endif /* __LIBMEMCACHED_STATS_H__ */