[jsr369-experts] Re: [servlet-spec users] [SERVLET_SPEC-83] ServletContext getInitParameter(), getAttribute() and null values

From: Edward Burns <edward.burns_at_oracle.com>
Date: Wed, 12 Aug 2015 15:54:24 -0700

>>>>> On Wed, 12 Aug 2015 15:06:22 -0700, Shing Wai Chan <shing.wai.chan_at_oracle.com> said:

SW> Using String("null") in this case may not be a good idea as it
SW> introduces some special meaning of the String("null").
SW> I notice that different implementations seems to behave differently for
SW> ServletContext.getInitParameter(null).
SW> In GlassFish, it is NPE.
SW> In WebLogic, it is null.

Ahh, I misunderstood you. I thought the issue was asking about what to
return if the someone had done


What do you think we should do in that case?

I agree that we should throw NPE if the argument is null.


| edward.burns_at_oracle.com | office: +1 407 458 0017
| 59 Business days til JavaOne 2015
| 74 Business days til DOAG 2015