/** * Create an instance of the embedded container * @param fullProfile Should a full JCA 1.6 profile be used * @return The instance */ public static Embedded create(boolean fullProfile) { return new EmbeddedJCA(fullProfile); } }
/** * Create an instance of the embedded container * with a certified configuration * @return The instance */ public static Embedded create() { return create(true); }
/** * Event * @param kernel The kernel * @param event The event */ public void event(Kernel kernel, Event event) { if (event == Event.PRE_CLASSLOADER) { SecurityActions.setSystemProperty("xb.builder.useUnorderedSequence", "true"); SecurityActions.setSystemProperty("java.util.logging.manager", "org.jboss.logmanager.LogManager"); SecurityActions.setSystemProperty("log4j.defaultInitOverride", "true"); } } }
/** * {@inheritDoc} * @see org.jboss.arquillian.spi.DeployableContainer#start */ @Override public void start() throws LifecycleException { embedded = EmbeddedFactory.create(true); try { embedded.startup(); contextProducer.set(createContext()); embeddedProducer.set(embedded); } catch (Throwable t) { throw new LifecycleException("Could not start the EmbeddedJCA container: " + t.getMessage(), t); } }
/** * {@inheritDoc} * @see org.jboss.arquillian.spi.DeployableContainer#start */ @Override public void start() throws LifecycleException { embedded = EmbeddedFactory.create(true); try { embedded.startup(); contextProducer.set(createContext()); embeddedProducer.set(embedded); } catch (Throwable t) { throw new LifecycleException("Could not start the IronJacamar container: " + t.getMessage(), t); } }
/** * {@inheritDoc} * @see org.jboss.arquillian.spi.DeployableContainer#stop */ @Override public void stop() throws LifecycleException { try { embedded.shutdown(); } catch (Throwable t) { throw new LifecycleException("Could not stop the IronJacamar container: " + t.getMessage(), t); } embedded = null; }
/** * {@inheritDoc} * @see DeployableContainer#undeploy(Descriptor) */ @Override public void undeploy(Descriptor descriptor) throws DeploymentException { if (descriptor == null) throw new DeploymentException("Could not undeploy a null application"); try { embedded.undeploy(descriptor); } catch (Throwable t) { throw new DeploymentException("Could not undeploy the application: " + t.getMessage(), t); } }
/** * Set auto activate * @param v The value */ void setAutoActivate(boolean v) { try { RAActivator activator = embedded.lookup("RAActivator", RAActivator.class); if (activator != null) { activator.setEnabled(v); } } catch (Throwable t) { // Nothing } }
/** * {@inheritDoc} * @see DeployableContainer#deploy(Descriptor) */ @Override public void deploy(Descriptor descriptor) throws DeploymentException { if (descriptor == null) throw new DeploymentException("Could not deploy a null descriptor"); try { embedded.deploy(descriptor); } catch (Throwable t) { throw new DeploymentException("Could not deploy the application: " + t.getMessage(), t); } }
/** * {@inheritDoc} * @see org.jboss.arquillian.spi.DeployableContainer#start */ @Override public void start() throws LifecycleException { embedded = EmbeddedFactory.create(true); try { embedded.startup(); contextProducer.set(createContext()); embeddedProducer.set(embedded); } catch (Throwable t) { throw new LifecycleException("Could not start the IronJacamar container: " + t.getMessage(), t); } }
/** * Create an instance of the embedded container * with a certified configuration * @return The instance */ public static Embedded create() { return create(true); }
/** * {@inheritDoc} * @see org.jboss.arquillian.spi.DeployableContainer#stop */ @Override public void stop() throws LifecycleException { try { embedded.shutdown(); } catch (Throwable t) { throw new LifecycleException("Could not stop the IronJacamar container: " + t.getMessage(), t); } embedded = null; }
/** * {@inheritDoc} * @see DeployableContainer#undeploy(Descriptor) */ @Override public void undeploy(Descriptor descriptor) throws DeploymentException { if (descriptor == null) throw new DeploymentException("Could not undeploy a null application"); try { embedded.undeploy(descriptor); } catch (Throwable t) { throw new DeploymentException("Could not undeploy the application: " + t.getMessage(), t); } }
/** * Set auto activate * @param v The value */ void setAutoActivate(boolean v) { try { RAActivator activator = embedded.lookup("RAActivator", RAActivator.class); if (activator != null) { activator.setEnabled(v); } } catch (Throwable t) { // Nothing } }
/** * {@inheritDoc} * @see DeployableContainer#deploy(Descriptor) */ @Override public void deploy(Descriptor descriptor) throws DeploymentException { if (descriptor == null) throw new DeploymentException("Could not deploy a null descriptor"); try { embedded.deploy(descriptor); } catch (Throwable t) { throw new DeploymentException("Could not deploy the application: " + t.getMessage(), t); } }
/** * Create an instance of the embedded container * @param fullProfile Should a full JCA 1.6 profile be used * @return The instance */ public static Embedded create(boolean fullProfile) { return new EmbeddedJCA(fullProfile); } }
/** * Event * @param kernel The kernel * @param event The event */ public void event(Kernel kernel, Event event) { if (event == Event.PRE_CLASSLOADER) { SecurityActions.setSystemProperty("xb.builder.useUnorderedSequence", "true"); SecurityActions.setSystemProperty("java.util.logging.manager", "org.jboss.logmanager.LogManager"); SecurityActions.setSystemProperty("log4j.defaultInitOverride", "true"); } } }
/** * {@inheritDoc} * @see org.jboss.arquillian.spi.DeployableContainer#stop */ @Override public void stop() throws LifecycleException { try { embedded.shutdown(); } catch (Throwable t) { throw new LifecycleException("Could not stop the EmbeddedJCA container: " + t.getMessage(), t); } embedded = null; }
/** * {@inheritDoc} * @see DeployableContainer#undeploy(Descriptor) */ @Override public void undeploy(Descriptor descriptor) throws DeploymentException { if (descriptor == null) throw new DeploymentException("Could not undeploy a null application"); try { embedded.undeploy(descriptor); } catch (Throwable t) { throw new DeploymentException("Could not undeploy the application: " + t.getMessage(), t); } }