Skip to content
Proyectos

Acerca de

Biblioteca sencilla de monitorización del rendimiento para Clojure/Script

Herramientas de desarrollo

Cómo se miden estas cifras

Crecimiento de estrellas medido

in 24h
0
in 7 days
0
in 15 days
0
in 1 month
Recopilando historial

Cambios netos en períodos que se solapan, no totales diarios. Los datos no disponibles se dejan en blanco. Las estrellas indican interés, no calidad.

README.md

Original

Taoensso open source
API | Wiki | Slack | Latest release: v3.1.0 (2026-07-30)

Clj tests Cljs tests Graal tests

Tufte

Simple performance monitoring library for Clojure/Script

Tufte allows you to easily monitor the ongoing performance of your Clojure and ClojureScript applications in production and other environments.

It provides sensible application-level metrics, and gives them to you as Clojure data that can be easily analyzed programatically.

Use it alone, or as part of a suite of complementary observability tools for modern Clojure/Script applications:

  • Telemere for logging, tracing, and general telemetry
  • Tufte for performance monitoring
  • Truss for assertions and error handling
  • Trove for library authors that want to do structured logging
Carte Figurative

Carte Figurative, one of Edward Tufte's favourite data visualizations.

Why Tufte?

  • Small, fast, cross-platform Clojure/Script codebase.
  • Sensible form-level profiling without the low-level JVM noise.
  • Metrics as Clojure maps: easily aggregate, analyse, log, serialize to db, etc.
  • Tiny, flexible API: p, profiled, profile.
  • Full support for thread-local and dynamic (multi-threaded) profiling.
  • Rich filtering: conditional profiling by namespace, id pattern, level, level by namespace pattern, etc.
  • Rich a/sync handling: with sampling, rate limiting, back-pressure monitoring, etc.
  • Includes handlers for Telemere, Timbre, and consoles (*out*, etc.).

Quick example

Using Tufte v3:

(require '[taoensso.tufte :as tufte])

;; Send `profile` signals to console
(tufte/add-handler! :my-console-handler (tufte/handler:console))

;;; Define a couple dummy fns to simulate doing some expensive work
(defn get-x [] (Thread/sleep 500)             "x val")
(defn get-y [] (Thread/sleep (rand-int 1000)) "y val")

;; Let's check how these fns perform:
(tufte/profile   ; Profile any `p` forms called during body execution
  {:level :info} ; Rich set of filtering options available
  (dotimes [_ 5]
    (tufte/p :get-x (get-x))
    (tufte/p :get-y (get-y))))

;; The following will be printed to *out*:
;; 2025-04-18T11:23:08.820786Z INFO MyHost readme-examples[15,1] Tufte pstats
;; pId           nCalls        Min      50% ≤      90% ≤      95% ≤      99% ≤        Max       Mean   MAD      Clock  Total
;;
;; :get-y             5      238ms      501ms      981ms      981ms      981ms      981ms      618ms  ±42%      3.09s    55%
;; :get-x             5      501ms      502ms      505ms      505ms      505ms      505ms      503ms   ±0%      2.51s    45%
;;
;; Accounted                                                                                                    5.60s   100%
;; Clock                                                                                                        5.60s   100%

Documentation

Funding

You can help support continued work on this project and others, thank you!! 🙏

License

Copyright © 2016-2025 Peter Taoussanis.
Licensed under EPL 1.0 (same as Clojure).

Explorar proyectos relacionados

Cargando…