[ 
https://issues.apache.org/activemq/browse/AMQ-1079?page=comments#action_37678 ] 
            
William Blackburn commented on AMQ-1079:
----------------------------------------

Please, ActiveMQ developers, please comment on this issue - it is a showstopper 
for us. Even the knowledge that you are unable to reproduce would be helpful, 
because we could then provide more data or test-cases. Our story is as follows:

We configure the master and slave according to the instructions on the site. 
They both start up OK, and we can see from the logs that the slave attaches to 
the master. But, as soon as the first connection is made to the master, the 
slave dies. When the client attempts to failover, the slave can't accept the 
connection of course, and everything fails.

The master log looks like:

INFO  DefaultDatabaseLocker          - Attempting to acquire the exclusive lock 
to become the Master broker
INFO  DefaultDatabaseLocker          - Becoming the master on dataSource: 
[EMAIL PROTECTED]
INFO  JournalPersistenceAdapter      - Journal Recovery Started from: Active 
Journal: using 5 x 20.0 Megs at: 
/Users/wblackburn/activemq-4.1.0-master/activemq-data/journal
INFO  JournalPersistenceAdapter      - Journal Recovered: 0 message(s) in 
transactions recovered.
INFO  TransportServerThreadSupport   - Listening for connections at: 
tcp://fastgt.local:61617
INFO  TransportConnector             - Connector openwire Started
INFO  BrokerService                  - ActiveMQ JMS Message Broker (localhost, 
ID:fastgt.local-50799-1166058345810-1:0) started
INFO  TransportConnection            - Slave Broker localhost is attached
ERROR MasterBroker                   - Slave Failed
java.lang.AssertionError: Unsupported Method
        at 
org.apache.activemq.transport.TransportSupport.request(TransportSupport.java:71)
        at 
org.apache.activemq.transport.TransportFilter.request(TransportFilter.java:88)
        at 
org.apache.activemq.transport.TransportFilter.request(TransportFilter.java:88)
        at 
org.apache.activemq.transport.MutexTransport.request(MutexTransport.java:49)
        at 
org.apache.activemq.broker.ft.MasterBroker.sendSyncToSlave(MasterBroker.java:363)
        at 
org.apache.activemq.broker.ft.MasterBroker.sendToSlave(MasterBroker.java:345)
        at 
org.apache.activemq.broker.ft.MasterBroker.acknowledge(MasterBroker.java:320)
        at 
org.apache.activemq.broker.MutableBrokerFilter.acknowledge(MutableBrokerFilter.java:88)
        at 
org.apache.activemq.broker.TransportConnection.processMessageAck(TransportConnection.java:488)
        at org.apache.activemq.command.MessageAck.visit(MessageAck.java:179)
        at 
org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:284)
        at 
org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:177)
        at 
org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:65)
        at 
org.apache.activemq.transport.WireFormatNegotiator.onCommand(WireFormatNegotiator.java:133)
        at 
org.apache.activemq.transport.InactivityMonitor.onCommand(InactivityMonitor.java:122)
        at 
org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:84)
        at 
org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:137)
        at java.lang.Thread.run(Thread.java:613)
ERROR MasterBroker                   - Slave Failed

master config is:

<beans>

  <!-- Allows us to use system properties as variables in this configuration 
file -->
  <bean 
class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/>

  <broker brokerName="localhost" useJmx="true" 
xmlns="http://activemq.org/config/1.0";>

    <persistenceAdapter>
        <journaledJDBC journalLogFiles="5" 
dataDirectory="${activemq.base}/activemq-data" dataSource="#postgres-ds"/>
    </persistenceAdapter>

    <transportConnectors>
       <transportConnector name="openwire" uri="tcp://localhost:61617"/>
    </transportConnectors>

  </broker>

  <!--  This xbean configuration file supports all the standard spring xml 
configuration options -->

  <!-- Postgres DataSource Sample Setup -->
    <bean id="postgres-ds" class="org.postgresql.ds.PGPoolingDataSource">
        <property name="serverName" value="localhost"/>
        <property name="databaseName" value="activemq"/>
        <property name="portNumber" value="0"/>
        <property name="user" value="activemq"/>
        <property name="password" value="activemq"/>
        <property name="dataSourceName" value="postgres"/>
        <property name="initialConnections" value="1"/>
        <property name="maxConnections" value="10"/>
    </bean>

</beans>



The slave log looks like:

