org.jboss.ejb
Class MessageDrivenContainer

java.lang.Object
  extended byorg.jboss.mx.util.JBossNotificationBroadcasterSupport (src) 
      extended byorg.jboss.system.ServiceMBeanSupport (src) 
          extended byorg.jboss.ejb.Container (src) 
              extended byorg.jboss.ejb.MessageDrivenContainer
All Implemented Interfaces:
AllowedOperationsFlags (src) , EJBProxyFactoryContainer (src) , InstancePoolContainer (src) , MBeanRegistration (src) , NotificationBroadcaster (src) , NotificationEmitter (src) , Service (src) , ServiceMBean (src)

public class MessageDrivenContainer
extends Container (src)
implements EJBProxyFactoryContainer (src) , InstancePoolContainer (src)

The container for MessageDriven beans.


Nested Class Summary
 
Nested classes inherited from class org.jboss.ejb.Container (src)
Container.AbstractContainerInterceptor (src)
 
Field Summary
protected  java.util.Map beanMapping
          These are the mappings between the remote interface methods and the bean methods.
protected  InstancePool (src) instancePool
          This is the instancepool that is to be used.
protected  Interceptor (src) interceptor
          This is the first interceptor in the chain.
protected  long messageCount
           
 
Fields inherited from class org.jboss.ejb.Container (src)
BASE_EJB_CONTAINER_NAME, beanClass, classLoader, createCount, EJB_CONTAINER_QUERY_NAME, EJB_TIMEOUT, ejbModule, EJBOBJECT_REMOVE, homeInterface, invokeStats, jaccContextID, localClassLoader, localHomeInterface, localInterface, localProxyFactory, lockManager, marshalledInvocationMapping, metaData, ORB_NAME, proxyFactories, proxyFactoryTL, remoteInterface, removeCount, rm, securityProxy, sm, tm, webClassLoader
 
Fields inherited from class org.jboss.system.ServiceMBeanSupport (src)
log, server, SERVICE_CONTROLLER_SIG, serviceName
 
Fields inherited from interface org.jboss.ejb.AllowedOperationsFlags (src)
IN_AFTER_BEGIN, IN_AFTER_COMPLETION, IN_BEFORE_COMPLETION, IN_BUSINESS_METHOD, IN_EJB_ACTIVATE, IN_EJB_CREATE, IN_EJB_FIND, IN_EJB_HOME, IN_EJB_LOAD, IN_EJB_PASSIVATE, IN_EJB_POST_CREATE, IN_EJB_REMOVE, IN_EJB_STORE, IN_EJB_TIMEOUT, IN_INTERCEPTOR_METHOD, IN_SERVICE_ENDPOINT_METHOD, IN_SET_ENTITY_CONTEXT, IN_SET_MESSAGE_DRIVEN_CONTEXT, IN_SET_SESSION_CONTEXT, IN_UNSET_ENTITY_CONTEXT, NOT_ALLOWED
 
Fields inherited from interface org.jboss.system.ServiceMBean (src)
CREATE_EVENT, CREATED, DESTROY_EVENT, DESTROYED, FAILED, REGISTERED, START_EVENT, STARTED, STARTING, states, STOP_EVENT, STOPPED, STOPPING, UNREGISTERED
 
Constructor Summary
MessageDrivenContainer()
           
 
Method Summary
 void addInterceptor(Interceptor (src)  in)
           
 EJBObject (src) createHome()
           
protected  void createService()
          The EJBDeployer calls this method.
