BrowserHawk IQ now available! Click here for the full scoop!
NullPointerException with WebSphere and BH4J
Created: 3/21/2008    Updated: 3/21/2008
Q   When calling getExtendedBrowserInfo I am getting a NullPointerException under WebSphere. This does not happen when using BH4J with Tomcat. How can I resolve this.

A   This issue is related to WebSphere involving its flushing of header values that happens on committing a response. That happens when some amount (usually 8k) has been written in the response. The underlying error is unrelated to the code that was just coincidentally doing the output when the commit barrier was crossed.

To resolve the issue increase the response buffer in the page the error is occurring in, using a statement prior to calling getExtendedBrowserInfo such as: response.setBufferSize(20000);

Note that the 20000 size specified above is just an example. You may want to experiment to see what the size is that works best for your specific needs.

    FAQ Home  |  Search FAQ  |  Show New Items  |  Ask a FAQ  |  Notify Me  |  Most Popular     
Copyright © 1994-2020 cyScape, Inc. All Rights Reserved. ()