This discussion is archived
1 Reply Latest reply: Feb 5, 2010 11:50 AM by Linda Lee RSS

NPE from LoggerUtil in 4.0.92

730295 Newbie
Currently Being Moderated
Hi,

I'm trying to upgrade our code from 3.x to 4.x, but when the code tries to open the environment, we get an NPE from LoggerUtils on the logger.getHandlers() line (line 164). Our application runs in the Resin application server, which has its own logging implementation, it looks like the Logger instance returned by Resin is returning null for the getHandlers call, causing the NPE in LoggerUtils. Any chance you could update this to check for null ?

Thanks
Simon
  • 1. Re: NPE from LoggerUtil in 4.0.92
    Linda Lee Journeyer
    Currently Being Moderated
    Simon,

    I've opened SR #18277 for this, and we'll put in the check as you suggest, and will make it available in the next patch release.

    Email me at linda dot q dot lee at o__ .com if you want the official source code change, because there are a few more places where we call java.util.logging.Logger.getHandlers() and expect it to obey the contract that it returns an empty array rather than a null array. It will also be interesting to find out if Resin behaves differently in any other ways.

    Regards,

    Linda

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points