-
Notifications
You must be signed in to change notification settings - Fork 1k
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
fix: Makes response codes rate limited as well as prints a message when it is hit #6701
Changes from all commits
7f1edb1
8673fec
48282a4
6836df9
1c0ec7a
be94664
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -612,18 +612,27 @@ property has the value `KSQL_PROCESSING_LOG`. | |
Toggles whether or not the processing log should include rows in log | ||
messages. By default, this property has the value `false`. | ||
|
||
### ksql.logging.server.skipped.response.codes | ||
### ksql.logging.server.rate.limited.response.codes | ||
|
||
A comma-separated list of HTTP response codes to skip during server | ||
request logging. This is useful for ignoring certain 4XX errors that you | ||
might not want to show up in the logs. | ||
A list of `code:qps` pairs, to limit the rate of server request | ||
logging. An example would be "400:10" which would limit 400 error | ||
logs to 10 per second. This is useful for limiting certain 4XX errors that you | ||
might not want to blow up in the logs. | ||
This setting enables seeing the logs when the request rate is low | ||
and dropping them when they go over the threshold. | ||
A message will be logged every 5 seconds indicating if the rate limit | ||
is being hit, so an absence of this message means a complete set of logs. | ||
|
||
### ksql.logging.server.rate.limited.request.paths | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We're currently logging for internal endpoints (used in server-to-server communication for multi-node clusters), right? Would it make sense to disable logging for those by default? (I don't feel strongly one way or the other -- you have more context than I do about when/how often those endpoints are hit.) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, currently we log all requests, regardless of internal/external status. I think this could be useful if we're trying to trace pull queries falling back on standbys after failures. We can see if this ends up being useful and potentially remove internal if not. |
||
|
||
A list of `path:rate_limit` pairs, to limit the rate of server request | ||
logging. This is useful for requests that are coming in at a high rate, | ||
such as for pull queries. This setting enables seeing the logs when the request rate is low | ||
A list of `path:qps` pairs, to limit the rate of server request | ||
logging. An example would be "/query:10" which would limit pull query | ||
logs to 10 per second. This is useful for requests that are coming in | ||
at a high rate, such as for pull queries. | ||
This setting enables seeing the logs when the request rate is low | ||
and dropping them when they go over the threshold. | ||
A message will be logged every 5 seconds indicating if the rate limit | ||
is being hit, so an absence of this message means a complete set of logs. | ||
|
||
ksqlDB-Connect Settings | ||
----------------------- | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mention that a message will be logged (at most once every five seconds) if the threshold is hit? (And same for the other config below.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done