All Projects → fukata → Golang Stats Api Handler

fukata / Golang Stats Api Handler

Licence: apache-2.0
Golang cpu, memory, gc, etc information api handler.

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to Golang Stats Api Handler

Zorka
Sophisticated monitoring agent for Java
Stars: ✭ 178 (-27.94%)
Mutual labels:  zabbix
Stat
Statistics package for Go [DEPRECATED]
Stars: ✭ 198 (-19.84%)
Mutual labels:  stats
Tracker
Laravel Stats Tracker
Stars: ✭ 2,638 (+968.02%)
Mutual labels:  stats
Wgcloud
linux运维监控工具,支持系统信息,内存,cpu,温度,磁盘空间及IO,硬盘smart,系统负载,网络流量等监控,API接口,大屏展示,拓扑图,进程监控,端口监控,docker监控,文件防篡改,日志监控,数据可视化,web ssh,堡垒机,指令下发批量执行,linux面板,探针,故障告警
Stars: ✭ 2,669 (+980.57%)
Mutual labels:  zabbix
Clickhouse exporter
This is a simple server that periodically scrapes ClickHouse stats and exports them via HTTP for Prometheus(https://prometheus.io/) consumption.
Stars: ✭ 193 (-21.86%)
Mutual labels:  stats
Ecommwar
A leaderboard of the top open-source e-commerce platforms. Promoting the bests for building reliable stores.
Stars: ✭ 203 (-17.81%)
Mutual labels:  stats
Zabbix Haproxy
HAProxy Zabbix Discovery and Template
Stars: ✭ 169 (-31.58%)
Mutual labels:  zabbix
Kubernetes Zabbix
📦 Kubernetes Zabbix/Grafana cluster (bare metal, Google Computer Engine - GCE, Google Container Engine - GKE)
Stars: ✭ 244 (-1.21%)
Mutual labels:  zabbix
Zabbix
Zabbix Plugin
Stars: ✭ 195 (-21.05%)
Mutual labels:  zabbix
Stdlib
✨ Standard library for JavaScript and Node.js. ✨
Stars: ✭ 2,749 (+1012.96%)
Mutual labels:  stats
Scikit Posthocs
Multiple Pairwise Comparisons (Post Hoc) Tests in Python
Stars: ✭ 186 (-24.7%)
Mutual labels:  stats
Mpv Stats
Display file statistics in mpv.
Stars: ✭ 192 (-22.27%)
Mutual labels:  stats
Zbx Smartctl
Templates and scripts for monitoring disks health with Zabbix and smartmontools
Stars: ✭ 206 (-16.6%)
Mutual labels:  zabbix
Thola
Tool for monitoring and provisioning network devices (mainly using SNMP) - monitoring check plugin
Stars: ✭ 179 (-27.53%)
Mutual labels:  zabbix
Sportsipy
A free sports API written for python
Stars: ✭ 229 (-7.29%)
Mutual labels:  stats
React Scanner
Extract React components and props usage from code.
Stars: ✭ 176 (-28.74%)
Mutual labels:  stats
Django Oms
加强版运维系统,集成工单、发布、监控、管理dns、saltstack
Stars: ✭ 201 (-18.62%)
Mutual labels:  zabbix
Pm2 Server Monit
Monitor server CPU / Memory / Process / Zombie Process / Disk size / Security Packages / Network Input / Network Output
Stars: ✭ 247 (+0%)
Mutual labels:  stats
Rabbitmq Zabbix
Zabbix RabbitMQ Configuration
Stars: ✭ 241 (-2.43%)
Mutual labels:  zabbix
Ewp oms
自动化运维系统(saltstack+django+bootstrap),QQ群342844540,博客http://ywzhou.blog.51cto.com
Stars: ✭ 211 (-14.57%)
Mutual labels:  zabbix

golang-stats-api-handler

Golang cpu, memory, gc, etc information api handler.

Build Status

Install

go get github.com/fukata/golang-stats-api-handler

Example

import (
    "net/http"
    "log"
    "github.com/fukata/golang-stats-api-handler"
)
func main() {
    http.HandleFunc("/api/stats", stats_api.Handler)
    log.Fatal( http.ListenAndServe(":8080", nil) )
}

Response

$ curl -i http://localhost:8080/api/stats/
HTTP/1.1 200 OK
Content-Length: 712
Content-Type: application/json
Date: Sun, 23 Aug 2015 16:52:13 GMT

{
    "time": 1440348733548339479,
    "go_version": "go1.5",
    "go_os": "darwin",
    "go_arch": "amd64",
    "cpu_num": 8,
    "goroutine_num": 24,
    "gomaxprocs": 8,
    "cgo_call_num": 9,
    "memory_alloc": 3974536,
    "memory_total_alloc": 12857888,
    "memory_sys": 12871928,
    "memory_lookups": 52,
    "memory_mallocs": 144922,
    "memory_frees": 118936,
    "memory_stack": 688128,
    "heap_alloc": 3974536,
    "heap_sys": 8028160,
    "heap_idle": 2170880,
    "heap_inuse": 5857280,
    "heap_released": 0,
    "heap_objects": 25986,
    "gc_next": 4833706,
    "gc_last": 1440348732827834419,
    "gc_num": 4,
    "gc_per_second": 0,
    "gc_pause_per_second": 0,
    "gc_pause": [
        0.196828,
        2.027442,
        0.181887,
        0.312866
    ]
}
Key Value
time unix timestamp as nano-seconds
go_version runtime.Version()
go_os runtime.GOOS
go_arch runtime.GOARCH
cpu_num number of CPUs
goroutine_num number of goroutines
gomaxprocs runtime.GOMAXRPOCS(0)
cgo_call_num runtime.NumCgoCall()
memory_alloc bytes allocated and not yet freed
memory_total_alloc bytes allocated (even if freed)
memory_sys bytes obtained from system
memory_lookups number of pointer lookups
memory_mallocs number of mallocs
memory_frees number of frees
memory_stack bytes used by stack allocator
heap_alloc bytes allocated and not yet freed (same as memory_alloc above)
heap_sys bytes obtained from system (not same as memory_sys)
heap_idle bytes in idle spans
heap_inuse bytes in non-idle span
heap_released bytes released to the OS
heap_objects total number of allocated objects
gc_next next collection will happen when HeapAlloc ≥ this amount
gc_last end time of last collection
gc_num number of GC-run
gc_per_second number of GC-run per second
gc_pause_per_second pause duration by GC per seconds
gc_pause pause durations by GC

Plugins

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].