tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Eggers <its_toas...@yahoo.com>
Subject Re: Tomcat deployment webapps and the whole stew
Date Fri, 28 Jun 2013 03:45:17 GMT
On 6/27/2013 8:19 PM, Caldarale, Charles R wrote:
>> From: Narahari 'n' Savitha [mailto:savithari@gmail.com] Subject:
>> Re: Tomcat deployment webapps and the whole stew
>
>> 22:18:34,427 ERROR [ConfigServlet]
>> com.adp.rev.config.ConfigServlet.init(): Error trying to read file
>> [null]. Exception = [java.lang.NullPointerException]
>> java.lang.NullPointerException at
>> java.io.FileInputStream.<init>(FileInputStream.java:116) at
>> java.io.FileInputStream.<init>(FileInputStream.java:79) at
>> com.alp.rev.config.ConfigServlet.init(ConfigServlet.java:59)
>
>> It is trying to find the faces-config.xml file which does not seem
>> to be found. (yes it is a part of the war file and exists under
>> WEB-INF)
>
> Your servlet is making the invalid assumption that its data is
> accessible through the file system, which is explicitly not allowed
> by the servlet spec.  It should be using
> ServletContext.getResourceAsStream() rather than java.io.
>
> - Chuck

+1

I have repaired many web applications where the developers assumed a 
readable (and writeable! - don't ask) file system.

. . . just my two cents
/mde/

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message