[jboss-cvs] JBossAS SVN: r104640 - in branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964: component-matrix and 2 other directories.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Mon May 10 18:50:53 EDT 2010
Author: ALRubinger
Date: 2010-05-10 18:50:52 -0400 (Mon, 10 May 2010)
New Revision: 104640
Modified:
branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/build/build.xml
branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/component-matrix/pom.xml
branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/depchain/pom.xml
branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/embedded/src/test/java/org/jboss/jbossas/embedded/testsuite/ServerIntegrationTest.java
Log:
[JBAS-7964] Integrate ShrinkWrapDeployer; EJB3 Embeddable test now failing from mcann where it tries to read in archives as GZIP and gets EOF.
Modified: branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/build/build.xml
===================================================================
--- branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/build/build.xml 2010-05-10 22:46:43 UTC (rev 104639)
+++ branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/build/build.xml 2010-05-10 22:50:52 UTC (rev 104640)
@@ -700,6 +700,7 @@
<include name="ejb3-connectors-jboss-beans.xml"/>
</fileset>
<fileset refid="org.jboss.ejb3.embedded:jboss-ejb3-embedded-impl-as:jar"/>
+ <fileset refid="org.jboss.shrinkwrap:shrinkwrap-extension-vdf:jar" />
<fileset dir="${ejb3.module.output}/resources/META-INF">
<include name="singleton-container-aop.xml"/>
</fileset>
@@ -2031,6 +2032,7 @@
<fileset refid="org.jboss.shrinkwrap:shrinkwrap-api:jar" />
<fileset refid="org.jboss.shrinkwrap:shrinkwrap-impl-base:jar" />
<fileset refid="org.jboss.shrinkwrap:shrinkwrap-spi:jar" />
+ <fileset refid="org.jboss.shrinkwrap:shrinkwrap-extension-vfs3:jar" />
<fileset refid="org.hibernate:hibernate-core:jar"/>
<fileset refid="org.hibernate:hibernate-commons-annotations:jar"/>
<fileset refid="org.hibernate:hibernate-entitymanager:jar"/>
Modified: branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/component-matrix/pom.xml
===================================================================
--- branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/component-matrix/pom.xml 2010-05-10 22:46:43 UTC (rev 104639)
+++ branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/component-matrix/pom.xml 2010-05-10 22:50:52 UTC (rev 104640)
@@ -137,7 +137,7 @@
<version.org.jboss.security>3.0.0.Beta4</version.org.jboss.security>
<version.org.jboss.security.negotiation>2.0.3.SP1</version.org.jboss.security.negotiation>
<version.org.jboss.service.binding>1.1.0.CR1</version.org.jboss.service.binding>
- <version.org.jboss.shrinkwrap>1.0.0-alpha-9</version.org.jboss.shrinkwrap>
+ <version.org.jboss.shrinkwrap>1.0.0-SNAPSHOT</version.org.jboss.shrinkwrap>
<version.org.jboss.slf4j>1.0.2.GA</version.org.jboss.slf4j>
<version.org.jboss.stdio>1.0.0.CR3</version.org.jboss.stdio>
<version.org.jboss.threads>2.0.0.CR4</version.org.jboss.threads>
@@ -2943,6 +2943,16 @@
<artifactId>shrinkwrap-impl-base</artifactId>
<version>${version.org.jboss.shrinkwrap}</version>
</dependency>
+ <dependency>
+ <groupId>org.jboss.shrinkwrap</groupId>
+ <artifactId>shrinkwrap-extension-vdf</artifactId>
+ <version>${version.org.jboss.shrinkwrap}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.shrinkwrap</groupId>
+ <artifactId>shrinkwrap-extension-vfs3</artifactId>
+ <version>${version.org.jboss.shrinkwrap}</version>
+ </dependency>
<dependency>
<groupId>org.jboss.osgi</groupId>
Modified: branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/depchain/pom.xml
===================================================================
--- branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/depchain/pom.xml 2010-05-10 22:46:43 UTC (rev 104639)
+++ branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/depchain/pom.xml 2010-05-10 22:50:52 UTC (rev 104640)
@@ -826,13 +826,40 @@
<dependency>
<groupId>org.jboss.shrinkwrap</groupId>
<artifactId>shrinkwrap-spi</artifactId>
- <version>${version.org.jboss.shrinkwrap}</version>
</dependency>
<dependency>
<groupId>org.jboss.shrinkwrap</groupId>
<artifactId>shrinkwrap-impl-base</artifactId>
</dependency>
<dependency>
+ <groupId>org.jboss.shrinkwrap</groupId>
+ <artifactId>shrinkwrap-extension-vdf</artifactId>
+ <exclusions>
+ <exclusion>
+ <groupId>org.jboss.logging</groupId>
+ <artifactId>jboss-logging-spi</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.jboss.logging</groupId>
+ <artifactId>jboss-logging-log4j</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.shrinkwrap</groupId>
+ <artifactId>shrinkwrap-extension-vfs3</artifactId>
+ <exclusions>
+ <exclusion>
+ <groupId>org.jboss.logging</groupId>
+ <artifactId>jboss-logging-spi</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.jboss.logging</groupId>
+ <artifactId>jboss-logging-log4j</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
<groupId>org.jboss.slf4j</groupId>
<artifactId>slf4j-jboss-logging</artifactId>
</dependency>
Modified: branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/embedded/src/test/java/org/jboss/jbossas/embedded/testsuite/ServerIntegrationTest.java
===================================================================
--- branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/embedded/src/test/java/org/jboss/jbossas/embedded/testsuite/ServerIntegrationTest.java 2010-05-10 22:46:43 UTC (rev 104639)
+++ branches/TEMP_EJB3_EMBEDDABLE_JBAS-7964/embedded/src/test/java/org/jboss/jbossas/embedded/testsuite/ServerIntegrationTest.java 2010-05-10 22:50:52 UTC (rev 104640)
@@ -271,14 +271,19 @@
server.deploy(archive);
// Test
- final OutputLocalBusiness bean = (OutputLocalBusiness) NAMING_CONTEXT.lookup(OutputBean.class.getSimpleName()
- + JNDI_SUFFIX_LOCAL_BUSINESS);;
- final String output = bean.getOutput();
- log.info("Got output: " + output);
- Assert.assertEquals(OutputLocalBusiness.OUTPUT, output);
+ try
+ {
+ final OutputLocalBusiness bean = (OutputLocalBusiness) NAMING_CONTEXT.lookup(OutputLocalBusiness.JNDI_NAME);
+ final String output = bean.getOutput();
+ log.info("Got output: " + output);
- // Undeploy
- server.undeploy(archive);
+ Assert.assertEquals(OutputLocalBusiness.OUTPUT, output);
+ }
+ finally
+ {
+ // Undeploy
+ server.undeploy(archive);
+ }
}
@@ -310,35 +315,40 @@
// Deploy
server.deploy(archive);
- // Get an HTTP Client
- final HttpClient client = new DefaultHttpClient();
+ try
+ {
+ // Get an HTTP Client
+ final HttpClient client = new DefaultHttpClient();
- // Make an HTTP Request
- final String echoValue = "EmbeddedBiatch";
- final List<NameValuePair> params = new ArrayList<NameValuePair>();
- params.add(new BasicNameValuePair("jsp", PATH_JSP));
- params.add(new BasicNameValuePair("echo", echoValue));
- final URI uri = URIUtils.createURI("http", "localhost", 8080, appName + SEPARATOR + servletClass.getSimpleName(),
- URLEncodedUtils.format(params, "UTF-8"), null);
- final HttpGet request = new HttpGet(uri);
+ // Make an HTTP Request
+ final String echoValue = "EmbeddedBiatch";
+ final List<NameValuePair> params = new ArrayList<NameValuePair>();
+ params.add(new BasicNameValuePair("jsp", PATH_JSP));
+ params.add(new BasicNameValuePair("echo", echoValue));
+ final URI uri = URIUtils.createURI("http", "localhost", 8080, appName + SEPARATOR
+ + servletClass.getSimpleName(), URLEncodedUtils.format(params, "UTF-8"), null);
+ final HttpGet request = new HttpGet(uri);
- // Execute the request
- log.info("Executing request to: " + request.getURI());
- final HttpResponse response = client.execute(request);
- final HttpEntity entity = response.getEntity();
- if (entity == null)
+ // Execute the request
+ log.info("Executing request to: " + request.getURI());
+ final HttpResponse response = client.execute(request);
+ final HttpEntity entity = response.getEntity();
+ if (entity == null)
+ {
+ TestCase.fail("Request returned no entity");
+ }
+
+ // Read the result, ensure it's what we're expecting (should be the value of request param "echo")
+ final BufferedReader reader = new BufferedReader(new InputStreamReader(entity.getContent()));
+ final String line = reader.readLine();
+ log.info("Got response: " + line);
+ Assert.assertEquals(echoValue, line);
+ }
+ finally
{
- TestCase.fail("Request returned no entity");
+ // Undeploy
+ server.undeploy(archive);
}
-
- // Read the result, ensure it's what we're expecting (should be the value of request param "echo")
- final BufferedReader reader = new BufferedReader(new InputStreamReader(entity.getContent()));
- final String line = reader.readLine();
- log.info("Got response: " + line);
- Assert.assertEquals(echoValue, line);
-
- // Undeploy
- server.undeploy(archive);
}
/**
@@ -366,31 +376,36 @@
// Deploy
server.deploy(archive);
- // Get an HTTP Client
- final HttpClient client = new DefaultHttpClient();
+ try
+ {
+ // Get an HTTP Client
+ final HttpClient client = new DefaultHttpClient();
- // Make an HTTP Request
- final URI uri = URIUtils.createURI("http", "localhost", 8080, appName + SEPARATOR + servletClass.getSimpleName(),
- null, null);
- final HttpGet request = new HttpGet(uri);
+ // Make an HTTP Request
+ final URI uri = URIUtils.createURI("http", "localhost", 8080, appName + SEPARATOR
+ + servletClass.getSimpleName(), null, null);
+ final HttpGet request = new HttpGet(uri);
- // Execute the request
- log.info("Executing request to: " + request.getURI());
- final HttpResponse response = client.execute(request);
- final HttpEntity entity = response.getEntity();
- if (entity == null)
+ // Execute the request
+ log.info("Executing request to: " + request.getURI());
+ final HttpResponse response = client.execute(request);
+ final HttpEntity entity = response.getEntity();
+ if (entity == null)
+ {
+ TestCase.fail("Request returned no entity");
+ }
+
+ // Read the result, ensure it's what we're expecting
+ final BufferedReader reader = new BufferedReader(new InputStreamReader(entity.getContent()));
+ final String line = reader.readLine();
+ log.info("Got response: " + line);
+ Assert.assertEquals(OutputLocalBusiness.JNDI_NAME, line);
+ }
+ finally
{
- TestCase.fail("Request returned no entity");
+ // Undeploy
+ server.undeploy(archive);
}
-
- // Read the result, ensure it's what we're expecting
- final BufferedReader reader = new BufferedReader(new InputStreamReader(entity.getContent()));
- final String line = reader.readLine();
- log.info("Got response: " + line);
- Assert.assertEquals(OutputLocalBusiness.JNDI_NAME, line);
-
- // Undeploy
- server.undeploy(archive);
}
/**
@@ -417,38 +432,43 @@
log.info(archive.toString(true));
server.deploy(archive);
- // Define a String message to send
- final String message = "From in-JVM Test Message";
+ try
+ {
+ // Define a String message to send
+ final String message = "From in-JVM Test Message";
- // Send the message
- this.sendTextMessageToQueue(message, MessageStoringMdb.NAME_QUEUE);
+ // Send the message
+ this.sendTextMessageToQueue(message, MessageStoringMdb.NAME_QUEUE);
- // Wait on the MDB to process
- try
- {
- MessageStoringMdb.BARRIER.await(10, TimeUnit.SECONDS);
+ // Wait on the MDB to process
+ try
+ {
+ MessageStoringMdb.BARRIER.await(10, TimeUnit.SECONDS);
+ }
+ catch (final InterruptedException e)
+ {
+ // Clear the flag
+ Thread.interrupted();
+ // Throw up
+ throw e;
+ }
+ catch (final TimeoutException e)
+ {
+ TestCase.fail("The MDB did not process the message in the allotted time");
+ }
+
+ // Get the contents of the String from the MDB
+ final String received = MessageStoringMdb.LAST_MESSAGE_CONTENTS;
+
+ // Ensure equal
+ Assert.assertEquals("The test message received was not as expected", message, received);
}
- catch (final InterruptedException e)
+ finally
{
- // Clear the flag
- Thread.interrupted();
- // Throw up
- throw e;
+ // Undeploy
+ server.undeploy(archive);
}
- catch (final TimeoutException e)
- {
- TestCase.fail("The MDB did not process the message in the allotted time");
- }
- // Get the contents of the String from the MDB
- final String received = MessageStoringMdb.LAST_MESSAGE_CONTENTS;
-
- // Ensure equal
- Assert.assertEquals("The test message received was not as expected", message, received);
-
- // Undeploy
- server.undeploy(archive);
-
}
/**
@@ -478,35 +498,40 @@
log.info(archive.toString(true));
server.deploy(archive);
- // Make some JBossians
- final Jbossian jgreene = new Jbossian("Jason T. Greene", "AS Hole", 12);
- final Jbossian jpederse = new Jbossian("Jesper Pedersen", "Professional Tattletale", 21);
- final Jbossian dmlloyd = new Jbossian("David M. Lloyd", "???????", 15);
- final Jbossian wolfc = new Jbossian("Carlo de Wolf", "Superlead", 13);
- final Jbossian alr = new Jbossian("Andew Lee Rubinger", "The New Fluery", 58);
- final Jbossian asaldhan = new Jbossian("Anil Saldhana", "Karma Police", 23);
+ try
+ {
+ // Make some JBossians
+ final Jbossian jgreene = new Jbossian("Jason T. Greene", "AS Hole", 12);
+ final Jbossian jpederse = new Jbossian("Jesper Pedersen", "Professional Tattletale", 21);
+ final Jbossian dmlloyd = new Jbossian("David M. Lloyd", "???????", 15);
+ final Jbossian wolfc = new Jbossian("Carlo de Wolf", "Superlead", 13);
+ final Jbossian alr = new Jbossian("Andew Lee Rubinger", "The New Fluery", 58);
+ final Jbossian asaldhan = new Jbossian("Anil Saldhana", "Karma Police", 23);
- // Get an SLSB to interact w/ the DB
- final JbossianRegistrarLocalBusiness slsb = (JbossianRegistrarLocalBusiness) NAMING_CONTEXT
- .lookup(JbossianRegistrarBean.class.getSimpleName() + JNDI_SUFFIX_LOCAL_BUSINESS);
+ // Get an SLSB to interact w/ the DB
+ final JbossianRegistrarLocalBusiness slsb = (JbossianRegistrarLocalBusiness) NAMING_CONTEXT
+ .lookup(JbossianRegistrarBean.class.getSimpleName() + JNDI_SUFFIX_LOCAL_BUSINESS);
- // Add the JBossians
- slsb.add(jgreene);
- slsb.add(jpederse);
- slsb.add(dmlloyd);
- slsb.add(wolfc);
- slsb.add(alr);
- slsb.add(asaldhan);
+ // Add the JBossians
+ slsb.add(jgreene);
+ slsb.add(jpederse);
+ slsb.add(dmlloyd);
+ slsb.add(wolfc);
+ slsb.add(alr);
+ slsb.add(asaldhan);
- // Get all
- final Collection<Jbossian> jbossians = slsb.getAllJbossians();
- log.info("Got all JBossians: " + jbossians);
+ // Get all
+ final Collection<Jbossian> jbossians = slsb.getAllJbossians();
+ log.info("Got all JBossians: " + jbossians);
- // Test
- Assert.assertEquals(6, jbossians.size());
-
- // Undeploy
- server.undeploy(archive);
+ // Test
+ Assert.assertEquals(6, jbossians.size());
+ }
+ finally
+ {
+ // Undeploy
+ server.undeploy(archive);
+ }
}
/**
@@ -530,18 +555,22 @@
// Deploy
log.info(archive.toString(true));
server.deploy(archive);
-
- // consume the webservice
- org.jboss.jbossas.embedded.testsuite.wsclient.Embedded embeddedService = new org.jboss.jbossas.embedded.testsuite.wsclient.Embedded();
- log.info("Create Web Service client...");
- org.jboss.jbossas.embedded.testsuite.wsclient.EmbeddedWs port = embeddedService.getEmbeddedWsPort();
- log.info("Call Web Service Operation...");
- String wsResponse = port.hello("jboss embedded user");
- log.info("Web service response: " + wsResponse);
- Assert.assertEquals(WS_RESPONSE, wsResponse);
-
- // Undeploy
- server.undeploy(archive);
+ try
+ {
+ // consume the webservice
+ org.jboss.jbossas.embedded.testsuite.wsclient.Embedded embeddedService = new org.jboss.jbossas.embedded.testsuite.wsclient.Embedded();
+ log.info("Create Web Service client...");
+ org.jboss.jbossas.embedded.testsuite.wsclient.EmbeddedWs port = embeddedService.getEmbeddedWsPort();
+ log.info("Call Web Service Operation...");
+ String wsResponse = port.hello("jboss embedded user");
+ log.info("Web service response: " + wsResponse);
+ Assert.assertEquals(WS_RESPONSE, wsResponse);
+ }
+ finally
+ {
+ // Undeploy
+ server.undeploy(archive);
+ }
}
/**
@@ -558,21 +587,28 @@
// Deploy it
server.deploy(url);
- // Lookup the bean
- final String context = MC_NAME_STATEREPORTING_BEAN;
- final StateReportingBean bean = (StateReportingBean) ((MCBasedServer<?, ?>) server).getKernel().getController()
- .getInstalledContext(context).getTarget();
- TestCase.assertNotNull("Bean was not found installed in expected context: " + context, bean);
+ StateReportingBean bean = null;
+ try
+ {
+ // Lookup the bean
+ final String context = MC_NAME_STATEREPORTING_BEAN;
+ bean = (StateReportingBean) ((MCBasedServer<?, ?>) server).getKernel().getController().getInstalledContext(
+ context).getTarget();
+ TestCase.assertNotNull("Bean was not found installed in expected context: " + context, bean);
- // Ensure started
- TestCase.assertEquals("Bean should be started after installation", StateReportingBean.State.STARTED, bean
- .getState());
+ // Ensure started
+ TestCase.assertEquals("Bean should be started after installation", StateReportingBean.State.STARTED, bean
+ .getState());
+ }
+ finally
+ {
+ // Undeploy
+ server.undeploy(url);
- // Undeploy
- server.undeploy(url);
-
- // Ensure stopped
- TestCase.assertEquals("Bean should be stopped after undeploy", StateReportingBean.State.STOPPED, bean.getState());
+ // Ensure stopped
+ TestCase.assertEquals("Bean should be stopped after undeploy", StateReportingBean.State.STOPPED, bean
+ .getState());
+ }
}
/**
@@ -589,21 +625,28 @@
// Deploy it
server.deploy(file);
- // Lookup the bean
- final String context = MC_NAME_STATEREPORTING_BEAN;
- final StateReportingBean bean = (StateReportingBean) ((MCBasedServer<?, ?>) server).getKernel().getController()
- .getInstalledContext(context).getTarget();
- TestCase.assertNotNull("Bean was not found installed in expected context: " + context, bean);
+ StateReportingBean bean = null;
+ try
+ {
+ // Lookup the bean
+ final String context = MC_NAME_STATEREPORTING_BEAN;
+ bean = (StateReportingBean) ((MCBasedServer<?, ?>) server).getKernel().getController().getInstalledContext(
+ context).getTarget();
+ TestCase.assertNotNull("Bean was not found installed in expected context: " + context, bean);
- // Ensure started
- TestCase.assertEquals("Bean should be started after installation", StateReportingBean.State.STARTED, bean
- .getState());
+ // Ensure started
+ TestCase.assertEquals("Bean should be started after installation", StateReportingBean.State.STARTED, bean
+ .getState());
+ }
+ finally
+ {
+ // Undeploy
+ server.undeploy(file);
- // Undeploy
- server.undeploy(file);
-
- // Ensure stopped
- TestCase.assertEquals("Bean should be stopped after undeploy", StateReportingBean.State.STOPPED, bean.getState());
+ // Ensure stopped
+ TestCase.assertEquals("Bean should be stopped after undeploy", StateReportingBean.State.STOPPED, bean
+ .getState());
+ }
}
//-------------------------------------------------------------------------------------||
More information about the jboss-cvs-commits
mailing list