Files
floci/src/main/java/io/github/hectorvent
Allen Sanborn 27d2de0479 docs(lambda): say blank LogGroup is deliberately read as not supplied (#3271)
* docs(lambda): say blank LogGroup is deliberately read as not supplied

LogGroup carries a 1-512 length constraint, so an empty string is a
length violation on paper, yet validateLogGroup exempts blank and
applyLoggingConfig then falls back to the /aws/lambda/ default. That
looked like the guard missing the minimum.

It is a choice, not an oversight. botocore enforces the 1-character
minimum client side, so an empty LogGroup never reaches the wire from
an SDK caller and nobody has observed what the service answers to one.
A 400 here would be inferred rather than measured, and rejecting a
request we have never seen AWS reject is the expensive side of the
trade; accepting it costs a caller nothing.

Say that in the javadoc, and pin the leniency with a test so a later
reader who wants the minimum enforced has to change the decision
rather than just the guard.

* test(lambda): pin the whitespace-only LogGroup case, not just the empty one

The javadoc says blank means "empty or whitespace-only" and the guard is isBlank(),
but the only test passed "". Narrowing isBlank() to isEmpty() left the suite green,
so half the documented contract was unpinned.

Adds the whitespace-only case. Verified load-bearing: with isEmpty() in place of
isBlank() this test alone fails, and nothing else does.
2026-09-08 15:35:35 -04:00
..