mirror of
https://github.com/taoensso/telemere.git
synced 2026-02-18 00:35:55 +00:00
Compare commits
2 commits
75a90c6b6d
...
dd22c7602b
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
dd22c7602b | ||
|
|
9d655bb9ce |
3 changed files with 29 additions and 22 deletions
|
|
@ -217,7 +217,7 @@ It enables you to write code that is **information-verbose by default**.
|
|||
## Comparisons
|
||||
|
||||
- Telemere [compared](../../wiki/5-Migrating#from-timbre) to [Timbre](https://www.taoensso.com/timbre) (Telemere's predecessor)
|
||||
- Telemere [compared](../../wiki/6-FAQ#how-does-telemere-compare-to-mulog) to [Mulog](https://github.com/BrunoBonacci/mulog) (structured micro-logging library)
|
||||
- Telemere [compared](../../wiki/6-FAQ#how-does-telemere-compare-to-mulog) to [μ/log](https://github.com/BrunoBonacci/mulog) (structured micro-logging library)
|
||||
|
||||
## Videos
|
||||
|
||||
|
|
|
|||
|
|
@ -391,7 +391,7 @@
|
|||
:signal! ; opts => allowed? / run result (value or throw)
|
||||
'( [& opts-kvs]
|
||||
[{:as opts-map :keys
|
||||
[elidable? coords inst uid xfn xfn+,
|
||||
[elidable? coords inst uid xfn xfn+ kvs+,
|
||||
sample kind ns id level when limit limit-by,
|
||||
ctx ctx+ parent root trace?, do let data msg error run & kvs]}])
|
||||
|
||||
|
|
@ -399,7 +399,7 @@
|
|||
'([opts-or-msg]
|
||||
[level msg]
|
||||
[{:as opts-map :keys
|
||||
[elidable? coords inst uid xfn xfn+,
|
||||
[elidable? coords inst uid xfn xfn+ kvs+,
|
||||
sample kind ns id level when limit limit-by,
|
||||
ctx ctx+ parent root trace?, do let data msg error #_run & kvs]}
|
||||
msg])
|
||||
|
|
@ -409,7 +409,7 @@
|
|||
[id level]
|
||||
[id
|
||||
{:as opts-map :keys
|
||||
[elidable? coords inst uid xfn xfn+,
|
||||
[elidable? coords inst uid xfn xfn+ kvs+,
|
||||
sample kind ns id level when limit limit-by,
|
||||
ctx ctx+ parent root trace?, do let data msg error #_run & kvs]}])
|
||||
|
||||
|
|
@ -417,7 +417,7 @@
|
|||
'([opts-or-run]
|
||||
[id run]
|
||||
[{:as opts-map :keys
|
||||
[elidable? coords inst uid xfn xfn+,
|
||||
[elidable? coords inst uid xfn xfn+ kvs+,
|
||||
sample kind ns id level when limit limit-by,
|
||||
ctx ctx+ parent root trace?, do let data msg error run & kvs]}
|
||||
run])
|
||||
|
|
@ -426,7 +426,7 @@
|
|||
'([opts-or-run]
|
||||
[level run]
|
||||
[{:as opts-map :keys
|
||||
[elidable? coords inst uid xfn xfn+,
|
||||
[elidable? coords inst uid xfn xfn+ kvs+,
|
||||
sample kind ns id level when limit limit-by,
|
||||
ctx ctx+ parent root trace?, do let data msg error run & kvs]}
|
||||
run])
|
||||
|
|
@ -435,7 +435,7 @@
|
|||
'([opts-or-error]
|
||||
[id error]
|
||||
[{:as opts-map :keys
|
||||
[elidable? coords inst uid xfn xfn+,
|
||||
[elidable? coords inst uid xfn xfn+ kvs+,
|
||||
sample kind ns id level when limit limit-by,
|
||||
ctx ctx+ parent root trace?, do let data msg error #_run & kvs]}
|
||||
error])
|
||||
|
|
@ -445,7 +445,7 @@
|
|||
[id run]
|
||||
[{:as opts-map :keys
|
||||
[catch-val,
|
||||
elidable? coords inst uid xfn xfn+,
|
||||
elidable? coords inst uid xfn xfn+ kvs+,
|
||||
sample kind ns id level when limit limit-by,
|
||||
ctx ctx+ parent root trace?, do let data msg error #_run & kvs]}
|
||||
run])
|
||||
|
|
@ -454,7 +454,7 @@
|
|||
'([]
|
||||
[opts-or-id]
|
||||
[{:as opts-map :keys
|
||||
[elidable? coords inst uid xfn xfn+,
|
||||
[elidable? coords inst uid xfn xfn+ kvs+,
|
||||
sample kind ns id level when limit limit-by,
|
||||
ctx ctx+ parent root trace?, do let data msg error #_run & kvs]}])
|
||||
|
||||
|
|
@ -602,13 +602,20 @@
|
|||
(get opts :xfn `taoensso.telemere/*xfn*))
|
||||
|
||||
kvs-form
|
||||
(not-empty
|
||||
(dissoc opts
|
||||
:elidable? :coords :inst :uid :xfn :xfn+,
|
||||
:sample :ns :kind :id :level :filter :when #_:limit #_:limit-by,
|
||||
:ctx :ctx+ :parent #_:trace?, :do :let :data :msg :error,
|
||||
:run :run-form :run-val, :elide? :allow? #_:callsite-id,
|
||||
:host :thread :otel/context))
|
||||
(let [base
|
||||
(not-empty
|
||||
(dissoc opts
|
||||
:elidable? :coords :inst :uid :xfn :xfn+ :kvs+,
|
||||
:sample :ns :kind :id :level :filter :when #_:limit #_:limit-by,
|
||||
:ctx :ctx+ :parent #_:trace?, :do :let :data :msg :error,
|
||||
:run :run-form :run-val, :elide? :allow? #_:callsite-id,
|
||||
:host :thread :otel/context))]
|
||||
|
||||
(if-let [kvs+ (get opts :kvs+)] ; Undocumented
|
||||
(if base
|
||||
`(not-empty (conj ~base ~kvs+))
|
||||
`(not-empty ~kvs+))
|
||||
base))
|
||||
|
||||
_ ; Compile-time validation
|
||||
(do
|
||||
|
|
|
|||
|
|
@ -115,11 +115,11 @@ See also [`msg-skip`](https://cljdoc.org/d/com.taoensso/telemere/CURRENT/api/tao
|
|||
|
||||
See section [9-Authors](./9-Authors.md).
|
||||
|
||||
# How does Telemere compare to Mulog?
|
||||
# How does Telemere compare to μ/log?
|
||||
|
||||
> [Mulog](https://github.com/BrunoBonacci/mulog) is an excellent "micro-logging library" for Clojure that shares many of the same capabilities and objectives as Telemere.
|
||||
> [μ/log](https://github.com/BrunoBonacci/mulog) is an excellent "micro-logging library" for Clojure that shares many of the same capabilities and objectives as Telemere.
|
||||
|
||||
Some **similarities** between Telemere and Mulog:
|
||||
Some **similarities** between Telemere and μ/log:
|
||||
|
||||
- Both emphasize **structured data** rather than string messages
|
||||
- Both offer **tracing** to understand (nested) program flow
|
||||
|
|
@ -127,7 +127,7 @@ Some **similarities** between Telemere and Mulog:
|
|||
- Both are **fast** and offer **async handling**
|
||||
- Both offer a variety of **handlers** and are designed for ease of use
|
||||
|
||||
Some particular **strengths of Mulog** that I'm aware of:
|
||||
Some particular **strengths of μ/log** that I'm aware of:
|
||||
|
||||
- More **established/mature**
|
||||
- Wider **range of handlers** (incl. Kafka, Kinesis, Prometheus, Zipkin, etc.)
|
||||
|
|
@ -137,7 +137,7 @@ Some particular **strengths of Mulog** that I'm aware of:
|
|||
|
||||
Some particular **strengths of Telemere**:
|
||||
|
||||
- Both **Clj and Cljs support** (Mulog is Clj only)
|
||||
- Both **Clj and Cljs support** (μ/log is Clj only)
|
||||
- Rich **filtering capabilities** (see [`help:filters`](https://cljdoc.org/d/com.taoensso/telemere/CURRENT/api/taoensso.telemere#help:filters)) incl. compile-time elision
|
||||
- Rich **dispatch control** (see [`help:handler-dispatch-options`](https://cljdoc.org/d/com.taoensso/telemere/CURRENT/api/taoensso.telemere#help:handler-dispatch-options))
|
||||
- Rich **environmental config** (see [`help:environmental-config`](https://cljdoc.org/d/com.taoensso/telemere/CURRENT/api/taoensso.telemere#help:environmental-config)) for all platforms
|
||||
|
|
@ -148,7 +148,7 @@ Some particular **strengths of Telemere**:
|
|||
|
||||
**My subjective thoughts**:
|
||||
|
||||
Mulog is an awesome, well-designed library with quality documentation and a solid API. It's **absolutely worth checking out** - you may well prefer it to Telemere!
|
||||
μ/log is an awesome, well-designed library with quality documentation and a solid API. It's **absolutely worth checking out** - you may well prefer it to Telemere!
|
||||
|
||||
The two libraries have many shared capabilities and objectives.
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue