Package org.glassfish.ejb.startup
Class EjbApplication
- java.lang.Object
-
- org.glassfish.ejb.startup.EjbApplication
-
- All Implemented Interfaces:
ApplicationContainer<Collection<EjbDescriptor>>
@Service(name="ejb") @PerLookup public class EjbApplication extends Object implements ApplicationContainer<Collection<EjbDescriptor>>
This class represents a logical collection of EJB components contained in one ejb-jar or one .war.- Author:
- Mahesh Kannan
-
-
Constructor Summary
Constructors Constructor Description EjbApplication(EjbBundleDescriptorImpl bundle, DeploymentContext dc, ClassLoader cl, org.glassfish.hk2.api.ServiceLocator services)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ClassLoader
getClassLoader()
Returns the class loader associated with this applicationCollection<EjbDescriptor>
getDescriptor()
Returns the deployment descriptor associated with this applicationEjbBundleDescriptorImpl
getEjbBundleDescriptor()
void
initialize()
Initialize the container post-startup of Hazelcast Used for EJB timers right nowboolean
isStarted()
boolean
resume()
Resumes this application container.boolean
start(ApplicationContext startupContext)
Starts an application container.boolean
stop(ApplicationContext stopContext)
boolean
suspend()
Suspends this application container.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.glassfish.api.deployment.ApplicationContainer
reload
-
-
-
-
Constructor Detail
-
EjbApplication
public EjbApplication(EjbBundleDescriptorImpl bundle, DeploymentContext dc, ClassLoader cl, org.glassfish.hk2.api.ServiceLocator services)
-
-
Method Detail
-
getDescriptor
public Collection<EjbDescriptor> getDescriptor()
Description copied from interface:ApplicationContainer
Returns the deployment descriptor associated with this application- Specified by:
getDescriptor
in interfaceApplicationContainer<Collection<EjbDescriptor>>
- Returns:
- deployment descriptor if they exist or null if not
-
getEjbBundleDescriptor
public EjbBundleDescriptorImpl getEjbBundleDescriptor()
-
isStarted
public boolean isStarted()
-
start
public boolean start(ApplicationContext startupContext) throws Exception
Description copied from interface:ApplicationContainer
Starts an application container. ContractProvider starting should not throw an exception but rather should use their prefered Logger instance to log any issue they encounter while starting. Returning false from a start mean that the container failed to start- Specified by:
start
in interfaceApplicationContainer<Collection<EjbDescriptor>>
- Parameters:
startupContext
- the start up context- Returns:
- true if the container startup was successful.
- Throws:
Exception
- if this application container could not be started
-
initialize
public void initialize()
Description copied from interface:ApplicationContainer
Initialize the container post-startup of Hazelcast Used for EJB timers right now- Specified by:
initialize
in interfaceApplicationContainer<Collection<EjbDescriptor>>
-
stop
public boolean stop(ApplicationContext stopContext)
- Specified by:
stop
in interfaceApplicationContainer<Collection<EjbDescriptor>>
-
suspend
public boolean suspend()
Suspends this application container.- Specified by:
suspend
in interfaceApplicationContainer<Collection<EjbDescriptor>>
- Returns:
- true if suspending was successful, false otherwise.
-
resume
public boolean resume()
Resumes this application container.- Specified by:
resume
in interfaceApplicationContainer<Collection<EjbDescriptor>>
- Returns:
- true if resumption was successful, false otherwise.
-
getClassLoader
public ClassLoader getClassLoader()
Returns the class loader associated with this application- Specified by:
getClassLoader
in interfaceApplicationContainer<Collection<EjbDescriptor>>
- Returns:
- ClassLoader for this app
-
-