Dark Mode

Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Add format for RabbitMQ logs#870

Draft
nicolasbock wants to merge 1 commit intotstack:masterfrom
nicolasbock:rabbitmq_log
Draft

Add format for RabbitMQ logs#870
nicolasbock wants to merge 1 commit intotstack:masterfrom
nicolasbock:rabbitmq_log

Conversation

Copy link
Contributor

nicolasbock commented Jun 9, 2021

Taken from #410 (comment)

Co-Authored-By: Adam Spiers adam@spiers.net
Co-Authored-By: Nicolas Bock nicolasbock@gmail.com
Signed-off-by: Nicolas Bock nicolasbock@gmail.com

Taken from tstack#410 (comment)

Co-Authored-By: Adam Spiers
Co-Authored-By: Nicolas Bock
Signed-off-by: Nicolas Bock
Copy link
Owner

tstack commented Jun 11, 2021

This is marked as a Draft, is there anything else you want to do?

Copy link
Contributor Author

nicolasbock commented Jun 11, 2021

It's working but I wanted to give myself a bit more time with it to see if everything is in there.

Unfortunately the performance is not great. Loading a 4GiB log file takes upwards of 10 minutes. Fortunately lnav is usable before it fully loads the log.

I will test it out today a bit more and then give it or

aspiers reviewed Jul 31, 2021
"rabbitmq_log": {
"regex": {
"connection": {
"pattern" : "^=(?[A-Z]+) REPORT==== (?\\d\\d?-\\w{3}-\\d{4}::\\d{2}:\\d{2}:\\d{2}) ===(\\n(?(closing AMQP connection <(?.+)> \\((?\\d[\\d.]+\\d?):(?\\d+) -> (?\\d[\\d.]+\\d?):(?\\d+)\\))?(.*\\n)*))?$"
Copy link
Contributor

aspiers Jul 31, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if the performance issue could be mitigated by tweaking this a bit. For example changing the .+ inside <(?.+)> to [^>]+ so that the regexp matching engine doesn't have to do any backtracking. Just a guess, not sure if it will help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

1 more reviewer

aspiers aspiers left review comments

Reviewers whose approvals may not affect merge requirements

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

3 participants