Fix (APAR): PK56887
Status: Fix
Release: 6.0.2.21
Operating System: AIX,HP-UX,i5/OS,Linux,Linux pSeries,Linux zSeries,OS/400,Solaris,Windows
Supersedes Fixes:
CMVC Defect: PK56887
Byte size of APAR: 26548
Date: 2007-12-07
Abstract: There is no flexibility for defining a cmpConnection factory binding for the container-managed persistence (CMP) V1.X beans present in an Enterprise Java Bean (EJB) V2.0 Module.
Description/symptom of problem:
PK56887 resolves the following problem:
ERROR DESCRIPTION:
If the ejb-jar.xml file for an EJB has a module type of
EJB 2.0,
.
and the CMP type of the bean is
1.x
.
the precedence order in the EJBContainer in WebSphere
AppServer of bindings in the ibm-ejb-jar-bnd.xmi file for CMP
1.1 EJBs in a EJB 2.0 modlue is
1. cmpConnectionFactory in the EJBBindings.
2. defaultCMPConnectionFactory
3. datasource in the EJBBindings
4. defaultDataSource
.
For an EJB 2.0 module with a CMP 1.1 EJB, there is no way
with a wsadmin command to get a cmpConnectionFactory added to
the EJBBindings in the ibm-ejb-jar-bnd.xmi file.
If you specify the tag, -DataSourceFor10CMPBeans on the wsadmin
command to modify the ejb, such as in the command,
.
"$AdminApp edit my_demo {-DataSourceFor10CMPBeans
{{Catalog-ProductManagementData Attribute
Catalog-ProductManagementData.jar,META-INF/ejb-jar.xml
jdbc/myDataSource}}}"
.
you get a datasource in the EJBBindings, such as
.
but if there is a defaultCMPConnectionFactory in the
ibm-ejb-jar-bnd.xmi file, then the jndi name specified in the
defaultCMPConnectionFactory is used by the CMP 1.1 application
versus using the specific datasource for the EJB.
.
IF you specify the tag,
-DataSourceFor10CMPBeans/-DataSourceFor20CMPBeans
wsadmin rejects this because it has parameter checks that
compares the CMP type to see if it is CMP 2.x.
WASX7111E: Cannot find a match for supplied
option: [Catalog-ProductManagementData, Attribute,
Catalog-ProductManagementData.jar,META-INF/ejb-jar.xml,
jdbc/myDataSource]; for task: DataSourceFor20CMPBeans
.
This is only a problem with the EJB 2.0 Module that contains
a CMP 1.1 bean.
LOCAL FIX:
Either comment out the defaultCMPConnectionFactory
or
modify the ibm-ejb-jar-bnd.xmi file with an editor to create the
cmpConnectionFactory.
PROBLEM SUMMARY
USERS AFFECTED:
Users of IBM Websphere Application Server
version 6.0.2 and 6.1.
PROBLEM DESCRIPTION:
There is no flexibility for defining a
cmpConnection factory binding for the
container-managed persistence (CMP)
V1.X beans present in an Enterprise
Java Bean (EJB) V2.0 Module.
RECOMMENDATION:
None
If you have an Enterprise application containing an EJB module
with Module Version of 2.0 and a CMP bean of version 1.X, while
deploying the application without bindings we always create a
datasource binding per CMP V1.x.
But there is no flexibility of defining a cmpConnection
factory binding for the CMP 1.X beans persent in an EJB 2.0
Module.
PROBLEM CONCLUSION:
Code changes have been made to ensure that cmpConnectionFactory
bindings will be genertaed for the CMP 1.X beans under EJB 2.0
Module.
The wsadmin AdminApp option "-DataSourceFor20CMPBeans"
will facilitate the above. In the Administrative Console we
are providing the same feature by listing all the CMP V1.X
beans in Module V2.0 in the Step "Map data sources for all 2.x
CMP beans" and any mappings done to the EJBs in this panel
will create cmpConnectionFactory bindings.
But if the same jndi name has been used for DataSource and
cmpConnectionFactory for a particular EJB then the
cmpConnectionFactory binding takes precedence over the
datasource.
The fix for this APAR is currently targeted for inclusion in
fixpacks 6.1.0.17. and 6.0.2.27
Please refer to the recommended updates page for delivery
information:
http://www.ibm.com/support/docview.wss?rs=180&uid=swg27004980
Directions to apply fix:
NOTE: Choose the:
1) Release the fix applies to
2) The Editions that apply
3) Delete the Editions & Methods that do not apply and this Note
Fix applies to Editions:
Release 6.0
_Y_ Application Server (Express or BASE)
_Y_ Network Deployment (ND)
__ WebSphere Business Integration Server Foundation (WBISF)
__ Edge Components
__ Developer
__ Extended Deployment (XD)
Install Fix to:
Method:
__ Application Server Nodes
__ Deployment Manager Nodes
_Y_ Both
NOTE:
The user must:
* Have Administrative rights in Windows, or be the Actual Root User in a UNIX environments.
* Logged in with the same authority level when unpacking a fix, fix pack or refresh pack.
* Be at V6.1.0.13 or newer of the Update Installer. This can be checked by reviewing the level of the Update Installer in file /updateinstaller/version.txt.
The Update Installer can be downloaded from the following link:
http://www.ibm.com/support/docview.wss?rs=180&uid=swg21205991
For detailed instructions to Extract the Update Installer see the following Technote:
http://www-1.ibm.com/support/docview.wss?rs=180&uid=swg21205400
1) Copy 6.0.2.21-WS-WAS-IFPK56887.pak file directly to the maintenance directory
2) Shutdown WebSphere
Manually execute setupCmdLine.bat in Windows or . ./setupCmdLine.sh in Unix from the WebSphere instance that maintenance is being applied to.
3) Launch Update Installer
4) Enter the installation location of the WebSphere product you want to update.
5) Select the "Install maintenance package" operation.
6) Enter the file name of the maintenance package to install (6.0.2.21-WS-WAS-IFPK56887.pak file which was copied in the maintenance directory).
7) Install the maintenance package.
8) Restart WebSphere
Directions to remove fix:
NOTE:
* The user must have Administrative rights in Windows, or be the Actual Root User in a UNIX environments.
* FIXES MUST BE REMOVED IN THE ORDER THEY WERE APPLIED
* DO NOT REMOVE A FIX UNLESS ALL FIXES APPLIED AFTER IT HAVE FIRST BEEN REMOVED
* YOU MAY REAPPLY ANY REMOVED FIX
Example: If your system has fix1, fix2, and fix3 applied in that order and fix2 is to be removed, fix3 must be removed first, fix2 removed, and fix3 re-applied.
1) Shutdown WebSphere
Manually execute setupCmdLine.bat in Windows or . ./setupCmdLine.sh in Unix from the WebSphere instance that uninstall is being run against.
2) Start Update Installer
3) Enter the installation location of the WebSphere product you want to remove the fix.
4) Select "Uninstall maintenance package" operation.
5) Enter the file name of the maintenance package to uninstall (6.0.2.21-WS-WAS-IFPK56887.pak).
6) UnInstall maintenance package.
7) Restart WebSphere
Directions to re-apply fix:
1) Shutdown WebSphere.
2) Follow the Fix instructions to apply the fix.
3) Restart WebSphere.
Additional Information: