aurc / loggo

A powerful terminal app for structured log streaming
MIT License
123 stars 11 forks source link

Filter by JSON key #8

Closed aurc closed 2 years ago

aurc commented 2 years ago

Background

A template is either provide or sensed by l'oGGo app. If basically consists of:

A common workflow when reviewing logs is the ability to tabularly filter out column field values so you can easily focus on a subset of candidate entries of your interest, removing, thus, unnecessary verbose noise.

Feature:

Given an arbitrary number of keys, enable the user to craft filters using any combinations in the set leveraging datatypes common aggregation/filtering standard functions and boolean logic. Example:

Given key set (as in template - some elements like colors removed for brevity):

keys:
  - name: priority
    type: number
  - name: severity
    type: string
  - name: resource/labels/container_name
    type: string
  - name: jsonPayload/message
    type: string

Wants to filter records in such a way that:

(
  ("priority" between "1" and "3") and 
  ("resource/labels/container_name" = "foo" or "resource/labels/container_name" = "bar") and 
  (severity = "debug")
)

Enable the following:

aurc commented 2 years ago

Delivered as part of v0.3.0