Bug 399148 - DBWS: server test - LegacySimpleTableServiceTestSuite failed on JBoss
Summary: DBWS: server test - LegacySimpleTableServiceTestSuite failed on JBoss
Status: CLOSED WONTFIX
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Eclipselink (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Edwin Tang CLA
QA Contact:
URL:
Whiteboard:
Keywords: test
Depends on:
Blocks:
 
Reported: 2013-01-25 21:29 EST by Edwin Tang CLA
Modified: 2022-06-09 10:05 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Edwin Tang CLA 2013-01-25 21:29:19 EST
The new DBWS server test - LegacySimpleTableServiceTestSuite failed on all app servers

Stack Trace:
============
Service test failed: SOAPMessage request format error - java.lang.NullPointerException

junit.framework.AssertionFailedError: Service test failed: SOAPMessage request format error - java.lang.NullPointerException
at dbws.testing.legacysimpletable.LegacySimpleTableServiceTestSuite.testService(LegacySimpleTableServiceTestSuite.java:287)
Comment 1 David McCann CLA 2013-01-28 10:56:44 EST
This test works fine in my local environment.  I am thinking that the datasource name is incorrect.  The checked in .war assumes "jdbc/DBWStestDS", but as I recall, the QA environment uses a different datasource name.  Please provide the correct name and I'll update the .war file accordingly.
Comment 2 David McCann CLA 2013-01-28 13:50:29 EST
The QA environment uses "jdbc/EclipseLinkDS" for all application servers except JBoss, which uses "java:/EclipseLinkDS".

Phase one will involve changing the DS name in the eclipselink-dbws-sessions.xml file in the checked in .war file.  Assuming this resolves the issue on all application servers except JBoss, phase two will involve either checking in a second .war file to be used on JBoss, or perhaps using a script to update the sessions file for the JBoss case prior to deployment.
Comment 3 David McCann CLA 2013-01-28 13:57:07 EST
Fir for phase#1 checked into EclipseLink 2.5.0, revision: 8e3c40a61fbc57d4f4e3d0bb6b057de279c8f93e
Comment 4 Edwin Tang CLA 2013-02-13 12:10:52 EST
With the phase#1 fix, the test passed on all versions of WebLogic server, but failed on WebSphere, GlassFish and JBoss with different error messages.

 
Exception with WebSphere:
=========================
Service test failed: Internal Error

junit.framework.AssertionFailedError: Service test failed: Internal Error
at dbws.testing.legacysimpletable.LegacySimpleTableServiceTestSuite.testService(LegacySimpleTableServiceTestSuite.java:287)


Exception with GlassFish:
=========================
Service test failed: com.sun.enterprise.container.common.spi.util.InjectionException: Error creating managed object for class: class _dbws.DBWSProvider

junit.framework.AssertionFailedError: Service test failed: com.sun.enterprise.container.common.spi.util.InjectionException: Error creating managed object for class: class _dbws.DBWSProvider
at dbws.testing.legacysimpletable.LegacySimpleTableServiceTestSuite.testService(LegacySimpleTableServiceTestSuite.java:287)


Exception with JBoss:
=====================
Service test failed: Calling of @PostConstruct annotated method failed: public void _dbws.DBWSProvider.init()

junit.framework.AssertionFailedError: Service test failed: Calling of @PostConstruct annotated method failed: public void _dbws.DBWSProvider.init()
at dbws.testing.legacysimpletable.LegacySimpleTableServiceTestSuite.testService(LegacySimpleTableServiceTestSuite.java:287)
Comment 5 Edwin Tang CLA 2013-02-19 10:57:05 EST
I looked into the eclipselink-dbws-sessions.xml in the .war file, not only the <datasource>, but <server-class> are defined there. 
         <server-class>org.eclipse.persistence.platform.server.wls.WebLogic_10_Platform</server-class>

That is why the .war can be deployed successfully on WebLogic servers only. It is not good idea to check in multiple versions of .war files, I can unpack and re-pack the .war file to include server-specific info in my nightly testing script.
Comment 6 Edwin Tang CLA 2013-02-25 10:30:19 EST
Cause: In the checked-in .war file, ecclipselink-dbws-sessions.xml contains server-specific attributes <datasource>, <server-class> and <external-transaction-controller-class>
Solution: In our nightly testing scripts, repackage the .war file to include the server-specific info
Result: It still failed on JBoss - Investigating
Comment 7 David McCann CLA 2013-07-05 11:17:54 EDT
I'm thinking that we don't really need to run the legacy tests on any server except WebLogic.  The test just ensures that we can successfully read in the legacy deployment XML projects (as opposed to the new JPA/JAXB metadata format) for backwards compatibility.  The application server should't affect reading in the project files, so I'd think we are OK with just testing on WLS.

I vote to close this bug as WON'T FIX or INVALID.
Comment 8 Eclipse Webmaster CLA 2022-06-09 10:05:12 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink