Posts

Showing posts with the label spring-integration

int-jdbc:inbound-channel-adapter channel depth

Image
Clash Royale CLAN TAG #URR8PPP int-jdbc:inbound-channel-adapter channel depth if the configured channel in int-jdbc:inbound-channel-adapter is full,after that polling happens or not ? Can I use a queue channel in int-jdbc:inbound-channel-adapter? My requirement is that if the channel is full,no DB call should make ,until channel is free. 1 Answer 1 You need to use a QueueChannel with restricted capacity. As far as any Inbound Channel Adapter uses a MessagingTemplate with the sendTimeout = -1 , the QueueChannel performs a put() operation on the underlying LinkedBlockingQueue : QueueChannel MessagingTemplate sendTimeout = -1 QueueChannel put() LinkedBlockingQueue /** * Inserts the specified element at the tail of this queue, waiting if * necessary for space to become available. * * @throws InterruptedException {@inheritDoc} * @throws NullPointerException {@inheritDoc} */ public void put(E e)...

Spring Integration : Remove Jms and Http Headers from Message

Image
Clash Royale CLAN TAG #URR8PPP Spring Integration : Remove Jms and Http Headers from Message I have a integration flow like this Subscriber & Publisher Broker->queue1->Transform->HTTP CALL->HTTP Response->JMS Message->Broker->queue2 This my integration flow DSL @Bean public IntegrationFlow orchestrationFlow() { return IntegrationFlows.from(Jms.messageDrivenChannelAdapter(connectionFactory).destination("MAILBOX")) //destination("amq.outbound1")) .<String, String>transform(s -> { return s.toLowerCase(); }).log() .transform(new PojoTransformer()) //.headerFilter("^(jms?|JMS)://.*$", true) .log() // HTTP part goes here .<String, HttpEntity<String>>transform(HttpEntity::new).handle( Http.outboundGateway("http://localhost:8080/uppsercase").httpMethod(HttpMethod.POST) ...