LiveDashboard Plugin for Timeless Logs
"I found it ironic that the first thing you do to time series data is squash the timestamp. That's how the name Timeless was born." --Mark Cotner
Phoenix LiveDashboard page for browsing TimelessLogs logs.
Provides three tabs:
- Search -- query logs with level, message, and metadata filters + pagination
- Stats -- aggregate metrics (blocks, entries, compressed size, index size, timestamps)
- Live Tail -- real-time streaming of new log entries
Installation
Quick Start (Igniter)
mix igniter.install timeless_logs_dashboardThis automatically:
-
Adds
config :timeless_logs, data_dir: "priv/timeless_logs"to your config -
Adds
import TimelessLogsDashboard.Routerto your router -
Adds
timeless_logs_dashboard "/dashboard"to your browser scope -
Updates your
.formatter.exs
For in-memory storage (logs lost on restart):
mix igniter.install timeless_logs_dashboard --storage memoryManual Setup
Add timeless_logs_dashboard to your dependencies:
def deps do
[
{:timeless_logs_dashboard, "~> 0.6.0"}
]
end
Configure TimelessLogs in config/config.exs:
config :timeless_logs, data_dir: "priv/timeless_logs"Add the router macro:
# lib/my_app_web/router.ex
import TimelessLogsDashboard.Router
scope "/" do
pipe_through :browser
timeless_logs_dashboard "/dashboard"
endOr add the page directly to an existing LiveDashboard:
live_dashboard "/dashboard",
additional_pages: [
logs: TimelessLogsDashboard.Page
]
Navigate to /dashboard/logs in your browser.
Requirements
- TimelessLogs must be running in your application
- Phoenix LiveDashboard ~> 0.8
- Phoenix LiveView ~> 1.0
License
MIT