Javax.faces.context.FacesContext not found in JDeveloper 10.1.3.2

I tried to use javax.faces.context.FacesContext calss in my application but JDeveloper 10.1.3.2 can not find this class
( the same problem also in 10.1.3)
I checked the jar file of this library (jsf-api.jar ), it is in folder [jsf-ri] in Jdev home
why JDev. can not read this library
please how can i solve this problem
Waheed

Hi,
make sure the project you are working in is configured for JSF. Double click onto the project to open its properties and set the "Technology Scope" to JSF. This ensures that all libraries are cnfigured. This also adds aa copy of jsf-impl.jar to the Web-Inf/lib directory of your project.
Frank

Similar Messages

  • Get NoClassDefFoundError: javax/faces/context/FacesContext Error at Runtime

    I'm in 11g, PS1. I have an application and I have a SelectOneChoice component that invokes a managed bean (i.e. #{queryHandler.availableFilterChoice}). It then calls my constructor public QueueHandler and within that constructor i have the following line of code:
    Application application = FacesContext.getCurrentInstance().getApplication();
    This line of code builds and compiles, but at runtime I get the following error NoClassDefFoundError: javax/faces/context/FacesContext and the application stops and fails and nothing is rendered. I have the following libraries in my project:
    JSP Runtime
    JSF 1.2
    JSTL 1.2
    ADF Page Flow Runtime
    ADF Controller Runtime
    ADF Controller Schema
    ADF Faces Runtime 11
    ADF Common Runtime
    ADF Web Runtime
    MDS Runtime
    MDS Runtime Dependencies
    Common Beanutils 1.6
    Common Logging 1.0.4
    Common Collections 3.1
    ADF DVT Faces Runtime
    ADF DVT Faces Databinding Runtime
    EJB 3.0
    JPS Designtime
    TopLink
    Oracle XML Parser V2
    Java EE 1.5 API
    Oracle JEWT
    Trinidad Runtime 11
    JSTL 1.2 Tags
    Resource Bundle Support
    Resource Bundle Variable Resolver
    Weblogic 10.3 Remote-Client
    Oracle JDBC

    I'm sorry, but I guess I don't understand what you're saying. But I'm not using the line of code below anywhere so I cannot remove it. I did try to use to use that line of code then I used the import org.apache.myfaces.trinidad.util.Service; and when I use those lines of code, I get the same exact Error.
    ExtendedRenderKitService erks = Service.getRenderKitService(FacesContext.getCurrentInstance(), ExtendedRenderKitService.class);

  • Oracle.adf.controller.faces.context.FacesPageLifecycleContext not found

    Hi all,
    I am using JDeveloper 11.1.1.0 and I am trying to do an application about security.
    I have found some references on web and I have a bean that uses this line of code:
    FacesPageLifecycleContext ctx = (FacesPageLifecycleContext)event.getLifecycleContext();
    but on the line:
    import oracle.adf.controller.faces.context.FacesPageLifecycleContext;
    the debugger tells me: "class oracle.adf.controller.faces.context.FacesPageLifecycleContext not found"
    What's the correct class to import?
    Thanks

    Hi,
    not sure what you are doing - however I am not asking ;-)
    Try import oracle.adf.controller.v2.context.LifecycleContext
    Frank

  • ClassNotFoundException: javax.faces.context.FacesContext

    I am deploying my WebCenter Portal: Framework application from JDeveloper 11.1.1.6.0 to to a custom managed server in a 11.1.1.6.0. WebLogic domain (with latest bundle patch).
    Deployment fails with the following error:
    Stack trace for message 149004
    java.lang.ClassNotFoundException: javax.faces.context.FacesContext at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:297) at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:270) at java.lang.ClassLoader.loadClass(ClassLoader.java:660) at java.lang.ClassLoader.loadClass(ClassLoader.java:626) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:179) at java.lang.Class.getDeclaredFieldsImpl(Native Method) at java.lang.Class.getDeclaredFields(Class.java:550) at weblogic.j2ee.dd.xml.BaseJ2eeAnnotationProcessor.getFields(BaseJ2eeAnnotationProcessor.java:1024) at weblogic.j2ee.dd.xml.BaseJ2eeAnnotationProcessor.getFields(BaseJ2eeAnnotationProcessor.java:1017) at weblogic.j2ee.dd.xml.BaseJ2eeAnnotationProcessor.processJ2eeAnnotations(BaseJ2eeAnnotationProcessor.java:98) at weblogic.j2ee.dd.xml.J2eeAnnotationProcessor.processJ2eeAnnotations(J2eeAnnotationProcessor.java:37) at weblogic.servlet.internal.WebAnnotationProcessorImpl.processFilters(WebAnnotationProcessorImpl.java:239) at weblogic.servlet.internal.WebAnnotationProcessorImpl.processJ2eeAnnotations(WebAnnotationProcessorImpl.java:210) at weblogic.servlet.internal.WebAnnotationProcessorImpl.processAnnotations(WebAnnotationProcessorImpl.java:105) at weblogic.servlet.internal.WebAppServletContext.processAnnotations(WebAppServletContext.java:1371) at weblogic.servlet.internal.WebAppServletContext.<init>(WebAppServletContext.java:451) at weblogic.servlet.internal.WebAppServletContext.<init>(WebAppServletContext.java:495) at weblogic.servlet.internal.HttpServer.loadWebApp(HttpServer.java:418) at weblogic.servlet.internal.WebAppModule.registerWebApp(WebAppModule.java:976) at weblogic.servlet.internal.WebAppModule.prepare(WebAppModule.java:384) at weblogic.application.internal.flow.ScopedModuleDriver.prepare(ScopedModuleDriver.java:176) at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:199) at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:517) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:159) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:45) at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:648) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52) at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:191) at weblogic.application.internal.EarDeployment.prepare(EarDeployment.java:59) at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:154) at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:60) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.createAndPrepareContainer(ActivateOperation.java:208) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doPrepare(ActivateOperation.java:98) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.prepare(AbstractOperation.java:217) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentPrepare(DeploymentManager.java:747) at weblogic.deploy.internal.targetserver.DeploymentManager.prepareDeploymentList(DeploymentManager.java:1216) at weblogic.deploy.internal.targetserver.DeploymentManager.handlePrepare(DeploymentManager.java:250) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.prepare(DeploymentServiceDispatcher.java:159) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doPrepareCallback(DeploymentReceiverCallbackDeliverer.java:171) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$000(DeploymentReceiverCallbackDeliverer.java:13) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$1.run(DeploymentReceiverCallbackDeliverer.java:46) at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:545) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256) at weblogic.work.ExecuteThread.run(ExecuteThread.java:221) Caused By: java.lang.ClassNotFoundException: javax.faces.context.FacesContext at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:297) at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:270) at java.lang.ClassLoader.loadClass(ClassLoader.java:660) at java.lang.ClassLoader.loadClass(ClassLoader.java:626) at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:179) at java.lang.Class.getDeclaredFieldsImpl(Native Method) at java.lang.Class.getDeclaredFields(Class.java:550) at weblogic.j2ee.dd.xml.BaseJ2eeAnnotationProcessor.getFields(BaseJ2eeAnnotationProcessor.java:1024) at weblogic.j2ee.dd.xml.BaseJ2eeAnnotationProcessor.getFields(BaseJ2eeAnnotationProcessor.java:1017) at weblogic.j2ee.dd.xml.BaseJ2eeAnnotationProcessor.processJ2eeAnnotations(BaseJ2eeAnnotationProcessor.java:98) at weblogic.j2ee.dd.xml.J2eeAnnotationProcessor.processJ2eeAnnotations(J2eeAnnotationProcessor.java:37) at weblogic.servlet.internal.WebAnnotationProcessorImpl.processFilters(WebAnnotationProcessorImpl.java:239) at weblogic.servlet.internal.WebAnnotationProcessorImpl.processJ2eeAnnotations(WebAnnotationProcessorImpl.java:210) at weblogic.servlet.internal.WebAnnotationProcessorImpl.processAnnotations(WebAnnotationProcessorImpl.java:105) at weblogic.servlet.internal.WebAppServletContext.processAnnotations(WebAppServletContext.java:1371) at weblogic.servlet.internal.WebAppServletContext.<init>(WebAppServletContext.java:451) at weblogic.servlet.internal.WebAppServletContext.<init>(WebAppServletContext.java:495) at weblogic.servlet.internal.HttpServer.loadWebApp(HttpServer.java:418) at weblogic.servlet.internal.WebAppModule.registerWebApp(WebAppModule.java:976) at weblogic.servlet.internal.WebAppModule.prepare(WebAppModule.java:384) at weblogic.application.internal.flow.ScopedModuleDriver.prepare(ScopedModuleDriver.java:176) at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:199) at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:517) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:159) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:45) at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:648) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52) at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:191) at weblogic.application.internal.EarDeployment.prepare(EarDeployment.java:59) at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:154) at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:60) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.createAndPrepareContainer(ActivateOperation.java:208) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doPrepare(ActivateOperation.java:98) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.prepare(AbstractOperation.java:217) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentPrepare(DeploymentManager.java:747) at weblogic.deploy.internal.targetserver.DeploymentManager.prepareDeploymentList(DeploymentManager.java:1216) at weblogic.deploy.internal.targetserver.DeploymentManager.handlePrepare(DeploymentManager.java:250) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.prepare(DeploymentServiceDispatcher.java:159) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doPrepareCallback(DeploymentReceiverCallbackDeliverer.java:171) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$000(DeploymentReceiverCallbackDeliverer.java:13) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$1.run(DeploymentReceiverCallbackDeliverer.java:46) at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:545) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256) at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)
    My apologies for the poor layout, it's WebLogic's server log.
    Any pointers were this may be going wrong? Why is it unable to load the Faces class? The domain was create using the template so it should have all required libraries.

    Alright, I've narrowed it down to my Customization Class. I attempted to have my customization class PortalCC in a JAR file, excluded it from the WAR file and added the JAR in the lib directory of the EAR file, as described on:
    http://docs.oracle.com/cd/E23943_01/web.1111/e16272/deploy_java_ee_app.htm#CHDGGFEB

  • Over-riding the class javax.faces.context.FacesContext: SUN App Server 9.1

    The method to over ride the faces context has changed between SUN Application Server 8.2 and 9.1, as a result the instructions which were previously provided on the MyFaces wiki (http://wiki.apache.org/myfaces/Installation_and_Configuration) no longer work. What I am looking for is instructions that will allow me to use our own faces jars and not (javaee.jar) which is provided as part of the application server.
    What I need to do is to get Sun Application Server 9.1 to allow me to over ride the faces context /javax/faces/context/ with that from my local jars, in version 8.X the following steps were enough:
    Start 8.X instructions:
    1. Change the config security file so that MyFaces <http://wiki.apache.org/myfaces/MyFaces> can delete it's temporary files.
    Change permission
        java.io.FilePermission <http://wiki.apache.org/myfaces/FilePermission> "<<ALL FILES>>", "read,write";to
      java.io.FilePermission <http://wiki.apache.org/myfaces/FilePermission> "<<ALL FILES>>", "read,write,delete";2. Prevent the sun reference implementation from being used
    In your WEB-INF, create a sun-web.xml file containing
        <?xml version="1.0" encoding="UTF-8"?>
        <sun-web-app>
        <class-loader delegate="false"/>
        </sun-web-app>3. That way, myfaces classes will be loaded instead of Sun RI ones.
    And prevent MyFaces <http://wiki.apache.org/myfaces/MyFaces> from loading the Sun RI context listener
    By creating in your webapp a "fake"
    com.sun.faces.config.ConfigureListener
    <http://wiki.apache.org/myfaces/ConfigureListener> that will be loaded BEFORE the sun RI one's.
    The war file I am making available as a test case has just such a file in my case it is called fakefaces.jar
    End instructions for 8.2
    However these steps have changed for version 9.1 as following the exact same procedures does not result in the Application Server using the correct jars, the following is a test using a simple find.jsp, notice how Application Server 9.1 is still using the default jars and not the ones shipping with included as part of my testApp.
    Within the war file is a jsp called find.jsp using this I can check which jar file file is being used for any class in my case I'm interested in the the /javax/faces/context/FacesContext.class, in 9.1 it always uses teh copy from javaee.jar and never teh local copy:
    For example running: http://<ip address>:<port>/test/find.jsp?class=javax.faces.context.FacesContext
    Version 9.1 returns: file:/u01/software/Apps/SunAppServer9.1/lib/javaee.jar!/javax/faces/context/FacesContext.class
    Version 8.2 returns: file:/u01/software/Apps/SunAppServer8.2/domains/domain1/applications/j2ee-apps/TestApp/test_war/WEB-INF/lib/myfaces-api.jar!/javax/faces/context/FacesContext.class
    Hence 9.1 is still using the copy provided by SUN and not our copy.
    The code for find.jsp is:
    <%
        String className = request.getParameter("class");
        Class theClass;
        try
            theClass = Class.forName(className);
            java.net.URL url = theClass.getResource("/" + theClass.getName().replace('.', '/') + ".class");
            out.println(url.getFile());
        catch (ClassNotFoundException e)
            // TODO Auto-generated catch block
            out.println(e);
    %>-------------------------------------------------
    Any idea how to over-ride the FacesContext class in version 9.1 to allow for similar functionality as 8.X
    Thanks,
    ERIC GANDT

    Alright, I've narrowed it down to my Customization Class. I attempted to have my customization class PortalCC in a JAR file, excluded it from the WAR file and added the JAR in the lib directory of the EAR file, as described on:
    http://docs.oracle.com/cd/E23943_01/web.1111/e16272/deploy_java_ee_app.htm#CHDGGFEB

  • Can't find javax.faces.context.FacesContext

    Hi,
    I have strange problem since morning. I am using Jdeveloper 10.1.3 ADF BC
    I have been using the below code successfully. But today all of a sudden everything is pointing to the wrong import
    // 1. Access the FacesContext
    FacesContext fc = javax.faces.context.FacesContext.getCurrentInstance();
    // 2. Create value binding for the #{data} EL expression
    ValueBinding vb = fc.getApplication().createValueBinding("#{data}");
    // 3. Evaluate the value binding, casting the result to BindingContext
    BindingContext bc = (BindingContext)vb.getValue(fc);
    // 4. Find the data control by name from the binding context
    DCDataControl dc = bc.findDataControl("AppModuleDataControl");
    For eg: FacesContext instead of fetching from javax.faces.context is getting FacesContext from com.sun.Faces
    DCIteratorBinding is going to oracle.jbo.uicli.binding.JUIteratorBinding instead of oracle.adf.model.binding even if i have imported it in the class. Should i start all over again.
    Please Help.
    Thanks in advance

    ADF BC isn't relevant here. However JSF is. What JSF component set are you using? Pure JSF components or ADF Faces?
    I suggest (or guess) what's happened is at some point you were using JSF only components, and the project was configured to use the pure JSF classes. However at some point you've brought in an ADF Faces component as well, and now its switched over to using the super ADF Faces classes instead.
    Does this make sense?
    Regards,
    CM.

  • Package javax.faces.context does not exist

    i get the following errors when trying to compile my class
    package javax.faces.context does not exist
    package javax.faces.component does not exist
    package javax.faces.validator does not existi'm really new to this and i do not know what this means
    i hope someone can help me
    this is my really simple code
    package  ourdemo;
    import javax.faces.context.*;
    import javax.faces.component.*;
    import javax.faces.validator.*;
    public class player
         String firstname;
         String lastname;   
         public void setfirstname(String a)
         { firstname=a; }
         public String getfirstname()
         { return firstname; }
         public void setlastname(String b)
         { lastname=b; }
         public String getlastname()
         { return lastname; }
         public void changeName()
         { lastname = firstname+" "+lastname; }             
    }

    Hello,
    nornaly this kind of errors happens, when the compiler isn't able to find the classes which it needs to compile your sourcecode. What you have to do is to say the compiler where it can find the sourcecodes. This means you have to put the jars into you classpath. you find the jars in the lib-directory of the jsf-directory which you downloaded. after unzipping the jsf-directory you will see it.
    if you use eclipse you go with you mouse to your workingdirectory, click with the right
    button on that directory ,choose properties then on the left you choose " java build path" and than on the right the libraries. Here you choose " add external jars" so you will have to direct to the jars. your are done.
    But if you don't use eclipse, you have to put those jars in your classpath, in the environment of windows.
    bye hamid

  • Class adf.controller.faces.context.FacesPageLifecycleContext not found

    Hi all,
    I am using Jdeveloper 11.1.1.0 and I have a class uses FacesPageLifecycleContext.
    When I import the class oracle.adf.controller.faces.context.FacesPageLifecycleContext, the debugger tells me it does not found that class.
    How can I solve the problem?
    Does I miss any library on my project?
    Thanks
    Andrea

    Excuse me, but I don't understand. Have I to found all these files:
    trinidad-api.jar
    trinidad-impl.jar
    adf-richclient-api-11.jar
    adf-richclient-impl-11.jar
    in my classpath?
    I am looking for these files in C:\Oracle\Middleware\jdeveloper\adfv but in this folder I have only jlib and skin folder.
    Can you give any other informations, please.
    Thank you so much

  • Javax.faces.model.ManagedBean not found

    Hi all,
    I am extremely new to JSF. Infact this is the first Hello World Application I am building that has Ajax Support. I have written following code from website :
    [http://weblogs.java.net/blog/driscoll/archive/2008/11/a_simple_ajax_j.html]
    import javax.faces.event.ActionEvent;
    import javax.faces.model.ManagedBean;
    import javax.faces.model.SessionScoped;
    @ManagedBean(name = "count")
    @SessionScoped
    public class Count {
         Integer count = 0;
        public Integer getCount() {
            return count++;
        public void reset(ActionEvent ae) {
            count = 0;
    }But Eclipse is not able to find classes for:
    javax.faces.model.ManagedBean
    javax.faces.model.SessionScoped
    Jars added currently:
    jsf-api.jar
    jsf-impl.jar
    jstl.jar
    standard.jar
    servlet-api.jar
    and some commons jar files.
    What jars should i include. I googled for it but could not get relevant information. Sadly, www.findjar.com is down.
    Thanks,
    Vikash Anand.

    Vikash.SunJava wrote:
    Hi icepax,
    Thanks for telling about jstl-1.2.jar for the application. I have added it to my application but same error continues.
    Between can you provide me some pointers for how to do Ajax + JSF? This sample is one sample I got from net that says that it is Ajax + JSF.
    If the tutorial is either some JBoss Seam Specific/wrong maybe I should be looking for some different things. Is Iceface good for Ajax + JSF?
    Thanks,
    Vikash Anand.Sorry, I can't help you with your latest reply as I haven't done Ajax...yet...nor do I have any experience with Icefaces. Anyway, there bound to be other JSF experts in this forum who can help you. If not, there are other JSF forums you can use to ask the same question as this thread - if you need to resolve this issue urgently.

  • Expression Error: Named Object: javax.faces.convert.IntegerConverter not fo

    I get the error below when i try to run the xhtml file.
    May I know how to import the "IntegerConvertor"?
    >
    Expression Error: Named Object: javax.faces.convert.IntegerConverter not found.
    >
    <?xml version='1.0' encoding='UTF-8' ?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml"     xmlns:h="http://java.sun.com/jsf/html"     xmlns:f="http://java.sun.com/jsf/core">
    <h:head>
         <title>Facelet Title</title>
    </h:head>
    <h:body>
    <h:inputText converter="javax.faces.convert.IntegerConverter" />
    </h:body>
    </html>Edited by: anIdiot on 12-Dec-2011 23:52

    <f:converter converterId="javax.faces.Integer"/>

  • Could not find Factory: javax.faces.context.FacesContextFactory

    I'm trying to start a new JSF with facelets app from scratch using JSF 1.2.06 on Tomcat 6.0.10 but I can't even get the app to start.
    I get this when I try to start the app:
    java.lang.IllegalStateException: Application was not properly initialized at startup, could not find Factory: javax.faces.context.FacesContextFactory
         javax.faces.FactoryFinder.getFactory(FactoryFinder.java:263)
         javax.faces.webapp.FacesServlet.init(FacesServlet.java:142)
         org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:699)
         org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:670)
         org.apache.jsp.index_jsp._jspService(index_jsp.java:59)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:384)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    I've seen a few contradictory pieces of advice on how to resolve but none seem very promising.
    What are the basic requirements for a JSF 1.2 application, especially regarding entries required in web.xml and faces-config.xml? I don't see this clearly documented anywhere on Sun's JSF site.
    Thanks!

    I think I found the reason for this problem.
    I should have also mentioned that my app contained a welcome page (index.jsp) that contained only a forward to my Facelet-based home page via:
    <jsp:forward page="pages/stm/StmHome.jsf" />
    My home page was named: StmHome.xhtml
    I mapped the FacesServlet to handle all requests with a *.jsf extension
    But I set the javax.faces.DEFAULT_SUFFIX context parameter to: .xhtml
    When I changed the value for the forward tag in the index.jsp to "StmHome.xhtml" the app started ok and the home page displayed without error.
    So it looks like this problem was caused by a mismatch between the value I set for the javax.faces.DEFAULT_SUFFIX context parameter and the value I set for the URL pattern in the FacesServlet mapping, correct ?
    Which brings me to my next question: should the values for the javax.faces.DEFAULT_SUFFIX and the FacesServlet URL pattern always match?
    Thanks!

  • JSF IllegalStateException:  could not find Factory: javax.faces.context....

    Dear all,
    I am trying to deploy a JSF page on the following system:
    Tomcat 5.5
    JSF 1.3
    JDK 1.5
    But keep getting the following exception:
    java.lang.IllegalStateException: Application was not properly initialized at startup, could not find Factory: javax.faces.context.FacesContextFactory (the full error is attached below).
    However, I have double checked that I have already placed all the neccessary .jar in <TOMCAT>/common/lib (e.g. jsf-api.jar, jsf-impl.jar, etc.) and also the WEB-INF/lib folder under my specific webapp (just make sure that the app should be able to retrieve it).
    I googled around and found that many people suggested to add a listener tag to the web.xml:
    <listener>
    <listener-class>com.sun.faces.config.ConfigureListener</listener-class>
    </listener>
    I also tried this but then I got 404.
    What could I have done wrong? Why can't Tomcat see the jsf-api.jar (which is where javax.faces.context.FacesContextFactory should be located)?
    Thanks very much in advance.
    Regards,
    Robert
    description The server encountered an internal error () that prevented it from fulfilling this request.
    exception
    javax.servlet.ServletException: Servlet.init() for servlet Faces Servlet threw exception
         org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
         org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
         org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:837)
         org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:640)
         org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1286)
         java.lang.Thread.run(Unknown Source)
    root cause
    java.lang.IllegalStateException: Application was not properly initialized at startup, could not find Factory: javax.faces.context.FacesContextFactory
         javax.faces.FactoryFinder$FactoryManager.getFactory(FactoryFinder.java:725)
         javax.faces.FactoryFinder.getFactory(FactoryFinder.java:239)
         javax.faces.webapp.FacesServlet.init(FacesServlet.java:164)
         org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
         org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
         org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:837)
         org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:640)
         org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1286)
         java.lang.Thread.run(Unknown Source)

    Dear all,
    I am trying to deploy a JSF page on the following system:
    Tomcat 5.5
    JSF 1.3
    JDK 1.5
    But keep getting the following exception:
    java.lang.IllegalStateException: Application was not properly initialized at startup, could not find Factory: javax.faces.context.FacesContextFactory (the full error is attached below).
    However, I have double checked that I have already placed all the neccessary .jar in <TOMCAT>/common/lib (e.g. jsf-api.jar, jsf-impl.jar, etc.) and also the WEB-INF/lib folder under my specific webapp (just make sure that the app should be able to retrieve it).
    I googled around and found that many people suggested to add a listener tag to the web.xml:
    <listener>
    <listener-class>com.sun.faces.config.ConfigureListener</listener-class>
    </listener>
    I also tried this but then I got 404.
    What could I have done wrong? Why can't Tomcat see the jsf-api.jar (which is where javax.faces.context.FacesContextFactory should be located)?
    Thanks very much in advance.
    Regards,
    Robert
    description The server encountered an internal error () that prevented it from fulfilling this request.
    exception
    javax.servlet.ServletException: Servlet.init() for servlet Faces Servlet threw exception
         org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
         org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
         org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:837)
         org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:640)
         org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1286)
         java.lang.Thread.run(Unknown Source)
    root cause
    java.lang.IllegalStateException: Application was not properly initialized at startup, could not find Factory: javax.faces.context.FacesContextFactory
         javax.faces.FactoryFinder$FactoryManager.getFactory(FactoryFinder.java:725)
         javax.faces.FactoryFinder.getFactory(FactoryFinder.java:239)
         javax.faces.webapp.FacesServlet.init(FacesServlet.java:164)
         org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
         org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
         org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:837)
         org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:640)
         org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1286)
         java.lang.Thread.run(Unknown Source)

  • Javax.naming.NameNotFoundException: SessionEJBBean not found

    Please help I am getting error: javax.naming.NameNotFoundException: SessionEJBBean not found.
    I am using JDeveloper 10g as editor.
    The embedded server is running, SessionEJBBean is also there. I have restarted the computer, changed 'SessionEJB' from 'SessionEJBBean'. Yet No success. This is what I get.:
    javax.naming.NameNotFoundException: SessionEJBBean not found
    at com.evermind.server.rmi.RMIClientContext.lookup(RMIClientContext.java:52)
    at javax.naming.InitialContext.lookup(InitialContext.java:351)
    at friends.SessionEJBClient.main(SessionEJBClient.java:11)
    Process exited with exit code 0.
    SessionEJBClient.java
    package friends;
    import javax.naming.Context;
    import javax.naming.InitialContext;
    import javax.naming.NamingException;
    public class SessionEJBClient {
    public static void main(String [] args) {
    try {
    final Context context = getInitialContext();
    SessionEJB sessionEJB = (SessionEJB)context.lookup("SessionEJBBean");
    } catch (Exception ex) {
    ex.printStackTrace();
    private static Context getInitialContext() throws NamingException {
    // Get InitialContext for Embedded OC4J
    // The embedded server must be running for lookups to succeed.
    return new InitialContext();
    }Thank you.

    Thanks Karma-9 for your reply. My issue has got resolved as I followed this link:
    http://www.oracle.com/technology/obe/obe1013jdev/10131/10131_ejb_30/ejb_30.htm
    However I have now new problem in hand, when I am trying to insert data in database
    using JSP. I am having problem with request.getParameter(). It is not
    recognised by JSP. A red underline is being shown below
    request.getParameter(). One more thing, in JSP page, if I take cursor over
    'request' in request.getParameter, it shows, 'Name request not found'. When
    I take cursor over 'getParameter' in request.getParameter, it shows, 'Method
    getParameter (java.lang.String) not found in<unknown>'.
    This is my code:
    MyPage.jsp
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <%@ page contentType="text/html;charset=windows-1252"%>
    <%@ page import="java.sql.*, javax.naming.Context,
    javax.naming.InitialContext, javax.naming.NamingException,
    friendspackage.*, java.text.*, java.util.*"%>
    <%!
    public void jspInit () {
    String name, city;
    name = request.getParameter("name");
    city = request.getParameter("city");
    try {
    final Context context = getInitialContext();
    SessionFriends sessionFriends =
    (SessionFriends)context.lookup("SessionFriends");
    sessionFriends.addFriends("name","city");
    //System.out.println( "Success" );
    } catch (Exception ex) {
    ex.printStackTrace();
    private static Context getInitialContext() throws NamingException {
    // Get InitialContext for Embedded OC4J
    // The embedded server must be running for lookups to succeed.
    return new InitialContext();
    %>MyPage.html
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html;
    charset=windows-1252"></meta>
    <title>My Friends</title>
    </head>
    <body>
    <form name="MyFriends" action="MyFriends.jsp" method="post">
    Name:
    <input type="text" name="name">
    City:
    <input type="text" name="city">
    <input type="submit" value="Submit">
    </form>
    </body>
    </html>Please let me know if I have to make any changes in web.xml which is:
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
    http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4"
    xmlns="http://java.sun.com/xml/ns/j2ee">
    <description>Empty web.xml file for Web Application</description>
    <session-config>
    <session-timeout>35</session-timeout>
    </session-config>
    <mime-mapping>
    <extension>html</extension>
    <mime-type>text/html</mime-type>
    </mime-mapping>
    <mime-mapping>
    <extension>txt</extension>
    <mime-type>text/plain</mime-type>
    </mime-mapping>
    </web-app>Thank you again.
    Anurag

  • Import javax.xml.ws.Service not found

    I am getting error import javax.xml.ws.Service not found. Which jar file I should add in JDeveloper and from where?
    This is my program:
    package examples.shop.client;
    import java.net.URL;
    import javax.xml.namespace.QName;
    import javax.xml.ws.Service;
    import examples.shop.impl.session.PricerBean;
    * This class is an example of a standalone JAX-RPC client code which uses both
    * the static stub and the dynamic proxy approach to get a reference to the
    * remote Web Service
    public class PricerClient {
    static String host = "localhost";
    static String portType = "PricerBean";
    static String serviceName = "PricerService";
    static String serviceEndpointAddress =
    "http://" + host + ":8080/" + serviceName;
    static String nameSpace = "urn:session.impl.shop.examples";
    public static void main(String[] args) throws Exception {
    URL wsdlLocation =
    new URL(serviceEndpointAddress + "/" + portType + "?WSDL");
    QName serviceNameQ = new QName(nameSpace, serviceName);
    // dynamic service usage
    Service service = Service.create(wsdlLocation, serviceNameQ);
    PricerBean pricerPort = service.getPort(PricerBean.class);
    String user = "Gerald";
    System.out.println("Tax rate: " + pricerPort.getTaxRate());
    System.out.println("Discount for : " + user + " is " +
    pricerPort.getPersonalDiscountRate(user));
    System.out.println("Discount for 1 item (at $1000,- per piece) for " +
    user + " is " +
    pricerPort.getDiscount(1, 1000, user));
    System.out.println("Discount for 5 items (at $1000,- per piece) for " +
    user + " is " +
    pricerPort.getDiscount(5, 5000, user));
    Thank you.

    I have Oracle JDeveloper Studio Edition Version 10.1.3.2.0.4066.
    Please note I have already added following libaries, jars to Tool->Project Properties->Libraries in JDeveloper.
    EJB3.0, TopLink Essentials JPA, J2EE, Jws-api.jar, Ejb30.jar, JSP Runtime, JAX-RPC Client, TopLink, JDeveloper Runtime, Embedded OC4J client, Jaxrpc-api.jar, Wsserver.jar
    Thank you.

  • Javax.naming.NameNotFoundException: Bean not found

    HI,
    we are getting javax.naming.NameNotFoundException: Bean not found exception often, it is not so frequent but it is consistent
    javax.naming.NameNotFoundException: Bean not found
         at com.evermind.server.rmi.RMIServerContext.lookup(RMIServerContext.java:207)
         at com.evermind.server.ApplicationContext.unprivileged_lookup(ApplicationContext.java:256)
         at com.evermind.server.ApplicationContext.lookup(ApplicationContext.java:196)
         at javax.naming.InitialContext.lookup(InitialContext.java:351)
         at com.xxxxx.yyyyy.framework.jndi.EJBLocator.lookup(Unknown Source)
         at com.xxxxx.yyyyy.managed.MBean.releaseAllLocks(Unknown Source)
         at com.xxxxx.yyyyy.managed.MenuBean.clearAllEnqueue(Unknown Source)
         at com.xxxxx.yyyyy.managed.MenuBean.resources(Unknown Source)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.sun.el.parser.AstValue.invoke(AstValue.java:157)
         at com.sun.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:283)
         at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68)
         at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:77)
         at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:95)
         at javax.faces.component.UICommand.broadcast(UICommand.java:383)
         at org.ajax4jsf.component.AjaxViewRoot.processEvents(AjaxViewRoot.java:321)
         at org.ajax4jsf.component.AjaxViewRoot.broadcastEvents(AjaxViewRoot.java:296)
         at org.ajax4jsf.component.AjaxViewRoot.processPhase(AjaxViewRoot.java:253)
         at org.ajax4jsf.component.AjaxViewRoot.processApplication(AjaxViewRoot.java:466)
         at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:97)
         at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:248)
         at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
         at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
         at org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:178)
         at org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:290)
         at org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:368)
         at org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:495)
         at com.evermind.server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:15)
         at com.xxxxx.yyyyy.filter.DWRLoginFilter.doFilter(Unknown Source)
         at com.evermind.server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:17)
         at com.xxxxx.wtf.yyyyy.yyyyy.doFilter(WssoLiteLogonFilter.java:260)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:621)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:370)
         at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:871)
         at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:453)
         at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:313)
         at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:199)
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)
    any help is highly appreciated

    Hi.
    Do you use remote invocation in same application or EJB module? Look [http://forums.sun.com/thread.jspa?threadID=5405443] - some notes about bean referencing

Maybe you are looking for

  • Battery exchange program - why wouldn't I get a new battery?

    Hi everyone, My MBP from December 2006 has a bad battery. 39% capacity 173 loadcycles turns off the computer without warning at high battery level Now, happily I think I can get a new one because of the date of my computer and the symptoms. Well, wro

  • Sent items not saved -- delete accounts/settings/preferences

    I have mail accounts with AOL and Mobile Me. I understand that to save sent items on the server, I must use the setting "Mailbox > Use This Mailbox For." For both AOL and Mobile Me accounts, I successfully set up the sent items folders. Under the pap

  • Partial confirmation and credit block

    Hi Friends, I have a scenario where we are using automatic credit check.  in the sales order based on the availability check the full 2 quantity is confirmed and then there is a credit block.  hence i check back the document and the confirmed quantit

  • ITunes won't install or uninstall. :(

    Howdy one and all, I've scoured your forums for an answer but I'm not really getting anywhere. :/ I wanted to install iTunes 7 to help fix my ipod (which subsequently fixed itself) but this message comes up each time. So I removed Quicktime from the

  • 16:9 to 4:3?

    I have a clip that was put into widescreen format, but it is distorted. Can I turn it into standard 4:3?