Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
S

spectator

> 编程语言
Open source

Client library for collecting metrics.

766 stars0 likes0 views
WebsiteGitHub

About

Client library for collecting metrics.

Spectator

Simple library for instrumenting code to record dimensional time series.

Requirements

  • Java 8 or higher at runtime, Java 17 or higher for building.
  • Java 8 or higher for spectator 1.8.x or earlier.
  • Java 7 or higher for spectator 0.27.x or earlier.

Documentation

  • Wiki
  • Javadoc

Dependencies

To instrument your code you need to depend on the api library. This provides the minimal interfaces for you to code against and build test cases. The only dependency is slf4j.

com.netflix.spectator:spectator-api:${version}

If running at Netflix with the standard platform, see the Netflix Integration page on the wiki.

Instrumenting Code

Suppose we have a server and we want to keep track of:

  • Number of requests received with dimensions for breaking down by status code, country, and the exception type if the request fails in an unexpected way.
  • Latency for handling requests.
  • Summary of the response sizes.
  • Current number of active connections on the server.

Here is some sample code that does that:

…

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

Java

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言