Test failed after Glassfish warning
pedrokowalski Sep 19, 2011 6:03 PMHowdy!
Got small problem. The Arquillian controlled JUnit test is failing because of Glassfish warning. I'm not sure if warning should stop the test from running. What I see in GF3.1 logs:
[#|2011-09-19T23:52:34.053+0200|WARNING|glassfish3.1.1|org.eclipse.persistence.session.file:/home/pedro/glassfish3/glassfish/domains/domain1/applications/test/WEB-INF/classes/_edip.server|_ThreadID=18;_ThreadName=admin-thread-pool-4848(2);|Multiple [2] JMX MBeanServer instances exist, we will use the server at index [0] : [com.sun.enterprise.v3.admin.DynamicInterceptor@1696e4c].|#]
[#|2011-09-19T23:52:34.054+0200|WARNING|glassfish3.1.1|org.eclipse.persistence.session.file:/home/pedro/glassfish3/glassfish/domains/domain1/applications/test/WEB-INF/classes/_edip.server|_ThreadID=18;_ThreadName=admin-thread-pool-4848(2);|JMX MBeanServer in use: [com.sun.enterprise.v3.admin.DynamicInterceptor@1696e4c] from index [0] |#]
[#|2011-09-19T23:52:34.054+0200|WARNING|glassfish3.1.1|org.eclipse.persistence.session.file:/home/pedro/glassfish3/glassfish/domains/domain1/applications/test/WEB-INF/classes/_edip.server|_ThreadID=18;_ThreadName=admin-thread-pool-4848(2);|JMX MBeanServer in use: [com.sun.jmx.mbeanserver.JmxMBeanServer@159be0d] from index [1] |#]
[#|2011-09-19T23:52:35.182+0200|WARNING|glassfish3.1.1|javax.org.glassfish.persistence.org.glassfish.persistence.common|_ThreadID=18;_ThreadName=admin-thread-pool-4848(2);|PER01000: Got SQLException executing statement "CREATE TABLE SEQUENCE (SEQ_NAME VARCHAR(50) NOT NULL, SEQ_COUNT DECIMAL(15), PRIMARY KEY (SEQ_NAME))": java.sql.SQLException: Table/View 'SEQUENCE' already exists in Schema 'APP'.|#]
Arquillian in JUnit console shows:
org.jboss.arquillian.container.spi.client.container.DeploymentException: "http://localhost:4848/management/domain/applications/application/test" created successfully.
PER01003: Deployment encountered SQL Exceptions:
PER01000: Got SQLException executing statement "CREATE TABLE SEQUENCE (SEQ_NAME VARCHAR(50) NOT NULL, SEQ_COUNT DECIMAL(15), PRIMARY KEY (SEQ_NAME))": java.sql.SQLException: Table/View 'SEQUENCE' already exists in Schema 'APP'.
at org.jboss.arquillian.container.glassfish.remote_3_1.GlassFishRestDeployableContainer.deploy(GlassFishRestDeployableContainer.java:154)
at org.jboss.arquillian.container.impl.client.container.ContainerDeployController$3.call(ContainerDeployController.java:148)
at org.jboss.arquillian.container.impl.client.container.ContainerDeployController$3.call(ContainerDeployController.java:115)
at org.jboss.arquillian.container.impl.client.container.ContainerDeployController.executeOperation(ContainerDeployController.java:246)
at org.jboss.arquillian.container.impl.client.container.ContainerDeployController.deploy(ContainerDeployController.java:114)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
[...]
So, there is an SQLException, but the deployment was fine and the exception is treated just as a warning. Consider also this: http://java.net/projects/glassfish/lists/persistence/archive/2006-11/message/221
"You can ignore this warning."
What do you think about that?
Cheers!