Monday, November 8, 2010

Spring v3.0.2 Learning Note 16 (Cont.)- Resolve NullPointerException on weblogic v10.3

In this article http://wangxiangblog.blogspot.com/2010/10/spring-v302-learning-note-16-integrate.html, I mentioned that NullPointerException occured if deployed hessian project to weblogic v10.3

After seach oracle website, found the info as follows
---------------------------------------------------------------------------------------------------
After some research on the stack trace, I found the reason for this error is Hession Spring servlet closes the input stream explicitly. While when WLS' reclaiming the connection for reuse(keep-alive) purpose, it tries to read the input stream to clear unread chunks. NPE happens here as input stream has been closed.

There is an existing bug on this: Bug 8183755. Patches are available for bug  8183755:

------------------------------------------
    PATCH REPOSITORY INFORMATION
------------------------------------------
 WLS Version | Patch ID |  Passcode
--------------+----------+----------------
    9.2 GA   |   K75X   | K3EB5V7M
    9.2 MP1  |   H67L   | HZYJQECN
    9.2 MP2  |   T4HG   | MJ95CPML
    9.2 MP3  |   RZCZ   | M3IEQWIP
    10.0MP1  |   2JNU   | HX9YYCA7
    10.3 GA  |   2UZ1   | I74ATQ1X

Fixed in: 10.3.1

To apply one of these patches, download the patch using Smart Update and apply: see Note  885851.1 for step-by-step instructions. If your target system is offline, please refer to Note  876004.1 for additional assistance. All the details about SmartUpdate are available in the SmartUpdate  documentation.

Patches are specifically tied to a particular release and maintenance  pack of WebLogic Server (WLS). A patch for WLS 9.2.2, for example, very  likely would not work on WLS 9.2.3. In a few cases, patches are also specific to particular operating systems. If you think you are experiencing the problem outlined in this note, but your WLS version is not included in the list of patches provided here, please contact support and ask for a version of the patch appropriate for you. Please reference this note as well as this bug number to help speed our service  for you.
----------------------------------------------------------------------------------------------------

The following commands are used to apply the patch on weblogic v10.3.
Before running these commands, need to copy 2UZ1.jar and patch-catalog.xml to folder D:\bea\utils\bsu\cache_dir

//// view the patch info
D:\bea\utils\bsu>bsu -prod_dir=D:\bea\wlserver_10.3 -patch_download_dir=D:\bea\utils\bsu\cache_dir -status=downloaded -view -verbose
ProductName:       WebLogic Server
ProductVersion:    10.3
Components:        WebLogic Server/Core Application Server,WebLogic Server/Admi
                   nistration Console,WebLogic Server/Configuration Wizard and
                   Upgrade Framework,WebLogic Server/Web 2.0 HTTP Pub-Sub Serve
                   r,WebLogic Server/WebLogic JDBC Drivers,WebLogic Server/Thir
                   d Party JDBC Drivers,WebLogic Server/WebLogic Server Clients
                   ,WebLogic Server/WebLogic Web Server Plugins,WebLogic Server
                   /UDDI and Xquery Support,WebLogic Server/Server Examples,Web
                   Logic Server/Evaluation Database,WebLogic Server/Workshop Co
                   de Completion Support
BEAHome:           D:\bea
ProductHome:       D:\bea\wlserver_10.3
PatchSystemDir:    D:\bea\utils\bsu
PatchDir:          D:\bea\patch_wls1030
Profile:           Default
DownloadDir:       D:\bea\utils\bsu\cache_dir
JavaHome:          D:\bea\jdk160_05
JavaVersion:       1.6.0_05
JavaVendor:        Sun


Patch ID:          2UZ1
PatchContainer:    2UZ1.jar
Checksum:          -2128224792
Severity:          optional
Category:          Web App
CR:                CR371433,CR385319
Restart:           true
Description:       Fixed NPE when ServletInputStream is closed explicitly.

//// apply the patch
D:\bea\utils\bsu>bsu -prod_dir=D:\bea\wlserver_10.3 -patchlist=2UZ1 -verbose -install
Checking for conflicts..
No conflict(s) detected

Starting installation of Patch ID: 2UZ1
Installing D:\bea\utils\bsu\cache_dir\2UZ1.jar
Extracting D:\bea\patch_wls1030\patch_jars\CR371433_1030ga.jar
Updating D:\bea\patch_wls1030\profiles\default\sys_manifest_classpath\weblogic_patch.jar
Old manifest value: Class-Path=
New manifest value: Class-Path=../../../patch_jars/CR371433_1030ga.jar
Result: Success

///// verify the patch
D:\bea\utils\bsu>bsu -prod_dir=D:\bea\wlserver_10.3 -status=applied -view -verbose
ProductName:       WebLogic Server
ProductVersion:    10.3
Components:        WebLogic Server/Core Application Server,WebLogic Server/Admi
                   nistration Console,WebLogic Server/Configuration Wizard and
                   Upgrade Framework,WebLogic Server/Web 2.0 HTTP Pub-Sub Serve
                   r,WebLogic Server/WebLogic JDBC Drivers,WebLogic Server/Thir
                   d Party JDBC Drivers,WebLogic Server/WebLogic Server Clients
                   ,WebLogic Server/WebLogic Web Server Plugins,WebLogic Server
                   /UDDI and Xquery Support,WebLogic Server/Server Examples,Web
                   Logic Server/Evaluation Database,WebLogic Server/Workshop Co
                   de Completion Support
BEAHome:           D:\bea
ProductHome:       D:\bea\wlserver_10.3
PatchSystemDir:    D:\bea\utils\bsu
PatchDir:          D:\bea\patch_wls1030
Profile:           Default
DownloadDir:       D:\bea\utils\bsu\cache_dir
JavaHome:          D:\bea\jdk160_05
JavaVersion:       1.6.0_05
JavaVendor:        Sun


Patch ID:          2UZ1
PatchContainer:    2UZ1.jar
Checksum:          -2128224792
Severity:          optional
Category:          Web App
CR:                CR371433,CR385319
Restart:           true
Description:       Fixed NPE when ServletInputStream is closed explicitly.


No comments:

Post a Comment