Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add bytes sent to query log message #167

Closed
troy2914 opened this issue Jan 17, 2019 · 5 comments
Closed

Add bytes sent to query log message #167

troy2914 opened this issue Jan 17, 2019 · 5 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@troy2914
Copy link
Member

In irrd-4.0.0rc1

irrd is wasting time (and space) logging thousands of "received query" INFO messages.

@mxsasha
Copy link
Collaborator

mxsasha commented Jan 17, 2019

We can lower this to DEBUG easily. However, my understanding was that currently NTT logs all queries in production? That would make it fit INFO level, as that's the recommended level for production.

@troy2914
Copy link
Member Author

Hmm, good point.
from the legacy irrd
Jan 17 00:24:40 [18446744073508222720] IRRD Command: !gas30259
Jan 17 00:24:40 [18446744073508222720] IRRD About to lock --lock_all_mutex_lock--
Jan 17 00:24:40 [18446744073508222720] IRRD Locked --lock_all_mutex_lock--
Jan 17 00:24:40 [18446744073508222720] IRRD Unlocked --lock_all_mutex_lock--
Jan 17 00:24:40 [18446744073508222720] IRRD Done with lock_all
Jan 17 00:24:40 [18446744073508222720] IRRD Sent 609 bytes

The bytes sent is kind of interesting too.

@mxsasha
Copy link
Collaborator

mxsasha commented Jan 18, 2019

We could also log the length of the response, at either INFO or DEBUG. Not sure what it would be useful for, but it's fairly easy to add.

@troy2914
Copy link
Member Author

Leaving the received query, and adding the response length at INFO would be the consistent with irrd2.

@mxsasha mxsasha self-assigned this Jan 28, 2019
@mxsasha mxsasha added the enhancement New feature or request label Jan 28, 2019
@mxsasha
Copy link
Collaborator

mxsasha commented Jan 28, 2019

We now have elapsed time, I can add the length of the response. Both the message that a query is being processed, and the time it took are now logged at INFO level.

I strongly advise against removing the "processing query" part before a command - if I understood that suggestion right - logs of IRRd 4 are not compatible with IRRd 2 in many other places.

@mxsasha mxsasha changed the title "received query" messages should be DEBUG not INFO Add bytes sent to query log message Jan 28, 2019
@mxsasha mxsasha added this to the IRRD 4.0.0 milestone Jan 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants