Coder Social home page Coder Social logo

jorgelbg / dissect-tester Goto Github PK

View Code? Open in Web Editor NEW
109.0 4.0 6.0 10.57 MB

Simple API/UI for testing filebeat dissect patterns against a collection of sample log lines.

Home Page: https://dissect-tester.jorgelbg.me/

License: Apache License 2.0

Go 26.14% JavaScript 18.53% CSS 0.16% HTML 42.43% Dockerfile 1.18% Makefile 11.56%
filebeat dissect filter elasticsearch logstash hacktoberfest

dissect-tester's Introduction

Hi there ๐Ÿ‘‹, I'm Jorge - aka jorgelbg

  • ๐Ÿ”ญ Iโ€™m currently working on dashflare
  • โœ๐Ÿป I ocassionally write about everything on my blog
  • ๐Ÿ“Š Passionate about observability/monitoring topics
  • ๐Ÿš€ Odd mix between SRE/DevOps ๐Ÿคฃ

Connect with me:

Personal blog Twitter LinkedIn



๐Ÿ“• Latest Blog Posts

dissect-tester's People

Contributors

dependabot[bot] avatar disaderp avatar jorgelbg avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

dissect-tester's Issues

Change the format of the logger

We, currently, log directly in JSON (nice for further processing) but a bit verbose for normal usage. We could consider using a more user-friendly format by default.

High CPU usage

I've noticed that in my (very small) VM instance the CPU usage sometimes stays at 100% for a long time. Using pprof added in 7acd50c the CPU profile looks like:

image

could not find delimiter

Amazing tool @jorgelbg (Thanks) -

But how do we test the dissect patterns when we have values in quotes in the log event ?

I tried with the same Envoy example in the blog -

Dissect Pattern -
[%{timestamp}] "%{request}" %{status} - %{bytes_sent} "%{forwarded_ips}"
"%{user_agent}" "%{unknown_id}" "%{destination_host}" "%{destination_address}"

[2020-02-21T14:29:08.671Z] "GET /stats?format=prometheus&usedonly=1 HTTP/1.1"
200 - 0 105150 6 - "10.22.10.103" "Prometheus/2.7.0" "-" "10.22.10.121:12345" "-"

but get the following error -

sample: 0, error: could not find delimiter: ] " in remaining: GET /stats?format=prometheus&usedonly=1 HTTP/1.1", (offset: 28)

image

Share the pattern and samples

It could be interesting to allow sharing of the current set of samples and pattern in the UI. I had this same issue today where I wanted to share a working configuration with a colleague and couldn't.

Ideally I would like to implement this in a way that doesn't mean running additional infrastructure to store the shareables. From the top of my head maybe we can encode it in the URL.

Support Github releases

Currently, we only publish a docker hub.docker.com/jorgelb/dissect-tester. It would be nice to also publish releases supported by Github.

log sample won't accept input with '<'

The log sample seems to treat less than ('<') as a wildcard, so pasting any log content with such character (e.g. a weblogic server log: https://tekslate.com/weblogic-logging-filtering) will fail.
dissect pattern '####<%{Timestamp}> <%{Severity}> <%{Subsystem}> <%{MachineName}> <%{ServerName}> <%{ThreadID}> <%{UserID}> <%{TransactionID}> <%{ContextID}> <%{RawTimeValue}> <%{MessageID}> <%{MessageText}>'

You can manually retype the log text - this will work once, but if you click elsewhere then back to log sample it will be reformatted to replace 'special' chars with e.g. &gt; &lt; etc. which will then not parse
probably the same is the case with other 'special' chars.
I note this is problem with "log sample" but not with the dissect pattern

Add httprof/debug endpoints

This is, in general, a good practice and a nice to have feature since the API could be running as a service.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.