Closed jludvice closed 3 years ago
It's already possible to use idempotent consumer in route dsl like this:
import com.github.czgov.isds.Constants;
import org.apache.camel.processor.idempotent.MemoryIdempotentRepository;
from("isds:messages?environment=test&username=...")
.idempotentConsumer(header(Constants.MSG_ID), MemoryIdempotentRepository.memoryIdempotentRepository())
It means that message is first downloaded from isds
and then eventually filtered out by idempotent consumer.
It's worth checking implementation of camel file component and support this direclty in consumer (and don't download message if we don't need to).
http://camel.apache.org/file2.html
http://camel.apache.org/idempotent-consumer.html