Kenmegne
7 days ago 23a46b4be35277e06ec89f48730eeb694e686be8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package com.megatim.fdxconsultation.service.impl.camel.routes.in;
 
import com.fdx.messaging.common.FdxMessagingContext;
import com.fdx.messaging.common.StandaloneServerState;
import com.megatim.fdxconsultation.service.impl.camel.consumer.StandaloneServerStateConsumer;
import com.megatim.fdxconsultation.service.resolvers.JacksonMapperFormat;
import org.apache.camel.builder.RouteBuilder;
 
/**
 *
 * @author ASUS
 */
public class StandaloneServerStateConsumerRoute extends RouteBuilder {
 
    @Override
    public void configure() throws Exception {
 
        from("rabbitmq:"
                + FdxMessagingContext.STANDALONE_SERVER_EXCHANGE
                + "?queue=" + FdxMessagingContext.STANDALONE_SERVER_QUEUE
                + "&routingKey=" + FdxMessagingContext.STANDALONE_SERVER_ROUTING_KEY
                + "&autoDelete=false")
                .unmarshal(JacksonMapperFormat.jacksonDataFormat(StandaloneServerState.class))
                .bean(StandaloneServerStateConsumer.class);
    }
}