What version of AMQ are you using? I deloyed your activemq.xml file, as is, on to my 6-week old 4.2-SNAPSHOT broker. No problema!
To successfully deploy it on to my 4.1.1 broker, I had to first comment out the xmpp transport connector and jetty elements. Joe Elber wrote: > > I don't made changes in my activemq.xml. > > activemq.xml: > > <!-- > 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. > --> > <!-- START SNIPPET: example --> > <beans> > > <!-- Allows us to use system properties as variables in this > configuration file --> > <bean > class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/> > > <broker xmlns="http://activemq.org/config/1.0" brokerName="localhost" > dataDirectory="${activemq.base}/data"> > > <!-- Destination specific policies using destination names or > wildcards --> > <destinationPolicy> > <policyMap> > <policyEntries> > > <policyEntry topic="FOO.>"> > <dispatchPolicy> > <strictOrderDispatchPolicy/> > </dispatchPolicy> > <subscriptionRecoveryPolicy> > <lastImageSubscriptionRecoveryPolicy/> > </subscriptionRecoveryPolicy> > </policyEntry> > > </policyEntries> > </policyMap> > </destinationPolicy> > > > <!-- The transport connectors ActiveMQ will listen to --> > <transportConnectors> > <transportConnector name="openwire" uri="tcp://localhost:61616" > discoveryUri="multicast://default"/> > <transportConnector name="ssl" uri="ssl://localhost:61617"/> > <transportConnector name="stomp" uri="stomp://localhost:61613"/> > <transportConnector name="xmpp" uri="xmpp://localhost:61222"/> > </transportConnectors> > > <!-- The store and forward broker networks ActiveMQ will listen to --> > <networkConnectors> > <!-- by default just auto discover the other brokers --> > <networkConnector name="default-nc" uri="multicast://default"/> > <!-- > <networkConnector name="host1 and host2" > uri="static://(tcp://host1:61616,tcp://host2:61616)" failover="true"/> > --> > </networkConnectors> > > > <!-- Use the following if you wish to configure the journal with JDBC > --> > <!-- > <persistenceAdapter> > <journaledJDBC journalLogFiles="5" > dataDirectory="${activemq.base}/activemq-data" > dataSource="#postgres-ds"/> > </persistenceAdapter> > --> > > <!-- Or if you want to use pure JDBC without a journal --> > <!-- > <persistenceAdapter> > <jdbcPersistenceAdapter dataSource="#postgres-ds"/> > </persistenceAdapter> > --> > > <!-- Use the following to set the broker memory limit > <memoryManager> > <usageManager id="memory-manager" limit="20 MB"/> > </memoryManager> > --> > > <!-- Use the following to configure how ActiveMQ is exposed in JMX > <managementContext> > <managementContext connectorPort="1099" > jmxDomainName="org.apache.activemq"/> > </managementContext> > --> > > </broker> > > <!-- lets create a command agent to respond to message based admin > commands on the ActiveMQ.Agent topic --> > <commandAgent xmlns="http://activemq.org/config/1.0"/> > > > <!-- An embedded servlet engine for serving up the Admin console --> > <jetty xmlns="http://mortbay.com/schemas/jetty/1.0"> > <connectors> > <nioConnector port="8161" /> > </connectors> > > <handlers> > <webAppContext contextPath="/admin" > resourceBase="${activemq.base}/webapps/admin" logUrlOnStart="true" /> > <webAppContext contextPath="/demo" > resourceBase="${activemq.base}/webapps/demo" logUrlOnStart="true" /> > </handlers> > </jetty> > > > > <!-- 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> > --> > > <!-- MySql DataSource Sample Setup --> > <!-- > <bean id="mysql-ds" class="org.apache.commons.dbcp.BasicDataSource" > destroy-method="close"> > <property name="driverClassName" value="com.mysql.jdbc.Driver"/> > <property name="url" > value="jdbc:mysql://localhost/activemq?relaxAutoCommit=true"/> > <property name="username" value="activemq"/> > <property name="password" value="activemq"/> > <property name="poolPreparedStatements" value="true"/> > </bean> > --> > > <!-- Oracle DataSource Sample Setup --> > <!-- > <bean id="oracle-ds" class="org.apache.commons.dbcp.BasicDataSource" > destroy-method="close"> > <property name="driverClassName" > value="oracle.jdbc.driver.OracleDriver"/> > <property name="url" value="jdbc:oracle:thin:@localhost:1521:AMQDB"/> > <property name="username" value="scott"/> > <property name="password" value="tiger"/> > <property name="poolPreparedStatements" value="true"/> > </bean> > --> > > <!-- Embedded Derby DataSource Sample Setup --> > <!-- > <bean id="derby-ds" class="org.apache.derby.jdbc.EmbeddedDataSource"> > <property name="databaseName" value="derbydb"/> > <property name="createDatabase" value="create"/> > </bean> > --> > > </beans> > <!-- END SNIPPET: example --> > > > > > > TOPPER_HARLEY wrote: >> >> [quote]"Error creating bean with name >> 'org.apache.activemq.xbean.XBeanBrokerService' defined in class path >> resource [activemq.xml]: Error setting property values; nested exception >> is org.springframework.beans.NotWritablePropertyException: Invalid >> property '-' of bean class >> [org.apache.activemq.xbean.XBeanBrokerService]: Bean property '-' is not >> writable or has an invalid setter method. Does the parameter type of the >> setter match the return type of the getter? "[/quote] >> >> It looks to me that your XML configuration of the broker has a typo or >> something simple like that as it seems to be trying to set a property >> "-". You should put you config so we can have a look.... >> >> /Tom >> > > -- View this message in context: http://www.nabble.com/Running-ActiveMQ-on-a-single-machine-tf4155961s2354.html#a11945560 Sent from the ActiveMQ - User mailing list archive at Nabble.com.