org.glassfish.weld
Class WeldActivator
java.lang.Object
org.glassfish.weld.WeldActivator
- All Implemented Interfaces:
- org.osgi.framework.BundleActivator
public class WeldActivator
- extends java.lang.Object
- implements org.osgi.framework.BundleActivator
This is a bundle activator which is responsible for configuring Weld bundle
to be used in GlassFish. As part of configuration, it configures the the
SingletonProvider in Weld. It sets different SingletonProvider for different
profiles. e.g., in WebProfile, it sets
TCCLSingletonProvider, where as
for full-javaee profile, it uses
ACLSingletonProvider. It tests profile by testing
existence of EarClassLoader.
Since Weld 1.1, an implementation of the
ProxyServices SPI is used to provide
a classloader to load javassist defined proxies. This classloader ensures
that they can load not only application defined classes but also classes
exported by any OSGi bundle as long as the operation is happening in
the context of a Java EE app.
The bundle activator resets the SingletonProvicer in stop().
- Author:
- Sanjeeb.Sahoo@Sun.COM
|
Method Summary |
void |
start(org.osgi.framework.BundleContext context)
|
void |
stop(org.osgi.framework.BundleContext context)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
WeldActivator
public WeldActivator()
start
public void start(org.osgi.framework.BundleContext context)
throws java.lang.Exception
- Specified by:
start in interface org.osgi.framework.BundleActivator
- Throws:
java.lang.Exception
stop
public void stop(org.osgi.framework.BundleContext context)
throws java.lang.Exception
- Specified by:
stop in interface org.osgi.framework.BundleActivator
- Throws:
java.lang.Exception
Copyright © 2012 GlassFish Community. All Rights Reserved.