The comment on MaxAccessLogLineBytes said the GORM adapter logs each statement with the client's parameter written into it. Its ParamsFilter drops every bound value, so the statement is logged with its placeholders. The comment now says so and keeps the parts that still hold: the widest line spends two budgets and the adapter's test checks it against this constant. The assertBounded doc no longer claims each line was cut, and the postReceiver doc no longer explains itself by a log size test that is gone. Model: opus-5-5
This commit is contained in:
@@ -191,13 +191,12 @@ func receiverRouter(h *handlers.Handlers) *chi.Mux {
|
||||
return router
|
||||
}
|
||||
|
||||
// postReceiver sends one POST at /h/<segment>.
|
||||
// postReceiver sends one POST with an empty body at /h/<segment>
|
||||
// through router and returns the response status.
|
||||
//
|
||||
// RawPath is cleared after parsing so chi routes on the decoded path
|
||||
// and the handler sees the raw bytes rather than their percent-escaped
|
||||
// spelling. That is the harder case for the budget: the escaped
|
||||
// spelling is plain ASCII, which costs one byte per byte, while the
|
||||
// decoded bytes are what the log handler has to escape.
|
||||
// spelling.
|
||||
func postReceiver(
|
||||
t *testing.T, router *chi.Mux, segment string,
|
||||
) int {
|
||||
|
||||
Reference in New Issue
Block a user