Here is a networkbroker , i have an activemqcomponent which connects to
broker client broker.
in turn client broker is connected to another broker

<bean id="activemq"
class="org.apache.activemq.camel.component.ActiveMQComponent">
<property name="brokerURL" value="tcp://localhost:8010"/>
</bean>

<amq:broker brokerName="clientBroker" useShutdownHook="true" >
        <amq:networkConnectors>
            <amq:networkConnector  uri="static:(tcp://192.168.253.2:8007)"
duplex="true">
                <amq:staticallyIncludedDestinations>
                    <amq:queue name = "financials" physicalName="financials"
></amq:queue>
                </amq:staticallyIncludedDestinations>
            </amq:networkConnector>
        </amq:networkConnectors>
        <amq:transportConnectors>
            <amq:transportConnector uri = "tcp://localhost:8010" />
        </amq:transportConnectors>
    </amq:broker>

Here is the broker for my server

<amq:broker id="serverBroker" brokerName="serverBroker" persistent="false">
<amq:transportConnectors>
<amq:transportConnector uri="tcp://localhost:8007/">
            </amq:transportConnector>
</amq:transportConnectors>
</amq:broker>

<bean id="activemq"
class="org.apache.activemq.camel.component.ActiveMQComponent">
<property name="brokerURL" value="tcp://localhost:8007"/>
</bean>


On Thu, Jan 21, 2010 at 2:17 AM, Gary Tully <[email protected]> wrote:

> This does not sound right. The store and forward should happen async and
> should block pending a reconnect of the networkconnector in the event of a
> failure of the second broker.
> Can you post your activemq configuration?
>
> An active network connector is visible in JMX so you could validate its
> state through a JMX query but you should not need to be aware of that state
> when producing messages.
>
> 2010/1/21 Carlo Camerino <[email protected]>
>
> > Hi,
> >
> > I have a sistuation in which i use a network connector to communicate
> with
> > another broker,
> > my problem is that when the other networked connector is turned off,
> > activemq still trys to send a message to
> >
> > i'm using producertemplate in camel btw,
> >
> > object.sendRequest(body, "activemq:financials");
> >
> > financials is a queue which is configured to do a store and forward to
> the
> > other broker residing on another system.
> > ]
> >
> >
> > is there any way i could check that if networkbroker a's connection to
> > networkbroker b is down,
> > the system will automatically throw an exception.
> >
> > The default behavior seems to be, when i place a message on the "queue"
> on
> > broker a, the system still waits for the message to timeout.
> >
> > It doesn't alert me that no connection is available at all.
> >
> > How can this be avoided?
> >
> > Thanks A lot
> >
>
>
>
> --
> http://blog.garytully.com
>
> Open Source Integration
> http://fusesource.com
>

Reply via email to