[jboss-user] [JBoss Microcontainer Users] - Re: Confused about POJO service

karypid do-not-reply at jboss.com
Thu Oct 8 07:43:19 EDT 2009


Would that be packaged in a JAR for JBoss to pick it up?

My current test (which does not get activated) is a JAR with one class and one interface (the interface defines the start/stop methods) as follows:

public class MyServiceImpl implements MyService {
  | 	private Logger logger;
  | 
  | 	public void start() {
  | 		logger = LoggerFactory.getLogger(MyServiceImpl.class);
  | 		logger.info("has been started");
  | 	}
  | 
  | 	public void stop() {
  | 		logger.info("has been shut down");
  | 		logger = null;
  | 	}
  | }

It contains a META-INF/my-service-beans.xml as follows:
<?xml version="1.0" encoding="UTF-8"?>
  | <deployment xmlns="urn:jboss:bean-deployer:2.0">
  | 	<bean name="MyService" class="test.MyServiceImpl" />
  | </deployment>

I drop it into the deploy folder (archived, not exploded) but nothing happens.


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

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



More information about the jboss-user mailing list