ediverse Explore the platform

Spotlight PEPPOL BIS Billing 3.0 The EU e-invoicing mandate is here — France Sept 2026, Belgium Jan 2026, Germany 2025.

Polling Consumer

The pull-at-interval consumer — legacy EDI SFTP/FTPS polling.

Problem

How to receive messages from a system without push notification? How to integrate a legacy EDI system that only drops files?

Forces

  • Push is elegant but requires an exposed endpoint — not always feasible behind a firewall.
  • Polling is simple to implement and debug — a cron + a script.
  • Polling consumes resources even with no messages.
  • Polling adds latency (poll interval) — not suited to real-time.

Solution

A looping consumer: (1) poll the channel/folder, (2) process new messages, (3) sleep N seconds, back to 1. Simple, predictable, easy to monitor (poll latency, items processed). Typical interval: 30s in batch EDI, 5s in near-realtime EDI.

EDI implementation

In EDI, Polling Consumer is the standard mode for SFTP: a CRON job or Camel route `file://?delay=30000` browses the SFTP folder every 30 seconds, processes each new file. Also used for OFTP polling and legacy VANs. Modernised: Polling Bridge transforms SFTP polling into Kafka push.

Anti-patterns

  • Polling interval < 1s with expensive processing — useless overhead.
  • Polling without timeout — a massive folder (1000+ files) takes hours per cycle.
  • Polling without lockfile — two instances process the same file in parallel.

Sources