Bruce
The distribution I am actually using is the latest FUSE which I believe
would be 3.1 of Service Mix and also let's forget about the Cluster
example for now since I don't really have any problem running it. I also
realized you don't need an example to see the cluster working, since
there is plenty in the logs to verify that. So. . .
When I exclude the Security Broker definition from my
servicemix-node1.xml (and node2 respectively) file, my last line in the
log when I start the first Node shows:
//
INFO - JBIContainer - ServiceMix JBI Container
(node1) started
//
Then I start the second Node and what I see is that Demand Forwarding
bridge has been established between the two nodes. Here is a fragment
from my log:
//
INFO - NetworkConnector - Establishing network connection
between from vm://peer--2344-1190377993829-3-0?
network=true to tcp://ustr-zhurako2:2354
DEBUG - WireFormatNegotiator - Sending: WireFormatInfo {
version=2, properties={TightEncodingEnabled=true, Cac
heSize=1024, TcpNoDelayEnabled=true, SizePrefixDisabled=false,
StackTraceEnabled=true, MaxInactivityDuration=30000, Cach
eEnabled=true}, magic=[A,c,t,i,v,e,M,Q]}
DEBUG - WireFormatNegotiator - Received WireFormat:
WireFormatInfo { version=2, properties={TightEncodingEnabl
ed=true, CacheSize=1024, TcpNoDelayEnabled=true,
SizePrefixDisabled=false, StackTraceEnabled=true, MaxInactivityDuration
=30000, CacheEnabled=true}, magic=[A,c,t,i,v,e,M,Q]}
DEBUG - WireFormatNegotiator - tcp://localhost/127.0.0.1:2354
before negotiation: OpenWireFormat{version=2, ca
cheEnabled=false, stackTraceEnabled=false, tightEncodingEnabled=false,
sizePrefixDisabled=false}
DEBUG - WireFormatNegotiator - tcp://localhost/127.0.0.1:2354
after negotiation: OpenWireFormat{version=2, cac
heEnabled=true, stackTraceEnabled=true, tightEncodingEnabled=true,
sizePrefixDisabled=false}
DEBUG - TransportConnection - Setting up new connection:
[EMAIL PROTECTED]
7d
INFO - DemandForwardingBridge - Network connection between
vm://peer--2344-1190377993829-3-0#2 and tcp://localh
ost/127.0.0.1:2354(peer--2352-1190378017751-3-0) has been established.
DEBUG - AbstractRegion - Adding consumer:
ID:ustr-zhurako2-2344-1190377993829-6:1:1:2
DEBUG - AbstractRegion - Adding destination:
queue://org.apache.servicemix.jms.node2
DEBUG - AbstractRegion - Adding destination:
topic://ActiveMQ.Advisory.Consumer.Queue.org.apache.service
mix.jms.node2
//
I do not see any errors or any of the messages you see above in my logs
if Security Broker is defined.
So, without Security Broker, when I deploy my sample services (not the
example) it all works as expected, so essentially I don't have problem
with setting up a cluster and if it was not for that XML segment I think
I would be OK, but it just bugs me when I don't understand why it is not
working when Security Broker configuration is defined.
I am also attaching servicemix-node1.xml
Thanks
Oleg
-----Original Message-----
From: Bruce Snyder [mailto:[EMAIL PROTECTED]
Sent: Friday, September 21, 2007 1:16 AM
To: [email protected]
Subject: Re: ServiceMix Cluster
On 9/20/07, Zhurakousky, Oleg <[EMAIL PROTECTED]> wrote:
> Guys
>
>
>
> I was just trying to extend clustering example that comes with
> distribution to run inside of main ServiceMix configuration (as
> conf/servicemix.xml). Obviously it didn't work, so I went through
> process of elimination or actually "build-up" by taking
> servicemix-poller.xml and moving components from servicemix.xml into
it
> and. got it to work. I also realized what was stopping it from working
> when I did it the first time, but I am not sure why. The issue was
with
> the Secured Broker configuration (see below) that apparently does not
> let two nodes join into the cluster. Once this XML segment removed I
see
> tow nodes joining in the cluster.
>
>
>
> ====
>
> <!-- Use a secured broker (see security.xml)
>
> and define the 3 standard flows -->
>
> <sm:broker>
>
> <sm:securedBroker authorizationMap="#authorizationMap">
>
> <sm:flows>
>
> <sm:sedaFlow />
>
> <sm:jmsFlow jmsURL="${activemq.url}" />
>
> <sm:jcaFlow connectionManager="#connectionManager"
>
> jmsURL="${activemq.url}" />
>
> </sm:flows>
>
> </sm:securedBroker>
>
> </sm:broker>
>
> ====
>
>
>
> I'll be looking at the source tomorrow, but would appreciate if anyone
> could point me in the right direction as to Why Secure Broker
> configuration
What version of ServiceMix are you using? To what clustering example
are you referring, possibly the old one? Did you see any errors? If so
please post them.
Bruce
--
perl -e 'print
unpack("u30","D0G)[EMAIL PROTECTED]&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
);'
Apache ActiveMQ - http://activemq.org/
Apache ServiceMix - http://servicemix.org/
Apache Geronimo - http://geronimo.apache.org/
Castor - http://castor.org/
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<beans xmlns:sm="http://servicemix.apache.org/config/1.0"
xmlns:foo="http://servicemix.org/demo/">
<bean id="jndi" class="org.apache.xbean.spring.jndi.SpringInitialContextFactory"
factory-method="makeInitialContext" singleton="true" />
<bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="location" value="classpath:servicemix.properties" />
</bean>
<import resource="classpath:security.xml" />
<import resource="classpath:jmx.xml" />
<import resource="classpath:activemq.xml" />
<import resource="classpath:tx.xml" />
<import resource="classpath:jndi.xml" />
<!-- the JBI container
<sm:container id="jbi"
name="node1"
flowName="jms"
useMBeanServer="true"
createMBeanServer="true"
rmiPort="1299">
-->
<sm:container id="jbi"
name="node1"
rootDir="./data/smx"
installationDirPath="./node1/install"
deploymentDirPath="./node1/deploy"
MBeanServer="#jmxServer"
transactionManager="#transactionManager"
createJmxConnector="true"
monitorInterval="1"
flowName="jms"
depends-on="jndi">
<!-- Use a secured broker (see security.xml)
and define the 3 standard flows
<sm:broker>
<sm:securedBroker authorizationMap="#authorizationMap">
<sm:flows>
<sm:sedaFlow />
<sm:jmsFlow jmsURL="${activemq.url}" />
<sm:jcaFlow connectionManager="#connectionManager"
jmsURL="${activemq.url}" />
</sm:flows>
</sm:securedBroker>
</sm:broker>
-->
<sm:services>
<sm:statistics statsInterval="10" dumpStats="true" />
</sm:services>
<sm:executorFactory>
<bean class="org.apache.servicemix.executors.impl.ExecutorFactoryImpl">
<property name="defaultConfig">
<bean class="org.apache.servicemix.executors.impl.ExecutorConfig">
<property name="corePoolSize" value="${servicemix.corePoolSize}"/>
<property name="maximumPoolSize" value="${servicemix.maximumPoolSize}"/>
<property name="queueSize" value="${servicemix.queueSize}"/>
</bean>
</property>
</bean>
</sm:executorFactory>
<sm:activationSpecs>
</sm:activationSpecs>
</sm:container>
</beans>