12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576 |
- <?php
- // $Id$
- /**
- * @file
- * APC instrumentation for Munin
- */
- /**
- * Implements hook_munin_api_info().
- *
- * @return
- * An array of Munin probes informations, index by probe name.
- */
- function munin_apc_munin_api_info() {
- $ret = array(
- 'munin_apc' => array(
- '#title' => t('PHP APC'),
- '#description' => t('Collect cache information for the Alternative PHP Cache'),
- 'uptime' => array(
- '#title' => t('Up-time of APC instance'),
- '#type' => MUNIN_API_GAUGE
- ),
- 'total_size' => array(
- '#title' => t('Number of bytes allocated to APC'),
- '#type' => MUNIN_API_COUNTER,
- ),
- 'used_size' => array(
- '#title' => t('Number of bytes currently used by APC, either cached or deleted'),
- '#type' => MUNIN_API_COUNTER,
- ),
- 'num_hits' => array(
- '#title' => t('The number of hits since the last restart'),
- '#type' => MUNIN_API_COUNTER,
- ),
- 'num_misses' => array(
- '#title' => t('The number of misses since the last restart'),
- '#type' => MUNIN_API_COUNTER,
- ),
- 'hit_rate' => array(
- '#title' => t('This hit/miss ratio since the last restart'),
- '#type' => MUNIN_API_GAUGE,
- ),
- 'num_insertions' => array(
- '#title' => t('The number of insertions since the last restart'),
- '#type' => MUNIN_API_COUNTER,
- ),
- 'cache_entries' => array(
- '#title' => t('The number of cache entries'),
- '#type' => MUNIN_API_GAUGE,
- ),
- 'deleted_entries' => array(
- '#title' => t('The number of deleted entries lingering'),
- '#type' => MUNIN_API_GAUGE,
- ),
- ),
- );
- return $ret;
- }
- /**
- * Implements hook_munin_api_fetch().
- */
- function munin_apc_munin_api_fetch() {
- return array(
- 'uptime' => 1,
- );
- }
- /**
- * Implements hook_munin_api_config().
- */
- function munin_apc_munin_api_config() {
- return array(
- );
- }
|