Skip to content
项目

关于

在笔记本电脑上实现可观测性

系统与基础设施

这些数字如何统计

实测星标增长

24小时
0
7天
0
15天
0
1个月
正在收集历史

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.md

原文

humanlog

Read logs from stdin and prints them back to stdout, but prettier. It's also a localhost observability platform, supporting logs and distributed traces.

Using it

curl -sSL "https://humanlog.io/install.sh" | bash

Read more at 👉 how to install in our docs.

Getting started

You can use humanlog in the CLI to make your logs prettier. You can also use it as a localhost observability platform to be able to explore the logs and traces that you ingested. Logs parsed by humanlog are persisted in a local database. Similarly, traces are ingested and persisted in a local database when sent via OpenTelemetry/OTLP.

Read more at 👉 how to get started in our docs.

Example - pretty-printing logs

If you emit logs in JSON or in logfmt, you will enjoy pretty logs when those entries are encountered by humanlog. Unrecognized lines are left unchanged.

$ humanlog < /var/log/logfile.log

example CLI usage

When the logs are parsed, they are persisted in a local database. You can then query and explore them via the web UI.

Example - using it as a localhost observability platform

With the query engine turned on (this is the default on new installations), you can query the logs and traces that you ingested. Run a query with:

$ humanlog query "spans | where duration > 100ms"

querying

Learn more at 👉 how to query in our docs.

Example - ingesting traces

You can ingest traces via OpenTelemetry/OTLP. Using your language of choices' OpenTelemetry client will work out of the box using the default configuration. If not, point your exporter to http://localhost:4317 or http://localhost:4318 (these are the default values).

Other valid values for OTEL_EXPORTER_OTLP_ENDPOINT are:

Situation OTEL_EXPORTER_OTLP_ENDPOINT
Default (same host, OTLP/HTTP) http://localhost:4317
Default (same host, OTLP/gRPC) http://localhost:4318
Docker, Orbstack, kind (OTLP/HTTP) http://host.docker.internal:4317
Docker, Orbstack, kind (OTLP/gRPC) http://host.docker.internal:4318

Learn more at 👉 ingesting OpenTelemetry/OTLP in our docs.

Support and help

Open an issue on this repo or contribute a PR if you find a bug or want to add a feature in the CLI.

Need more help or want to give feedback? Join our community channels.

License

The core CLI is Apache 2 licensed (everything in this repo). Official releases are available at humanlog.io and include proprietary code that is inserted at build time (the query engine).

探索相关项目

加载中…