protected  void destroyService()
          A default implementation of destroying the container service (no-op).
 EJBMetaData (src) getEJBMetaDataHome()
           
 java.lang.Class getHomeClass()
          EJBProxyFactoryContainer - not needed, should we skip inherit this or just throw Error??
 HomeHandle (src) getHomeHandleHome()
           
 InstancePool (src) getInstancePool()
          Get the instance pool for the container.
 Interceptor (src) getInterceptor()
           
 java.lang.Class getLocalClass()
          ???
 java.lang.Class getLocalHomeClass()
          ???
 LocalProxyFactory (src) getLocalProxyFactory()
          ???
 long getMessageCount()
           
 java.lang.Class getRemoteClass()
          ???
 java.lang.Object internalInvoke(Invocation (src)  mi)
          This method does invocation interpositioning of tx and security, retrieves the instance from an object table, and invokes the method on the particular instance
 java.lang.Object internalInvokeHome(Invocation (src)  mi)
          This method is called when a method call comes in on the Home object.
 void removeHome(Handle (src)  handle)
           
 void removeHome(java.lang.Object primaryKey)
           
 void setInstancePool(InstancePool (src)  instancePool)
           
protected  void startService()
          A default implementation of starting the container service.
protected  void stopService()
          A default implementation of stopping the container service (no-op).
 
Methods inherited from class org.jboss.ejb.Container (src)
addProxyFactory, createBeanClassInstance, getBeanClass, getBeanMetaData, getClassLoader, getCreateCount, getDeploymentInfo, getEjbModule, getEnvContext, getInvokeStats, getJaccContextID, getJmxName, getLocalClassLoader, getLockManager, getMessageDestination, getMethodPermissions, getProxyFactory, getRealmMapping, getRemoveCount, getSecurityManager, getSecurityProxy, getTimerService, getTransactionManager, getWebClassLoader, invoke, isCallByValue, lookupProxyFactory, removeTimerService, setBeanMetaData, setClassLoader, setDeploymentInfo, setEjbModule, setJaccContextID, setLocalClassLoader, setLockManager, setProxyFactory, setRealmMapping, setSecurityManager, setSecurityProxy, setTransactionManager, setWebClassLoader
 
Methods inherited from class org.jboss.system.ServiceMBeanSupport (src)
create, destroy, getLog, getName, getNextNotificationSequenceNumber, getObjectName, getServer, getServiceName, getState, getStateString, jbossInternalCreate, jbossInternalDescription, jbossInternalDestroy, jbossInternalLifecycle, jbossInternalStart, jbossInternalStop, postDeregister, postRegister, preDeregister, preRegister, start, stop
 
Methods inherited from class org.jboss.mx.util.JBossNotificationBroadcasterSupport (src)
addNotificationListener, getNotificationInfo, handleNotification, removeNotificationListener, removeNotificationListener, sendNotification
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jboss.ejb.EJBProxyFactoryContainer (src)
getProxyFactory
 

Field Detail

beanMapping

protected java.util.Map beanMapping
These are the mappings between the remote interface methods and the bean methods.


instancePool

protected InstancePool (src)  instancePool
This is the instancepool that is to be used.


interceptor

protected Interceptor (src)  interceptor
This is the first interceptor in the chain. The last interceptor must be provided by the container itself.


messageCount

protected long messageCount
Constructor Detail

MessageDrivenContainer

public MessageDrivenContainer()
Method Detail

getLocalProxyFactory

public LocalProxyFactory (src)  getLocalProxyFactory()
Description copied from interface: EJBProxyFactoryContainer (src)
???

Specified by:
getLocalProxyFactory in interface EJBProxyFactoryContainer (src)
Returns:
???

setInstancePool

public void setInstancePool(InstancePool (src)  instancePool)

getInstancePool

public InstancePool (src)  getInstancePool()
Description copied from interface: InstancePoolContainer (src)
Get the instance pool for the container.

Specified by:
getInstancePool in interface InstancePoolContainer (src)
Returns:
The instance pool for the container.

addInterceptor

public void addInterceptor(Interceptor (src)  in)
Specified by:
addInterceptor in class Container (src)

getInterceptor

public Interceptor (src)  getInterceptor()

getMessageCount

public long getMessageCount()
Returns:
the number of messages delivered

getHomeClass

public java.lang.Class getHomeClass()
EJBProxyFactoryContainer - not needed, should we skip inherit this or just throw Error??

Specified by:
getHomeClass in interface EJBProxyFactoryContainer (src)
Overrides:
getHomeClass in class Container (src)

