Skip to content

Only record the matching pattern from a traffic shaping rule to log on internal transient failure #350

@lianatech-jutaky

Description

@lianatech-jutaky

What Operating System are you seeing this problem on?

Debian 12

What Hardware is this system running?

Cloud instance

KumoMTA version

2025.02.28.084144.3966ca59

Did you try the latest release to see if the issue is better (or worse!) than your current version?

Yes, and I updated the version box above to show the version that I tried

Describe the bug

Scenario: traffic automation helper toml has one gigantic rule with dozens of regex patterns to match various responses. Logically similar patterns, so they all trigger one identical config change.

Behavior: when internal transient failure occurs due to a queue suspension, KumoMTA implodes the regex pattern list into one single mile long string into the log:

451: KumoMTA internal: scheduled queue is suspended: automation rule: $very_long_text_with_all_the_regex_patterns_imploded

When lots of internal transient failures happen, this will suck up disk space and IO quite a bit into logging efforts.

My suggestion is to only log the relevant regex pattern that actually matched and triggered the suspension. No reason to include all the dozens of other unrelated patterns in there.

This would reduce resource usage as well as improve UX by actually showing in the log what triggered the suspension.

To Reproduce

No response

Configuration

Transient failure logging enabled and a traffic shaping rule with maany regexes.

Expected Behavior

No response

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions