Uncategorized

  • Log rotation on json-file, which has no default limit

    The default logging driver writes to a file that grows without bound, so a chatty container fills the host disk over a fortnight and nothing warns first. Setting…

  • An init process, or PID 1 ignores your signals

    PID 1 in Linux gets no default signal handlers, so a shell script as the entrypoint ignores SIGTERM entirely and docker stop waits ten seconds before killing it.…

  • A grid with minmax and no media queries

    A responsive card grid was a set of breakpoints each restating the column count, which is four rules describing one intention. The min(16rem, 100%) is the part usually…

  • A sampling profiler is the one for production

    An instrumenting profiler records every call, which changes the timings it is measuring — small fast functions look disproportionately expensive because the overhead is per call. Sampling belongs…

  • An SLI is good events over valid events, and both are choices

    The numerator and the denominator are both decisions, and getting the denominator wrong is what makes an objective meaningless. Excluding health checks and monitoring traffic is uncontroversial and…

  • A stale closure in an effect, and the two ways out

    An effect with an empty dependency array captures the first render’s variables permanently, so a timer set up once reads values that stopped being current seconds later. A…

  • PHPUnit 9 removed what 8 deprecated, on schedule

    February brought the removals that 8 had warned about for a year, and a suite that ignored the warnings does not run at all. Rector handles the mechanical…

  • A consumer that is idempotent by construction, not by check

    A deduplication table is a check bolted on afterwards, and some operations are naturally repeatable — which is better, because there is nothing to get wrong. Designing the…

  • An architecture test that asserts on namespaces

    A layering rule that exists only in a diagram is a rule that has already been broken, and asserting on it is a test like any other. Fifteen…

  • array_key_first, and the pointer it does not move

    Getting the first key meant reset() then key(), which moves the internal pointer — so a read had a side effect on an array the caller may still…