getRemoteClass

public java.lang.Class getRemoteClass()
Description copied from interface: EJBProxyFactoryContainer (src)
???

Specified by:
getRemoteClass in interface EJBProxyFactoryContainer (src)
Overrides:
getRemoteClass in class Container (src)

getLocalClass

public java.lang.Class getLocalClass()
Description copied from interface: EJBProxyFactoryContainer (src)
???

Specified by:
getLocalClass in interface EJBProxyFactoryContainer (src)
Overrides:
getLocalClass in class Container (src)

getLocalHomeClass

public java.lang.Class getLocalHomeClass()
Description copied from interface: EJBProxyFactoryContainer (src)
???

Specified by:
getLocalHomeClass in interface EJBProxyFactoryContainer (src)
Overrides:
getLocalHomeClass in class Container (src)

createService

protected void createService()
                      throws java.lang.Exception
Description copied from class: Container (src)
The EJBDeployer calls this method. The EJBDeployer has set all the plugins and interceptors that this bean requires and now proceeds to initialize the chain. The method looks for the standard classes in the URL, sets up the naming environment of the bean. The concrete container classes should override this method to introduce implementation specific initialization behaviour.

Overrides:
createService in class Container (src)
Throws:
java.lang.Exception - if loading the bean class failed (ClassNotFoundException) or setting up "java:" naming environment failed (DeploymentException)

startService

protected void startService()
                     throws java.lang.Exception
Description copied from class: Container (src)
A default implementation of starting the container service. The container registers it's dynamic MBean interface in the JMX base. The concrete container classes should override this method to introduce implementation specific start behaviour. todo implement the service lifecycle methods in an xmbean interceptor so non lifecycle managed ops are blocked when mbean is not started.

Overrides:
startService in class Container (src)
Throws:
java.lang.Exception - An exception that occured during start

stopService

protected void stopService()
                    throws java.lang.Exception
Description copied from class: Container (src)
A default implementation of stopping the container service (no-op). The concrete container classes should override this method to introduce implementation specific stop behaviour.

Overrides:
stopService in class Container (src)
Throws:
java.lang.Exception

destroyService

protected void destroyService()
                       throws java.lang.Exception
Description copied from class: Container (src)
A default implementation of destroying the container service (no-op). The concrete container classes should override this method to introduce implementation specific destroy behaviour.

Overrides:
destroyService in class Container (src)
Throws:
java.lang.Exception

internalInvokeHome

public java.lang.Object internalInvokeHome(Invocation (src)  mi)
                                    throws java.lang.Exception
Description copied from class: Container (src)
This method is called when a method call comes in on the Home object. The Container forwards this call to the interceptor chain for further processing.

Specified by:
internalInvokeHome in class Container (src)
Parameters:
mi - the object holding all info about this invocation
Returns:
the result of the home invocation
Throws:
java.lang.Error - Not valid for MDB
java.lang.Exception

internalInvoke

public java.lang.Object internalInvoke(Invocation (src)  mi)
                                throws java.lang.Exception
This method does invocation interpositioning of tx and security, retrieves the instance from an object table, and invokes the method on the particular instance

Specified by:
internalInvoke in class Container (src)
Throws:
java.lang.Exception

createHome

public EJBObject (src)  createHome()
                     throws java.rmi.RemoteException,
                            CreateException (src) 
Throws:
java.rmi.RemoteException
CreateException (src)

removeHome

public void removeHome(Handle (src)  handle)
                throws java.rmi.RemoteException,
                       RemoveException (src) 
Throws:
java.rmi.RemoteException
RemoveException (src)

removeHome

public void removeHome(java.lang.Object primaryKey)
                throws java.rmi.RemoteException,
                       RemoveException (src) 
Throws:
java.rmi.RemoteException
RemoveException (src)

getEJBMetaDataHome

public EJBMetaData (src)  getEJBMetaDataHome()
                               throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException

getHomeHandleHome

public HomeHandle (src)  getHomeHandleHome()
                             throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException