[jboss-user] [Beginner's Corner] - Spring

zzpprk do-not-reply at jboss.com
Wed Jun 8 11:04:32 EDT 2011

zzpprk [http://community.jboss.org/people/zzpprk] created the discussion


To view the discussion, visit: http://community.jboss.org/message/609215#609215

Hello again

Spring is giving me a headache! This is not strictly JBoss but one of you guys might know.

I am currently working on a WEB service and the deployment WAR has a spring-ws-servlet.xml file. I am also working on a regular WEB application and that has a spring-servlet.xml file. What is the difference between those two files? Can they contain the same things?

I wish to add an MBeam to my WEB service so I can dynamically change the log4j logging level. I have found at http://www.unicon.net/node/614 that I can add the following lines to a config file but it does not say which one!

<bean id="mbeanServer" class="org.springframework.jmx.support.MBeanServerFactoryBean">
 <property name="defaultDomain" value="SRS Exstream"/>
 <property name="registerWithFactory" value="true"/>
 <property name="locateExistingServerIfPossible" value="true"/>
<bean id="exporter" class="org.springframework.jmx.export.MBeanExporter" lazy-init="false">
 <property name="beans">
   <entry key="bean:name=Log4jLevelChanger" value-ref="Log4jLevelChanger"/>
<bean id="Log4jLevelChanger" class="com.hp.exstream.project.gmac.util.Log4jLevelChanger">
 <property name="name" value="Log4jLevelChanger"/>

I tried adding the above to my spring-ws-servlet.xml file but this has not worked because my MBean does not show-up in jConsole.

Any ideas how to get this to work?



Reply to this message by going to Community

Start a new discussion in Beginner's Corner at Community

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20110608/c507050c/attachment-0001.html 

More information about the jboss-user mailing list