Skip to content

chatwoot-adapter: bound the seen: dedup markers (unbounded plugin storage growth) #620

Description

@rmyndharis

The chatwoot-adapter writes a durable seen:* dedup marker (one ctx.storage file) per inbound message id and per outbound send id, and never removes them. Over a long-running deployment the plugin data directory grows without bound.

Two effects:

  1. Unbounded disk/inode growth in <dataDir>/plugins/chatwoot-adapter/.
  2. The inbound retry drain (v0.5.0) scans that directory (ctx.storage.list('retry:')readdirSync) every 30s; its cost scales with the total file count, which these markers dominate.

Options: age/TTL-based pruning of seen: markers, or a bounded rolling dedup window — re-delivery of a very old message id is not a realistic concern.

Pre-existing (predates the retry feature); the retry drain just makes the directory-scan cost visible.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions