Question: How can I convert `<int-jms:outbound-channel-adapter channel="topicChannel" destination="requestQueue"/>` to equivalent [Spring Integration DSL](https://github.com/spring-projects/spring-integration-java-dsl/wiki/spring-integration-java-dsl-reference) in java 1.7 

Below is the ActiveMQ configuration:

```
<bean id="connectionFactory" class="org.springframework.jms.connection.CachingConnectionFactory">
    <property name="targetConnectionFactory">
        <bean class="org.apache.activemq.ActiveMQConnectionFactory">
            <property name="brokerURL" value="tcp://localhost:61616"/>
        </bean>
    </property>
    <property name="sessionCacheSize" value="10"/>
</bean>

<bean id="requestQueue" class="org.apache.activemq.command.ActiveMQQueue">
    <constructor-arg value="queue.demo"/>
</bean>

```

Answer: 
```
var obj = [{"taxAmount":572.26,"totalAmount":2004,"totalDiscount":0,"totalItems":12,"gTotal":2576.2599999999998,"count":4,"deployment":{"_id":"554c92f979d26026307a5a9b","name":"Punjabi Bagh"}},
{"taxAmount":304.9,"totalAmount":1111,"totalDiscount":0,"totalItems":9,"gTotal":1415.8999999999999,"count":2,"deployment":{"_id":"554c930579d26026307a5a9c","name":"Pitampura"}},
{"deployment":{"_id":"554c930c79d26026307a5a9d","name":"Model Town"}},   
{"deployment":{"_id":"554c945079d26026307a5cae","name":"Dwarka"}},
{"deployment":{"_id":"554cd66c0a40ccd2416e38e7","name":"Green Park"}}],
    sumObj = { "taxAmount":0, "totalAmount":0 };

for( var o in obj ){
    sumObj.taxAmount += obj[ o ].taxAmount || 0;
    sumObj.totalAmount += obj[ o ].totalAmount || 0;
}

```

This `obj[ o ].taxAmount || 0` tests if `obj[ o ]` has property `taxAmount` and if it's true-like. If it does, return it, else return 0.
Not sure what you realy want. Is it this ?

```
var obj = [{"taxAmount":572.26,"totalAmount":2004,"totalDiscount":0,"totalItems":12,"gTotal":2576.2599999999998,"count":4,"deployment":{"_id":"554c92f979d26026307a5a9b","name":"Punjabi Bagh"}},
{"taxAmount":304.9,"totalAmount":1111,"totalDiscount":0,"totalItems":9,"gTotal":1415.8999999999999,"count":2,"deployment":{"_id":"554c930579d26026307a5a9c","name":"Pitampura"}},
{"deployment":{"_id":"554c930c79d26026307a5a9d","name":"Model Town"}},   
{"deployment":{"_id":"554c945079d26026307a5cae","name":"Dwarka"}},
{"deployment":{"_id":"554cd66c0a40ccd2416e38e7","name":"Green Park"}}],
    sumObj = { "taxAmount":[], "totalAmount":[] };

for( var o in obj ){
    var current = obj[ o ];
    current.taxAmount && sumObj.taxAmount.push( current.taxAmount );
    current.totalAmount && sumObj.totalAmount.push( current.totalAmount  );
}

```