INFO  DefaultDatabaseLocker          - Attempting to acquire the exclusive lock 
to become the Master broker
INFO  DefaultDatabaseLocker          - Becoming the master on dataSource: 
[EMAIL PROTECTED]
INFO  JournalPersistenceAdapter      - Journal Recovery Started from: Active 
Journal: using 5 x 20.0 Megs at: 
/Users/wblackburn/activemq-4.1.0-slave/activemq-data/journal
INFO  JournalPersistenceAdapter      - Journal Recovered: 0 message(s) in 
transactions recovered.
INFO  TransportServerThreadSupport   - Listening for connections at: 
tcp://fastgt.local:61618
INFO  TransportConnector             - Connector openwire Started
INFO  TransportConnector             - Connector vm://localhost Started
INFO  MasterConnector                - Starting a network connection between 
vm://localhost#0 and tcp://null:0 has been established.
INFO  BrokerService                  - ActiveMQ JMS Message Broker (localhost, 
ID:fastgt.local-50808-1166058365982-2:0) started
INFO  MasterConnector                - Slave connection between 
vm://localhost#0 and tcp://localhost/127.0.0.1:61617 has been established.

Slave config is:

<beans>

  <!-- Allows us to use system properties as variables in this configuration 
file -->
  <bean 
class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/>

  <broker brokerName="localhost" useJmx="true" 
xmlns="http://activemq.org/config/1.0"; 
masterConnectorURI="tcp://localhost:61617" shutdownOnMasterFailure="false">

    <persistenceAdapter>
        <journaledJDBC journalLogFiles="5" 
dataDirectory="${activemq.base}/activemq-data" dataSource="#postgres-ds"/>
    </persistenceAdapter>

    <transportConnectors>
       <transportConnector name="openwire" uri="tcp://localhost:61618"/>
    </transportConnectors>

  </broker>

  <!--  This xbean configuration file supports all the standard spring xml 
configuration options -->

<!-- Postgres DataSource Sample Setup -->
    <bean id="postgres-ds" class="org.postgresql.ds.PGPoolingDataSource">
        <property name="serverName" value="localhost"/>
        <property name="databaseName" value="amqslave"/>
        <property name="portNumber" value="0"/>
        <property name="user" value="activemq"/>
        <property name="password" value="activemq"/>
        <property name="dataSourceName" value="postgres"/>
        <property name="initialConnections" value="1"/>
        <property name="maxConnections" value="10"/>
    </bean>

</beans>


> Slave Fail Error when Receiving message on a MasterSlave configuration
> ----------------------------------------------------------------------
>
>                 Key: AMQ-1079
>                 URL: https://issues.apache.org/activemq/browse/AMQ-1079
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.2.0
>         Environment: Windows XP, jdk1.5
>            Reporter: Marlon Santos
>             Fix For: 4.2.0
>
>         Attachments: ConsumerTool.java, MasterSlave.java, ProducerTool.java
>
>
> A slave fail error is caught while receiving message from master broker on a 
> master slave configuration.
> I included the java files that I used. Running this through xbean/xml config 
> also produces the same error.
> SEVERE: Slave Failed
> java.lang.AssertionError: Unsupported Method
>       at 
> org.apache.activemq.transport.TransportSupport.request(TransportSupport.java:71)
>       at 
> org.apache.activemq.transport.TransportFilter.request(TransportFilter.java:88)
>       at 
> org.apache.activemq.transport.TransportFilter.request(TransportFilter.java:88)
>       at 
> org.apache.activemq.transport.MutexTransport.request(MutexTransport.java:49)
>       at 
> org.apache.activemq.broker.ft.MasterBroker.sendSyncToSlave(MasterBroker.java:363)
>       at 
> org.apache.activemq.broker.ft.MasterBroker.sendToSlave(MasterBroker.java:345)
>       at 
> org.apache.activemq.broker.ft.MasterBroker.acknowledge(MasterBroker.java:320)
>       at 
> org.apache.activemq.broker.MutableBrokerFilter.acknowledge(MutableBrokerFilter.java:88)
>       at 
> org.apache.activemq.broker.TransportConnection.processMessageAck(TransportConnection.java:491)
>       at org.apache.activemq.command.MessageAck.visit(MessageAck.java:179)
>       at 
> org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:287)
>       at 
> org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:178)
>       at 
> org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:65)
>       at 
> org.apache.activemq.transport.WireFormatNegotiator.onCommand(WireFormatNegotiator.java:133)
>       at 
> org.apache.activemq.transport.InactivityMonitor.onCommand(InactivityMonitor.java:122)
>       at 
> org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:84)
>       at 
> org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:137)
>       at java.lang.Thread.run(Thread.java:595)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to