activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Tully <gary.tu...@gmail.com>
Subject Re: durable subscription problems
Date Tue, 17 Aug 2010 22:49:32 GMT
Schema validation is the default with spring 3. Elements in the broker
sequence must follow alphabetical ordering 2 validate.

On Tuesday, August 17, 2010, Joe Niski <joe.niski@nwea.org> wrote:
> Greetings again, Dejan:
>
> I tried setting up another Remote broker using the 5.40 release, just dropping my existing
configuration files into place.
>
> I'm getting this parsing error on startup:
> ERROR: java.lang.RuntimeException: Failed to execute start task. Reason: org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException:
Line 86 in XML document from class path resource [activemq.xml] is invalid; nested exception
is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting
with element 'amq:destinationPolicy'. One of '{"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:producerSystemUsage,
"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:proxyConnectors,
"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:regionBroker,
"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:services,
"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:shutdownHooks,
"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:sslContext,
"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:systemUsage,
"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:taskRunnerFactory,
"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:tempDataStore,
"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:transportConnectorURIs,
"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>:transportConnectors,
WC[##other:"http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>]}'
is expected.
>
>
> The content of my activemq.xml is pasted below. Even though i'm forcing the schemaLocation
to http://activemq.apache.org/schema/core/activemq-core-5.3.0.xsd, is AMQ trying to validate
teh file against the 5.4.0 schema?
>
> <beans xmlns="http://www.springframework.org/schema/beans"<http://www.springframework.org/schema/beans>
>        xmlns:amq="http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>
>        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"<http://www.w3.org/2001/XMLSchema-instance>
>        xsi:schemaLocation="http://www.springframework.org/schema/beans
>             http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
>             http://activemq.apache.org/schema/core
>             http://activemq.apache.org/schema/core/activemq-core-5.3.0.xsd">
>
>     <!--
>         Allows us to use system properties as variables in this configuration
>         file. For more information, see the Javadoc:
>
>         http://static.springframework.org/spring/docs/2.5.x/api/org/springframework/beans/factory/config/PropertyPlaceholderConfigurer.html
>     -->
>     <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
>         <property name="locations">
>             <list>
>                 <value>file:${activemq.base}/conf/messaging.conf</value>
>                 <value>file:${activemq.base}/conf/credentials.properties</value>
>             </list>
>         </property>
>     </bean>
>
>     <!--
>         The <broker> element is used to configure the ActiveMQ broker. Tips:
-
>         Change the brokerName attribute to something unique
>     -->
>     <broker xmlns="http://activemq.apache.org/schema/core"<http://activemq.apache.org/schema/core>
>             brokerName="${ApplianceID}" useJmx="true" advisorySupport="true"  dataDirectory="${activemq.base}/data">
>
>         <!--  Define Queue and Topic Names -->
>         <destinations>
>             <!-- for remote_messaging app -->
>             <queue physicalName="org.nwea.queues.local.inbound.notifications_and_alerts"/>
>             <queue physicalName="org.nwea.queues.local.internal.invalidmessages"/>
>             <queue physicalName="org.nwea.queues.local.internal.updated_entities_to_mto"/>
>             <queue physicalName="org.nwea.queues.local.internal.notifications_and_alerts"/>
>             <queue physicalName="org.nwea.queues.local.internal.from_central.hold_for_upgrade"/>
>             <queue physicalName="org.nwea.queues.local.outbound.data_updates"/>
>             <!-- for Reports app -->
>             <queue physicalName="inbound.rptreq.q"/>
>             <queue physicalName="internal.largerptreq.q"/>
>             <queue physicalName="internal.rptreq.q"/>
>             <queue physicalName="inbound.tt2etl.q"/>
>             <queue physicalName="internal.tt2etl.q"/>
>         </destinations>
>
>         <plugins>
>             <jaasAuthenticationPlugin configuration="activemq-domain"/>
>             <authorizationPlugin>
>                 <map>
>                     <authorizationMap>
>                         <authorizationEntries>
>                             <authorizationEntry topic=">"
>                                                 read="admins"
>                                                 write="admins"
>                                                 admin="admins"/>
>                             <authorizationEntry topic="ActiveMQ.Advisory.>"
>                                                 read="remotepeer"
>                                                 write="remotepeer"
>                                                 admin="remotepeer"/>
>                             <authorizationEntry topic="org.nwea.topics.>"
>                                                 write="remotepeer"
>                                                 admin="remotepeer"/>
>                             <authorizationEntry queue=">"
>                                                 read="admins"
>                                                 write="admins"
>                                                 admin="admins"/>
>                             <authorizationEntry queue="org.nwea.queues.central.>"
>                                                 read="remotepeer"
>                                                 admin="remotepeer"/>
>                         </authorizationEntries>
>                     </authorizationMap>
>                 </map>
>             </authorizationPlugin>
>         </plugins>
>         <!--
>             Examples of destination-specific policies using destination names or
>             wildcards. For more information, see:
>
>             http://activemq.apache.org/per-destination-policies.html
>             http://activemq.apache.org/destination-features.html
>             http://activemq.apache.org/slow-consumer-handling.html
>             http://activemq.apache.org/subscription-recovery-policy.html
>         -->
>         <destinationPolicy>
>             <policyMap>
>                 <policyEntries>
>                     <!-- originally set to 5mb -->
>                     <policyEntry queue=">" producerFlowControl="true"
>                                  memoryLimit="${remote_baseQueueMemory}mb"/>
>                     <policyEntry topic=">" producerFlowControl="true"
>                                  memoryLimit="${remote_baseTopicMemory}mb">
>                         <dispatchPolicy>
>                             <!--
>                                 Use total ordering, see:
>                                 http://activemq.apache.org/total-ordering.html
>                             -->
>                             <strictOrderDispatchPolicy/>
>                         </dispatchPolicy>
>                         <subscriptionRecoveryPolicy>
>                             <!--
>                                 Upon subscription, receive the last image
sent on the
>                                 destination.
>                             -->
>                             <lastImageSubscriptionRecoveryPolicy/>
>                         </subscriptionRecoveryPolicy>
>                     </policyEntry>
>
>                     <!-- nwea dead letter policy -->
>                     <!--
>                         http://activemq.apache.org/schema/core/activemq-core-5.2.0.xsd.html
>                     -->
>                     <!-- originally set to 100mb -->
>                     <policyEntry queue="org.nwea.>" memoryLimit="${remote_deadLetterQueueMemory}mb">
>                         <deadLetterStrategy>
>                             <individualDeadLetterStrategy processExpired="true"
>                                                         
 processNonPersistent="true"
>                                                         
 queuePrefix="nwea_dlq_queue.">
>                             </individualDeadLetterStrategy>
>                         </deadLetterStrategy>
>                     </policyEntry>
>
>             http://activemq.apache.org/networks-of-brokers.html
>         -->
>         <networkConnectors>
>             <networkConnector name="${ApplianceID}"
>                               userName="${networkConnectorUserName}"
>                               password="${networkConnectorPassword}"
>                               uri="static://(ssl://${Central.ServerHostname}:${central_sslPortNumber})"
>                               duplex="true"
>                               dynamicOnly="true">
>                 <dynamicallyIncludedDestinations>
>                     <queue physicalName="org.nwea.queues.central.>"/>
>                     <topic physicalName="org.nwea.topics.>"/>
>                 </dynamicallyIncludedDestinations>
>                 <staticallyIncludedDestinations>
>                     <queue physicalName="org.nwea.queues.central.>"/>
>                     <topic physicalName="org.nwea.topics.>"/>
>                 </staticallyIncludedDestinations>
>             </networkConnector>
>         </networkConnectors>
>
>         <!--
>             Configure message persistence for the broker. The default
>             persistence mechanism is the AMQ store (identified by the
>             amqPersistenceAdapter).  For more information, see:
>
>             http://activemq.apache.org/persistence.html
>         -->
>         <persistenceAdapter>
>             <kahaDB directory="${activemq.base}/data/${ApplianceID}/kahadb"
>                     indexWriteBatchSize="1000" enableIndexWriteAsync="true"
>                     enableJournalDiskSyncs="false"/>
>         </persistenceAdapter>
>
>         <!-- ssl configuration -->
>         <sslContext>
>             <sslContext keyStore="file:${activemq.base}/conf/broker.ks"<file:${activemq.base}/conf/broker.ks>
>                         keyStorePassword="password"
>                         trustStore="file:${activemq.base}/conf/broker.ts"<file:${activemq.base}/conf/broker.ts>
>                         trustStorePassword="password"/>
>         </sslContext>
>
>
>         <!--
>             The systemUsage controls the maximum amount of space the broker will
>             use before slowing down producers. For more information, see:
>
>             http://activemq.apache.org/producer-flow-control.html
>         -->
>         <systemUsage>
>             <systemUsage>
>                 <memoryUsage>
>                     <!-- originally set to 100 mb -->
>                     <memoryUsage limit="${remote_systemMemoryUsage} mb"/>
>                 </memoryUsage>
>                 <storeUsage>
>                     <!-- originally set to 1 gb -->
>                     <storeUsage limit="${remote_systemStoreUsage} gb"/>
>                 </storeUsage>
>                 <tempUsage>
>                     <!-- originally set to 200 mb -->
>                     <tempUsage limit="${remote_systemTempUsage} mb"/>
>                 </tempUsage>
>
>
>
> Joe Niski
> IS Development |  NWEA
>
> PHONE 503.212.3382  |  FAX 503.639.7873
>
> NWEA.ORG<3D%22http://www.nwea.org/%22>  |  Partnering to Help All Kids Learn
>
> On 08/17/2010 03:26 AM, Dejan Bosanac wrote:
>
> Hi Joe,
>
> this sounds like a bug. Did you tested it with some newer version of
> ActiveMQ (as there was a lot of work in that area since 5.0.3)
>
> Can you test newly released 5.4.0
> http://repo1.maven.org/maven2/org/apache/activemq/apache-activemq/5.4.0/
> and see if the problem still exists?
>
> If it's still there, it would be great if you could raise a Jira
> issue, ideally with a test case.
>
> Cheers
> --
> Dejan Bosanac - http://twitter.com/dejanb
>
> Open Source Integration - http://fusesource.com/
> ActiveMQ in Action - http://www.manning.com/snyder/
> Blog - http://www.nighttale.net
>
> On Tue, Aug 17, 2010 at 2:00 AM, Joe

-- 
http://blog.garytully.com

Open Source Integration
http://fusesource.com

Mime
View raw message