In a previous post, I specified my JSF URL mapping as *.jsf . If however, you try to access the JSP page that contains the JSF code directly (e.g. browse to hello.jsp instead of hello.jsf), then JSF will throw an IllegalStateException. It took me a few minutes to work out what the exception means, but in this case the description is rather obvious.
java.lang.IllegalStateException: No FacesContext is available to process this request. 
This is most likely due to the request being sent to the wrong path.
com.sun.faces.taglib.jsf_core.ViewTag.doStartTag(ViewTag.java:159)
org.apache.jsp.hello_jsp._jspx_meth_f_view_0(hello_jsp.java:106)
org.apache.jsp.hello_jsp._jspService(hello_jsp.java:80)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:111)
....
xin
2/8/2011 06:21:08 pm

could u plz tell me how did u resolve this problem, coz I couldnt fix it up, and could u plz send it to my e-mail box

Reply
Cristan
2/8/2011 06:21:44 pm

This is why I don’t like JSF (or mostly any Java library for that matter): when you do something wrong, the errors you get is almost almost useless. I mean, according to you, this is an obvious error (!)

Reply



Leave a Reply.