[jboss-user] [JBoss AOP] - Re: How to deploy a WebApplication in Tomcat with Jboss AOP?

DerMas do-not-reply at jboss.com
Tue Oct 21 10:22:26 EDT 2008


Works with my sample Project with xml bindings :)


  | public class ContextListener implements ServletContextListener {
  | 
  |     public void contextInitialized(ServletContextEvent arg0) {
  |     	try {
  | 			AspectXmlLoader.deployXML(new URL("file:/D:/dir/jboss-aop.xml"));
  | 	} catch (MalformedURLException e) {
  | 	} catch (Exception e) {}
  |     }
  |     public void contextDestroyed(ServletContextEvent arg0) {
  |     	//nothing
  |     }
  | }
  | 
Then added the ContextListener to the web.xml:



    <listener>
  |         <listener-class>package.ContextListener</listener-class>
  |     </listener>

I hope it's going to work just as good for my real project ;)

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4183533#4183533

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4183533



More information about the jboss-user mailing list