Java.io.FileNotFoundException in Bean code

          My application uses a application scope bean. The bean is initialized in the function
          initialize(). The bean has a Properties member which I initialize from an INI
          file.
          The code fragment below gives the exception:
          public void initialize() throws Exception
          try
          // Read in from a configuration file
          // database attributes
          Properties configProps = new Properties();
          configProps.load(new BufferedInputStream(new FileInputStream ("PI.ini")));
          // Create the database object
          dao = new DataAccessObject();
          dao.initialize(configProps);
          catch(Exception e)
          System.err.println(e);
          throw(e);
          Please let me know where should I place the INI file to avoid the exception.
          Thanks
          Shiva
          

The uri look like paths so the jsp is looking for a file at that location.
http://java.sun.com/products/jsp/syntax/1.2/syntaxref1211.html#8780
uri="URIForLibrary"
The Uniform Resource Identifier (URI) that uniquely locates the TLD that describes the set of custom tags associated with the named tag prefix. A URI can be any of the following:
A Uniform Resource Locator (URL), as defined in RFC 2396, available at http://www.hut.fi/u/jkorpela/rfc/2396/full.html
A Uniform Resource Name (URN), as defined in RFC 2396
An absolute or relative pathname
If the URI is a URL or URN, then the TLD is located by consulting the mapping indicated in web.xml extended using the implicit maps in the packaged tag libraries. If URI is pathname, it is interpreted relative to the root of the web application and should resolve to a TLD file directly, or to a JAR file that has a TLD file at location META-INF/taglib.tld.

Similar Messages

  • Problem in moving the java beans code from computer to other

    Hi,
    I am working on building a webservice. I started building the EJB teir compnents like (Entity beans, Sessions beans, data base schemas) using the SUN ONE STUDIO 5 and SUN ONE App Server 7.0.
    The problem, if I want to move the same entity beans code from one computer to other computer.
    I am using same platform except the operating system (XP, and Windows 2000), apart from this every thing is same (Sun one studio 5, sun one app server 7.0). The Entity beans are working on the source computer and tested the beans. But When I moved the code to other computer, I compiled the entity beans code and it compiled perfectly. Then I tested the entity bean, I generated the test client, and deployed it. Till now no problem. When I tried to excute it and invoke the functions then it giving the following error:
    Is there any solution, so that I can avoid coding from scrath again when I want to use same on other computer.
    [22/Sep/2003:10:29:39] SEVERE ( 1616):
    javax.ejb.EJBException: nested exception is: com.sun.jdo.api.persistence.support.JDOUserException: Object not found for this ObjectId.
    NestedException: java.lang.ClassCastException: java.lang.String
    com.sun.jdo.api.persistence.support.JDOUserException: Object not found for this ObjectId.
    NestedException: java.lang.ClassCastException: java.lang.String
    at com.sun.jdo.spi.persistence.support.sqlstore.impl.PersistenceManagerImpl.getObjectById(PersistenceManagerImpl.java:615)
    at com.sun.jdo.spi.persistence.support.sqlstore.impl.PersistenceManagerWrapper.getObjectById(PersistenceManagerWrapper.java:247)
    at Data.AppNumInfoBean_535499553_ConcreteImpl.jdoGetInstance(AppNumInfoBean_535499553_ConcreteImpl.java:905)
    at Data.AppNumInfoBean_535499553_ConcreteImpl.ejbLoad(AppNumInfoBean_535499553_ConcreteImpl.java:693)
    at com.sun.ejb.containers.EntityContainer.callEJBLoad(EntityContainer.java:2372)
    at com.sun.ejb.containers.EntityContainer.afterBegin(EntityContainer.java:1362)
    at com.sun.ejb.containers.BaseContainer.startNewTx(BaseContainer.java:1405)
    at com.sun.ejb.containers.BaseContainer.preInvokeTx(BaseContainer.java:1313)
    at com.sun.ejb.containers.BaseContainer.preInvoke(BaseContainer.java:462)
    at Data.AppNumInfoBean_535499553_ConcreteImpl_EJBObjectImpl.getDatelastapp(AppNumInfoBean_535499553_ConcreteImpl_EJBObjectImpl.java:113)
    at Data._AppNumInfo_Stub.getDatelastapp(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:324)
    at com.sun.forte4j.j2ee.ejbtest.webtest.InvocableMethod$MethodIM.invoke(InvocableMethod.java:231)
    at com.sun.forte4j.j2ee.ejbtest.webtest.EjbInvoker.getInvocationResults(EjbInvoker.java:96)
    at com.sun.forte4j.j2ee.ejbtest.webtest.DispatchHelper.getForward(DispatchHelper.java:189)
    at jasper.dispatch_jsp._jspService(_dispatch_jsp.java:136)
    at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.iplanet.ias.web.jsp.JspServlet$JspServletWrapper.service(JspServlet.java:552)
    at com.iplanet.ias.web.jsp.JspServlet.serviceJspFile(JspServlet.java:368)
    at com.iplanet.ias.web.jsp.JspServlet.service(JspServlet.java:287)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at org.apache.catalina.core.StandardWrapperValve.invokeServletService(StandardWrapperValve.java:720)
    at org.apache.catalina.core.StandardWrapperValve.access$000(StandardWrapperValve.java:118)
    at org.apache.catalina.core.StandardWrapperValve$1.run(StandardWrapperValve.java:278)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:274)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:212)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:203)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
    at com.iplanet.ias.web.connector.nsapi.NSAPIProcessor.process(NSAPIProcessor.java:157)
    at com.iplanet.ias.web.WebContainer.service(WebContainer.java:598)
    javax.ejb.EJBException: nested exception is: com.sun.jdo.api.persistence.support.JDOUserException: Object not found for this ObjectId.
    NestedException: java.lang.ClassCastException: java.lang.String
    at com.sun.ejb.containers.EntityContainer.afterBegin(EntityContainer.java:1378)
    at com.sun.ejb.containers.BaseContainer.startNewTx(BaseContainer.java:1405)
    at com.sun.ejb.containers.BaseContainer.preInvokeTx(BaseContainer.java:1313)
    at com.sun.ejb.containers.BaseContainer.preInvoke(BaseContainer.java:462)
    at Data.AppNumInfoBean_53
    [22/Sep/2003:10:32:00] INFO ( 1616): Bean AppNumInfo method ejbLoad:
    com.sun.jdo.api.persistence.support.JDOUserException: Object not found for this ObjectId.
    NestedException: java.lang.ClassCastException: java.lang.String
    at com.sun.jdo.spi.persistence.support.sqlstore.impl.PersistenceManagerImpl.getObjectById(PersistenceManagerImpl.java:615)
    at com.sun.jdo.spi.persistence.support.sqlstore.impl.PersistenceManagerWrapper.getObjectById(PersistenceManagerWrapper.java:247)
    at Data.AppNumInfoBean_535499553_ConcreteImpl.jdoGetInstance(AppNumInfoBean_535499553_ConcreteImpl.java:905)
    at Data.AppNumInfoBean_535499553_ConcreteImpl.ejbLoad(AppNumInfoBean_535499553_ConcreteImpl.java:693)
    at com.sun.ejb.containers.EntityContainer.callEJBLoad(EntityContainer.java:2372)
    at com.sun.ejb.containers.EntityContainer.afterBegin(EntityContainer.java:1362)
    at com.sun.ejb.containers.BaseContainer.startNewTx(BaseContainer.java:1405)
    at com.sun.ejb.containers.BaseContainer.preInvokeTx(BaseContainer.java:1313)
    at com.sun.ejb.containers.BaseContainer.preInvoke(BaseContainer.java:462)
    at Data.AppNumInfoBean_535499553_ConcreteImpl_EJBObjectImpl.setDatelastapp(AppNumInfoBean_535499553_ConcreteImpl_EJBObjectImpl.java:138)
    at Data._AppNumInfo_Stub.setDatelastapp(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:324)
    at com.sun.forte4j.j2ee.ejbtest.webtest.InvocableMethod$MethodIM.invoke(InvocableMethod.java:231)
    at com.sun.forte4j.j2ee.ejbtest.webtest.EjbInvoker.getInvocationResults(EjbInvoker.java:96)
    at com.sun.forte4j.j2ee.ejbtest.webtest.DispatchHelper.getForward(DispatchHelper.java:189)
    at jasper.dispatch_jsp._jspService(_dispatch_jsp.java:136)
    at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.iplanet.ias.web.jsp.JspServlet$JspServletWrapper.service(JspServlet.java:552)
    at com.iplanet.ias.web.jsp.JspServlet.serviceJspFile(JspServlet.java:368)
    at com.iplanet.ias.web.jsp.JspServlet.service(JspServlet.java:287)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at org.apache.catalina.core.StandardWrapperValve.invokeServletService(StandardWrapperValve.java:720)
    at org.apache.catalina.core.StandardWrapperValve.access$000(StandardWrapperValve.java:118)
    at org.apache.catalina.core.StandardWrapperValve$1.run(StandardWrapperValve.java:278)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:274)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:212)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:203)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
    at com.iplanet.ias.web.connector.nsapi.NSAPIProcessor.process(NSAPIProcessor.java:157)
    at com.iplanet.ias.web.WebContainer.service(WebContainer.java:598)
    [22/Sep/2003:10:32:00] SEVERE ( 1616): EJB5017: Exception while running preinvoke : ejbName = [AppNumInfo]
    [22/Sep/2003:10:32:00] SEVERE ( 1616):
    javax.ejb.EJBException: nested exception is: com.sun.jdo.api.persistence.support.JDOUserException: Object not found for this ObjectId.
    NestedException: java.lang.ClassCastException: java.lang.String
    com.sun.jdo.api.persistence.support.JDOUserException: Object not found for this ObjectId.
    NestedException: java.lang.ClassCastException: java.lang.String
    at com.sun.jdo.spi.persistence.support.sqlstore.impl.PersistenceManagerImpl.getObjectById(PersistenceManagerImpl.java:615)
    at com.sun.jdo.spi.persistence.support.sqlstore.impl.PersistenceManagerWrapper.getObjectById(PersistenceManagerWrapper.java:247)
    at Data.AppNumInfoBean_535499553_ConcreteImpl.jdoGetInstance(AppNumInfoBean_535499553_ConcreteImpl.java:905)
    at Data.AppNumInfoBean_535499553_ConcreteImpl.ejbLoad(AppNumInfoBean_535499553_ConcreteImpl.java:693)
    at com.sun.ejb.containers.EntityContainer.callEJBLoad(EntityContainer.java:2372)
    at com.sun.ejb.containers.EntityContainer.afterBegin(EntityContainer.java:1362)
    at com.sun.ejb.containers.BaseContainer.startNewTx(BaseContainer.java:1405)
    at com.sun.ejb.containers.BaseContainer.preInvokeTx(BaseContainer.java:1313)
    at com.sun.ejb.containers.BaseContainer.preInvoke(BaseContainer.java:462)
    at Data.AppNumInfoBean_535499553_ConcreteImpl_EJBObjectImpl.setDatelastapp(AppNumInfoBean_535499553_ConcreteImpl_EJBObjectImpl.java:138)
    at Data._AppNumInfo_Stub.setDatelastapp(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:324)
    at com.sun.forte4j.j2ee.ejbtest.webtest.InvocableMethod$MethodIM.invoke(InvocableMethod.java:231)
    at com.sun.forte4j.j2ee.ejbtest.webtest.EjbInvoker.getInvocationResults(EjbInvoker.java:96)
    at com.sun.forte4j.j2ee.ejbtest.webtest.DispatchHelper.getForward(DispatchHelper.java:189)
    at jasper.dispatch_jsp._jspService(_dispatch_jsp.java:136)
    at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.iplanet.ias.web.jsp.JspServlet$JspServletWrapper.service(JspServlet.java:552)
    at com.iplanet.ias.web.jsp.JspServlet.serviceJspFile(JspServlet.java:368)
    at com.iplanet.ias.web.jsp.JspServlet.service(JspServlet.java:287)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at org.apache.catalina.core.StandardWrapperValve.invokeServletService(StandardWrapperValve.java:720)
    at org.apache.catalina.core.StandardWrapperValve.access$000(StandardWrapperValve.java:118)
    at org.apache.catalina.core.StandardWrapperValve$1.run(StandardWrapperValve.java:278)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:274)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:212)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:203)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:505)
    at com.iplanet.ias.web.connector.nsapi.NSAPIProcessor.process(NSAPIProcessor.java:157)
    at com.iplanet.ias.web.WebContainer.service(WebContainer.java:598)
    javax.ejb.EJBException: nested exception is: com.sun.jdo.api.persistence.support.JDOUserException: Object not found for this ObjectId.
    NestedException: java.lang.ClassCastException: java.lang.String
    at com.sun.ejb.containers.EntityContainer.afterBegin(EntityContainer.java:1378)
    at com.sun.ejb.containers.BaseContainer.startNewTx(BaseContainer.java:1405)
    at com.sun.ejb.containers.BaseContainer.preInvokeTx(BaseContainer.java:1313)
    at com.sun.ejb.containers.BaseContainer.preInvoke(BaseContainer.java:462)
    at Data.AppNumInfoBean_53

    There appears to be either a portion that didn't get recompiled, or perhaps a hard-coded GUID-type number within the application. Carefully go over the elements in the application that were hard-coded to run on the other machine -- were they have all been migrated?

  • Complex "validation rule" using Java Bean code

    Hi,
    I have never used validation rules with jdeveloper, but i need a complex validation rule of one column of my table.
    Can i put a "validation rule" on an attibute of a view object, or on a column of a table, that use Bean code ?
    My column must contain different values depending of the other columns of the table, so i think i can't do this without java code...
    I tried to doubleClick on the column to create a validator, but I have put a "Print" inside, and seen that it is executes lots of times, but I want to execute the validation only when the value of the column change !
    How can I do this ? What do i need to use ?
    Regards,
    Trigger

    I have use John's solution, it works well !
    Sorry vinod_t_krishnan i am good with java but i don't know how to use well EL Expressions so I did not try your method...
    The code if so is interested...
        public boolean validateOvpdOvprCode(String ovpdovprcode) {
            RowIterator ovRubrique = this.getOvRubrique();
            RowIterator ovRubriqueType = this.getOvRubriqueType();
            String modifiable = (String)ovRubriqueType.getRowAtRangeIndex(0).getAttribute("OvrtModifiable");
            String majuscule = (String)ovRubrique.getRowAtRangeIndex(0).getAttribute("OvruMajuscule");
            String type = (String)ovRubrique.getRowAtRangeIndex(0).getAttribute("OvruTypeDonnee");
            BigDecimal repMin = (BigDecimal)ovRubrique.getRowAtRangeIndex(0).getAttribute("OvruRepMini");
            BigDecimal repMax = (BigDecimal)ovRubrique.getRowAtRangeIndex(0).getAttribute("OvruRepMaxi");
            modifiable = modifiable.toUpperCase();
            majuscule = majuscule.toUpperCase();
            type = type.toUpperCase();
            BigDecimal ovprBD = null;
            if (modifiable.equals("N")) {
                errorMessage = "Ce champ n'est pas modifiable ! Actualisez la page pour réinitialiser sa valeur !";
                return false;
            } else {
                if (ovpdovprcode == null)
                    return true;
                if (type.equals("N")) {
                    float ovprInt = 0;
                    try {
                        ovprInt = Float.parseFloat(ovpdovprcode);
                        ovprBD = new BigDecimal(ovprInt);
                    } catch (Exception e) {
                        errorMessage =
                                "Ce champ est de type numérique, il ne doit contenir que des chiffres et un 'point'";
                        return false;
                    if(repMin != null && repMax != null)
                        if(ovprBD.compareTo(repMin) == -1 || ovprBD.compareTo(repMax) == 1) {
                            System.out.println("4");
                            errorMessage = "La réponse doit être comprise entre " + repMin + " et " + repMax + ".";
                            return false;
                if (majuscule.equals("O"))
                    if (!ovpdovprcode.equals(ovpdovprcode.toUpperCase())) {
                        errorMessage = "Ce champ doit comporter uniquement des majuscules";
                        return false;
                return true;
        }

  • Java.io.FileNotFoundException in a JSP Page

    Hi people,
    My JSP page is launching an IOException: java.io.FileNotFoundException and the compiler is telling that the problem is occurring at this code:
    <%@ taglib uri="/tags/struts-logic" prefix="logic" %>
    <%@ taglib uri="/tags/struts-html" prefix="html" %>
    <%@ taglib uri="/tags/struts-bean" prefix="bean" %>
    Could you tell me what is the problem with this code right here???
    Greetings and best regards...
    Lucas

    The uri look like paths so the jsp is looking for a file at that location.
    http://java.sun.com/products/jsp/syntax/1.2/syntaxref1211.html#8780
    uri="URIForLibrary"
    The Uniform Resource Identifier (URI) that uniquely locates the TLD that describes the set of custom tags associated with the named tag prefix. A URI can be any of the following:
    A Uniform Resource Locator (URL), as defined in RFC 2396, available at http://www.hut.fi/u/jkorpela/rfc/2396/full.html
    A Uniform Resource Name (URN), as defined in RFC 2396
    An absolute or relative pathname
    If the URI is a URL or URN, then the TLD is located by consulting the mapping indicated in web.xml extended using the implicit maps in the packaged tag libraries. If URI is pathname, it is interpreted relative to the root of the web application and should resolve to a TLD file directly, or to a JAR file that has a TLD file at location META-INF/taglib.tld.

  • Java.io.FileNotFoundException: Unable to locate style sheet "oracle/webcent

    Hi
    I have created a webceter application in jdeveloper 11.1.1.4 with the default page templates and pages.
    After creating the application i followed the below steps
    1. Created a new skin file test-skin.css under webcontent/oracle/webcenter/portalapp/skins
    2. Created a trinidad-skins.xml under WEB-INF and configured it as below
    <?xml version="1.0" encoding="windows-1252" ?>
    <skins xmlns="http://myfaces.apache.org/trinidad/skin">
    <skin>
    <id>testskin</id>
    <family>testskin</family>
    <version>
    <name>v1</name>
    <default>true</default>
    </version>
    <render-kit-id>org.apache.myfaces.trinidad.desktop</render-kit-id>
    <style-sheet-name>oracle/webcenter/portalapp/skins/test-skin.css</style-sheet-name>
    </skin>
    </skins>
    3. Made entry in the trinidad-config.xml as
    <?xml version="1.0" encoding="windows-1252"?>
    <trinidad-config xmlns="http://myfaces.apache.org/trinidad/config">
    <skin-family>testskin</skin-family>
    </trinidad-config>
    4. Ran the portal but got error on the console as below
    <StyleSheetEntry> <_getNameResolver> Could not load style sheet: oracle/webcenter/portalapp/skins/test-skin.css
    <StyleSheetEntry> <_getNameResolver>
    java.io.FileNotFoundException: Unable to locate style sheet "oracle/webcenter/portalapp/skins/test-skin.css" in local styles directory (C:\Users\197944 \AppData\Roaming\JDeveloper\system11.1.1.4.37.59.23\DefaultDomain\servers\DefaultServer\tmp\_WL_user\TestSkin_V2.0\7x71m9\public\adf\styles), or on the class path.
    Please be sure that this style sheet is installed.
         at org.apache.myfaces.trinidadinternal.skin.StyleSheetEntry._getNameResolverForStyleSheetFile(StyleSheetEntry.java:439)
         at org.apache.myfaces.trinidadinternal.skin.StyleSheetEntry._getNameResolver(StyleSheetEntry.java:347)
         at org.apache.myfaces.trinidadinternal.skin.StyleSheetEntry.createEntry(StyleSheetEntry.java:78)
         at org.apache.myfaces.trinidadinternal.skin.SkinImpl._createStyleSheetDocument(SkinImpl.java:563)
         at org.apache.myfaces.trinidadinternal.skin.SkinImpl.getStyleSheetDocument(SkinImpl.java:346)
         at org.apache.myfaces.trinidadinternal.skin.SkinExtension.getStyleSheetDocument(SkinExtension.java:527)
         at org.apache.myfaces.trinidadinternal.skin.SkinStyleProvider.createStyleSheetDocument(SkinStyleProvider.java:158)
         at org.apache.myfaces.trinidadinternal.style.cache.FileSystemStyleCache._getStyleSheetDocument(FileSystemStyleCache.java:649)
         at org.apache.myfaces.trinidadinternal.style.cache.FileSystemStyleCache._getEntry(FileSystemStyleCache.java:424)
         at org.apache.myfaces.trinidadinternal.style.cache.FileSystemStyleCache.getStyleSheetURIs(FileSystemStyleCache.java:178)
         at org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.StyleSheetRenderer.encodeAll(StyleSheetRenderer.java:97)
         at org.apache.myfaces.trinidad.render.CoreRenderer.encodeEnd(CoreRenderer.java:335)
         at org.apache.myfaces.trinidad.component.UIXComponentBase.encodeEnd(UIXComponentBase.java:767)
         at javax.faces.component.UIComponent.encodeAll(UIComponent.java:937)
         at oracle.adfinternal.view.faces.renderkit.rich.DocumentRenderer._renderSkinStylesheet(DocumentRenderer.java:1999)
         at oracle.adfinternal.view.faces.renderkit.rich.DocumentRenderer.encodeAll(DocumentRenderer.java:885)
         at oracle.adf.view.rich.render.RichRenderer.encodeAll(RichRenderer.java:1396)
         at org.apache.myfaces.trinidad.render.CoreRenderer.encodeEnd(CoreRenderer.java:335)
         at org.apache.myfaces.trinidad.component.UIXComponentBase.encodeEnd(UIXComponentBase.java:767)
         at javax.faces.component.UIComponent.encodeAll(UIComponent.java:937)
         at javax.faces.component.UIComponent.encodeAll(UIComponent.java:933)
         at com.sun.faces.application.ViewHandlerImpl.doRenderView(ViewHandlerImpl.java:266)
         at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:197)
         at javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:189)
         at org.apache.myfaces.trinidadinternal.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:193)
         at oracle.webcenter.portalframework.sitestructure.handler.CustomViewHandler.renderView(CustomViewHandler.java:279)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._renderResponse(LifecycleImpl.java:777)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:293)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:213)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:266)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
         at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.portlet.client.adapter.adf.ADFPortletFilter.doFilter(ADFPortletFilter.java:32)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.webcenter.framework.events.dispatcher.EventDispatcherFilter.doFilter(EventDispatcherFilter.java:44)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:205)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:106)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:446)
         at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:446)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:271)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:177)
         at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.wcps.client.PersonalizationFilter.doFilter(PersonalizationFilter.java:75)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.webcenter.content.integration.servlets.ContentServletFilter.doFilter(ContentServletFilter.java:168)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.webcenter.lifecycle.filter.LifecycleLockFilter.doFilter(LifecycleLockFilter.java:151)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adf.library.webapp.LibraryFilter.doFilter(LibraryFilter.java:175)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:111)
         at java.security.AccessController.doPrivileged(Native Method)
         at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:313)
         at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:413)
         at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:94)
         at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:161)
         at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:136)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3715)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
         at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)
         at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)
         at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:207)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:176)
    I also tried creating portal resource for the skin by right clicking on the skin file, but i still get the same error.
    If i create a skin file under anyother folder directly under the webcontent say /css/test-skin.css it works file.
    Am i doing something wrong or missing any entries?Help is appreciated.
    Thanks

    By default, trinidad-config picks up the skin setup through the preference bean - "#{preferenceBean.defaultTrinidadSkin}". The default skin can be setup through adf-config.xml at design time (look for <portal:preference id="oracle.webcenter.portalapp.skin") or using the Administration console at run-time. The value used here is whatever you've configured as "Skin Family" when creating the portal resource.
    Of course, you can edit the trinidad-config to hard-code the skin as well using the same "Skin Family" from the Create Portal Resource dialog.

  • PeopleSoft XML Publisher report error with java.io.FileNotFoundException

    Hi,
    I have created two reports using XML Publisher in Peoplesoft Financials. The two reports are not related and they were submitted for processing separately. The first report completes without any issues. The second report results in error with the following message:
    09.11.17 ..(CIS_POTRPT.XML_FILE.Step03) (PeopleCode)
    [012309_091118154][oracle.apps.xdo.template.FOProcessor][EXCEPTION] IOException is occurred in FOProcessor.setData(String) with 'files/cis_potrpt.xml'.
    [012309_091118500][oracle.apps.xdo.template.FOProcessor][EXCEPTION] java.io.FileNotFoundException: files/cis_potrpt.xml (A file or directory in the path name does not exist.)
         at java.io.FileInputStream.open(Native Method)
         at java.io.FileInputStream.<init>(FileInputStream.java(Compiled Code))
         at java.io.FileInputStream.<init>(FileInputStream.java:89)
         at oracle.apps.xdo.template.FOProcessor.getInputStream(FOProcessor.java:1316)
         at oracle.apps.xdo.template.FOProcessor.getXMLInput(FOProcessor.java:1100)
         at oracle.apps.xdo.template.FOProcessor.setData(FOProcessor.java:372)
         at com.peoplesoft.pt.xmlpublisher.PTFOProcessor.generateOutput(PTFOProcessor.java:53)
    2009-01-23-09.11.18.000418 AePcdExecutePeopleCode [174] Exception logged: RC=100.
    Error generating report output: (235,2309) PSXP_RPTDEFNMANAGER.ReportDefn.OnExecute Name:ProcessReport PCPC:51552 Statement:1153
    Called from:CIS_POTRPT.XML_FILE.GBL.default.1900-01-01.Step03.OnExecute Statement:8
    2009-01-23-09.11.18.000617 DoStepActions [1797] Exception logged: RC=100.
    Process 598607 ABENDED at Step CIS_POTRPT.XML_FILE.Step03 (PeopleCode) -- RC = 24 (108,524)
    In the process monitor detail > view log/trace page, the xml file is accessible so the file was generated to a valid directory.
    The weird thing is I was able to run this report without any issues few weeks ago although another user also ran into same error. The PeopleCode step that has been identified is essentially same in the two reports. I checked the app server and the directory does exist as well as the xml files for the two reports. The problem does not occur in test environment, just in production. Any help would be appreciated.

    We encounter the same problem. Did you get the answer for this issue? Thanks in advance.

  • XML Publisher post-processing error 'java.io.FileNotFoundException'

    Hi,
    We are getting following XML Publisher post-processing error while running XML Publisher report.
    It was working earlier but suddenly its erroring out.
    [9/07/10 9:00:17 PM] [OPPServiceThread1] Post-processing request 559655.
    [9/07/10 9:00:18 PM] [39177:RT559655] Executing post-processing actions for request 559655.
    [9/07/10 9:00:18 PM] [39177:RT559655] Starting XML Publisher post-processing action.
    [9/07/10 9:00:18 PM] [39177:RT559655]
    Template code: XXHPOXPRRFLR
    Template app: XXH
    Language: en
    Territory: 00
    Output type: PDF
    [9/07/10 9:00:18 PM] [UNEXPECTED] [39177:RT559655] java.io.FileNotFoundException: /apps/oracle/DEV/inst/apps/DEV_hlt439erplap001/logs/appl/conc/out/o559655.out (No such file or directory)
         at java.io.FileInputStream.open(Native Method)
         at java.io.FileInputStream.<init>(FileInputStream.java:106)
         at oracle.apps.fnd.cp.opp.XMLPublisherProcessor.process(XMLPublisherProcessor.java:274)
         at oracle.apps.fnd.cp.opp.OPPRequestThread.run(OPPRequestThread.java:173)
    [9/07/10 9:00:18 PM] [39177:RT559655] Completed post-processing actions for request 559655.
    Please help me out to resolve this issue.
    Thanks & Regards,
    Sagarika

    Hi,
    java.io.FileNotFoundException: /apps/oracle/DEV/inst/apps/DEV_hlt439erplap001/logs/appl/conc/out/o559655.out (No such file or directory)Most probably this file is not created (since no changes have been done recently, so definitely it is not a permission issue), and if there are any log files generate at the client side it should help in investigating the issue.
    Thanks,
    Hussein

  • Java.lang.NoSuchMethodError using beans and JSP

    Hi,
    I get a
    java.lang.NoSuchMethodError: Unit.UnitBean.execSQL(Ljava/lang/String; Ljava/sql/ResultSet;
    when i try to call that method from my jsp page. I can call all other methods in teh bean but I can't understand why it can't find execSQL when it finds every thing else.
    Any help would be greatly appreciated.
    Mike
    Heres a copy of my java bean code:
    package Unit;
    import java.sql.*; 
    import java.io.*; 
    public class UnitBean
         Connection con;
         String error;
         public boolean connect() throws ClassNotFoundException,SQLException
              String StudentNumber = "xxx";
              String strHost = "xxxx";
              String strConnectURL = ("jdbc:postgresql://" + strHost + "/");
              String strUser = "xxxx";
              String strPassword = "xxxxx";
              Class.forName("org.postgresql.Driver");
              con = DriverManager.getConnection(strConnectURL, strUser, strPassword);     
              return true;
         public void disconnect() throws SQLException
              con.close();
         public ResultSet execSQL(String sql)throws SQLException
              Statement s = con.createStatement();
              ResultSet rs = s.executeQuery(sql);
              return rs;
         public String test()
              String Mike="HIHIHIHIHI";
              return Mike;
    }And the jsp code:
    <%@ page language="java" contentType="text/html"%>
    <%@ page import="java.sql.*" %>
    <%@ page import="java.io.*" %>
    <jsp:useBean id="Unit" class="Unit.UnitBean" scope="page"/>
    <html>
         <head>
              <title>Test My Bean!!!!???!!?!</title>
         </head>
         <body>
              <%
                   String SQL ="Select * from unit where unitid='CMPS2B26'";
                   ResultSet rs =null;
                   try
                        Unit.connect();
                        rs = Unit.execSQL(SQL);
                        while(rs.next())
                                  out.println(rs.getString("unitid"));
                        Unit.disconnect();     
                   catch(Exception e)
                        out.println("<p>Problem with jsp code" +e);
              %>
              This is a jsp page.
              <p><a href = "http://stuweb3.cmp.uea.ac.uk/~xxxx/index.html">Click here for home page</a>
         </body>
    </html>

    Yeah, that worked great, thanks a lot. I thought that JSP compiled when you changed it and then visited it, but i've tried that. I just ran ant stop start on my server and it's all working.
    Thanks again :)
    Mike

  • Java.io.FileNotFoundException: when calling the parse() method of XMLReader

    Hi all, I'm getting the next exception:
    java.io.FileNotFoundException: C:\OP2\< (The name of the file, directory or volumn's label is not invalid)
    Which file is talking that exception about?
    I've no idea of what do this exception means.
    Please help me as it's very urgent.
    Thanks on advance.

    here you are the code:
    package com.saincotrafico.optimus.jms;
    import javax.jms.*;
    import com.saincotrafico.optimus.xml.*;
    import javax.xml.parsers.*;
    import org.xml.sax.*;
    import org.xml.sax.helpers.*;
    import java.io.*;
    import com.saincotrafico.optimus.client.gui.*;
    import javax.swing.SwingUtilities;
    * Description of the Class
    *@author root
    *@created 15 de febrero de 2002
    public class XMLListener implements MessageListener
    DataManager dm;
    InputSource input = new InputSource();
    DefaultHandler mh = null;
    SAXParserFactory spf = null;
    XMLReader xmlReader = null;
    * Constructor for the XMLListener object
    *@param dm Description of the Parameter
    public XMLListener(DataManager dm)
    System.out.println("AQUI");
    this.dm = dm;
    //mh=dm.getHandler();
    spf = SAXParserFactory.newInstance();
    try
    SAXParser saxParser = spf.newSAXParser();
    xmlReader = saxParser.getXMLReader();
    } catch (Exception ex)
    System.err.println(ex);
    //System.exit(1);
    * Description of the Method
    *@param message Description of the Parameter
    public void onMessage(Message message)
    if (message instanceof TextMessage)
    TextMessage msg = (TextMessage) message;
    try
    creaObjeto(msg.getText());
    Runnable doSetDatos =
    new Runnable()
    private DefaultHandler miHandler=mh;
    public void run()
    System.out.println("EN RUN!!!");
    dm.setDatos(miHandler);
    try { Thread.sleep(30);}catch (Exception ex) { ex.printStackTrace();}
    SwingUtilities.invokeLater(doSetDatos);
    } catch (JMSException e)
    System.out.println("Exception in onMessage(): " + e.toString());
    * Description of the Method
    *@param msg Description of the Parameter
    private void creaObjeto(String msg)
    mh = dm.getHandler();
    xmlReader.setContentHandler(mh);
    try
    System.out.println(msg);
    input.setCharacterStream(new StringReader(msg));
    xmlReader.parse(msg);
    }catch(Exception ex){ex.printStackTrace();}
    the exception happens at xmlReader.parse(msg).

  • File Making Directories Problem. java.io.FileNotFoundException

    When ever I run my program it is SUPPOSED to make the directories, instead it tells me the file doesn't exist and fails.
    Here is my Code:
    * To change this template, choose Tools | Templates
    * and open the template in the editor.
    package passworddatamacsetup;
    import java.io.File;
    import java.io.FileInputStream;
    import java.io.FileNotFoundException;
    import java.io.FileOutputStream;
    import java.io.IOException;
    import java.io.InputStream;
    import java.io.OutputStream;
    import java.util.logging.Level;
    import java.util.logging.Logger;
    import javax.swing.JOptionPane;
    * @author jacobgarber
    public class Main {
         * @param args the command line arguments
        public static void main(String[] args) {
            try {
                File PasswordDATA = new File("/Applications/PasswordDATA");
                PasswordDATA.mkdirs();
                File passwords = new File("/Applications/PasswordDATA/PasswordFiles");
                passwords.mkdirs();
                File main = new File("./PasswordDATA_-_MAC.jar");
                File out = new File(PasswordDATA.getPath()+"/PasswordDATA.jar");
                copy(main, PasswordDATA);
                JOptionPane.showMessageDialog(null, "Framework setup complete!", "Completed!", JOptionPane.INFORMATION_MESSAGE);
            } catch(Exception ex) {
                JOptionPane.showMessageDialog(null, ex);
        // Copies src file to dst file.
        // If the dst file does not exist, it is created
        public static void copy(File src, File dst) throws IOException {
            try {
                InputStream in = new FileInputStream(src);
                OutputStream out = new FileOutputStream(dst);
                // Transfer bytes from in to out
                byte[] buf = new byte[1024];
                int len;
                while ((len = in.read(buf)) > 0) {
                    out.write(buf, 0, len);
                in.close();
                out.close();
            } catch (FileNotFoundException ex) {
                JOptionPane.showMessageDialog(null, ex);
    }Here is my exception:
    java.io.FileNotFoundException: /Applications/PasswordDATA

    This looks suspicious:
                File out = new File(PasswordDATA.getPath()+"/PasswordDATA.jar");
                copy(main, PasswordDATA);You probably meant:
                File out = new File(PasswordDATA.getPath()+"/PasswordDATA.jar");
                copy(main, out);

  • [UNEXPECTED] [2275:RT915351] java.io.FileNotFoundException: /tmp/xml/xdo117

    Hi All,
    Currently i am developing RTF template for standard RDF, 'INVOICE PRINT
    SELECTED INVOICES' in AR module.
    After we registered template in oracle applications we tried to run the xml output
    concurrent program (this gives input to template) which gives “Completed and
    Warning”
    And log file shows following error
    [UNEXPECTED] [2275:RT915351] java.io.FileNotFoundException: /tmp/xml/xdo1172562108722.fo (No such file or directory)
    at java.io.FileOutputStream.open(Native Method)
         at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
         at java.io.FileOutputStream.<init>(FileOutputStream.java:131)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:967)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:209)
         at oracle.apps.xdo.template.FOProcessor.createFO(FOProcessor.java:1561)
         at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:951)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.runProcessTemplate(TemplateHelper.java:5975)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.processTemplate(TemplateHelper.java:3555)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.processTemplate(TemplateHelper.java:3614)
         at oracle.apps.fnd.cp.opp.XMLPublisherProcessor.process(XMLPublisherProcessor.java:229)
         at oracle.apps.fnd.cp.opp.OPPRequestThread.run(OPPRequestThread.java:153)
    [2/27/07 2:41:48 AM] [2275:RT915351] Completed post-processing actions for request 915351.
    [2/27/07 2:42:51 AM] [OPPServiceThread0] Post-processing request 915353.
    [2/27/07 2:42:51 AM] [2275:RT915353] Executing post-processing actions for request 915353.
    [2/27/07 2:42:51 AM] [2275:RT915353] Starting XML Publisher post-processing action.
    [2/27/07 2:42:51 AM] [2275:RT915353]
    Template code: CSIT
    Template app: AR
    Language: en
    Territory: US
    Output type: PDF
    could any one help from this problem.
    thanks and regards,
    sai krishna @cavaya.com

    Hi
    Can u please run standalone 'XML report Publisher' concurrent Program .Choose request_id of program which went in warning.
    You can check one thing as well.Check temp directory in Adminstration page of XML Publisher.
    Thanks
    Darshan

  • Java.io.FileNotFoundException: test.txt (The system cannot find the file sp

    Hi All,
    am getting the following error, help me out. Thanks in advance...
    java.io.FileNotFoundException: test.txt (The system cannot find the file specified)
         java.io.FileInputStream.open(Native Method)
         java.io.FileInputStream.<init>(FileInputStream.java:106)
         java.io.FileInputStream.<init>(FileInputStream.java:66)
         BinaryStreamServlet.doGet(BinaryStreamServlet.java:13)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    I have placed "test.txt" in the path"D:\Backup\Tomcat web server\apache-tomcat-6.0.14\webapps\examples\WEB-INF\classes\test.txt".
    web.xml entry is as follows,
    <servlet>
    <servlet-name>demoservlet2</servlet-name>
    <servlet-class>BinaryStreamServlet</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>demoservlet2</servlet-name>
    <url-pattern>/demoservlet2</url-pattern>
    </servlet-mapping>
    Source code:
    import java.io.*;
    import java.net.*;
    import java.io.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    public class BinaryStreamServlet extends HttpServlet{
    public void doGet(HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException{     
    response.setContentType("text/plain"); /* set the MIME type */
         File f= new File("test.txt");
         byte[] arBytes = new byte[(int) f.length()];
         FileInputStream is= new FileInputStream("test.txt");
         is.read(arBytes);
         OutputStream os = response.getOutputStream();
         os.write(arBytes);
         os.flush();
    }

    I have one Drivers.xml file in /WEB-INF that i want to read .but everytime i get exception file not found..
    i m trying to read this xml file in DriverUtilties.java (a non servlet class)
    inside of /WEB-INF/classess folder is there and hierarchy for non-servlet class DriverUtilties is :- com.dds.apps.ptes.pidentifier.admin.util.common.DriverUtilties
    what code shall i write so that i can read the xml file. ???
    where i set in classpath ?
    MYCODE is like this :
    public static final String DEFAULT_FILE = "/WEB-INF/drivers.xml";
    InputStream in = new FileInputStream(DEFAULT_FILE);
    Thanks in advance

  • Java.io.FileNotFoundException: The system cannot find the path specified

    hi all.
    have this problem
    i have a jsp with the codes as follows:
    try{
    File f=new File("C:/Program Files/Apache Group/Tomcat 4.1/webapps/iiso/account.xml");
    FileWriter fw=new FileWriter(f,false);
    XMLConverter xmlc=new XMLConverter();
    String msg=xmlc.ConvertToXML("account");
    fw.write(msg);
    fw.flush();
    System.out.println("file printed");
    }catch(IOException ioe)
    System.out.println(ioe);
    }it works prefectly on my comp but however when i posted it up on the dev server
    which is running on tomcat 4.0
    i got this error:
    java.io.FileNotFoundException: P:\Program Files\Apache Tomcat 4.0\webapps\IISOelearn\account.xml (The system cannot find the path specified)
    the dev server is running on P drive.
    tried installing tomcat 4.0 on my com and the code runs well.
    could there be other sources tt i miss out causing the error?
    many thanx in advance!
    =)

    Most probably the server has a different path setup from you.
    Instead of hardcoding the full file path into your app, you should have the following
    ServletContext application = getServletConfig().getServletContext();
    String fileName = application.getRealPath("/account.xml");
    File f = new File(fileName);The method ServletContext.getRealPath takes a WEBSITE relative link, and turns it into a real location on disk.
    This makes your code completely independant of what machine it is installed on.
    Cheers,
    evnafets

  • Java.io.FileNotFoundException: C:\Blazix\ejbtemp\pack1\JellyBeanCtx_Skel.cl

    Dear all,
    I am using Blazix server, when i executing third command in the build file , i got this exception , so now i am unable to create EJB jar , please send me reply for this doubt
    D:\mania\java\kum>blxejbc Jelly.jar JellyEjb.jar
    Blazix EJB Compiler 1.2
    Copyright (C) Desiderata Software, 2001-2006
    All rights reserved
    Configuration file: C:\Blazix\ejb.ini
    JRMP Version
    Processing Session bean "Jelly"
    Validating bean classes
    Generating bean support classes
    Jelly: Compiling classes with javac
    Jelly: Generating RMI classes
    Jelly: Adding to JAR file JellyEjb.jar
    java.io.FileNotFoundException: C:\Blazix\ejbtemp\pack1\JellyBeanCtx_Skel.class (
    The system cannot find the file specified)
    at java.io.FileInputStream.open(Native Method)
    at java.io.FileInputStream.<init>(Unknown Source)
    at desisoft.ejbtools.EjbCompiler.addZipEntry(EjbCompiler.java:79)
    at desisoft.ejbtools.EjbCompiler.compileAndAddToJar(EjbCompiler.java:133
    8)
    at desisoft.ejbtools.EjbCompiler.compileBeans(EjbCompiler.java:449)
    at desisoft.ejbtools.EjbCompiler.compile(EjbCompiler.java:224)
    at desisoft.ejbtools.EjbCompiler.main(EjbCompiler.java:1513)

    how can we know the third command in your build file unless you put the build file here???

  • Java.io.FileNotFoundException (Too many file open)

    Hi,
    I have an application wherein I have to open an XMl file, make amends to it and then write it back. It is possible that the same XML file be opened more than once. After processing lots of XMl files I get the following error:
    [java] java.io.FileNotFoundException: /nas/bansalp/app/databases/databases/IntActe_human_528_psimi.xml (Too many open files)
         [java]      at java.io.FileInputStream.open(Native Method)
         [java]      at java.io.FileInputStream.<init>(FileInputStream.java:106)
         [java]      at java.io.FileInputStream.<init>(FileInputStream.java:66)
         [java]      at sun.net.www.protocol.file.FileURLConnection.connect(FileURLConnection.java:70)
         [java]      at sun.net.www.protocol.file.FileURLConnection.getInputStream(FileURLConnection.java:161)
         [java]      at com.sun.org.apache.xerces.internal.impl.XMLEntityManager.setupCurrentEntity(XMLEntityManager.java:653)
         [java]      at com.sun.org.apache.xerces.internal.impl.XMLVersionDetector.determineDocVersion(XMLVersionDetector.java:186)
         [java]      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:771)
         [java]      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:737)
         [java]      at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:107)
         [java]      at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:225)
         [java]      at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:283)
         [java]      at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:208)
         [java]      at alliance.dps.Commons.makedocument(Unknown Source)Code for makedocument is as follows:
    public static Document makedocument(File file) throws Exception
      Document response = null;
      DocumentBuilder builder = null;
      try
         DocumentBuilderFactory builderFactory = DocumentBuilderFactory.newInstance();
         builder  = builderFactory.newDocumentBuilder();
         if (file==null)
          response = builder.newDocument();
         else
          response = builder.parse(file);
      catch(Exception e) { e.printStackTrace(); }
      return response;
    }Here also I am not explicitely opening any handle. parse method should close the file after creating a DOM tree.
    I would appreciate if someone could give me some directions as to what might be wrong.
    - Parit

    I'm finding that builder.parse(File) doesn't close the file. I now create a FileInputStream from the File and make sure I close it myself in a finally{} block.

Maybe you are looking for

  • JComboBox drops up instead of down!

    I have a JComboBox in a JMenuBar at the top of my JPanel. I have some items in the JComboBox. When I click on the arrow to view the elements, the display window goes up instead of down. Thus, I can only see one item since all the others are our of th

  • Problems with apps and safari since installing Yosemite

    I could have shot myself after installing Maverick when it cam out but after a zillion updates and finally a 100 mile drive to the nearest Apple store and the genius bar it seemed to be working fine.  I dreaded installing Yosemite but as I have and i

  • Query in SAPKKA12 - taking long time

    Hi, The following query is from program SAPKKA12 and taking a long time to run . Any inputs how can I  optimize it? Will index creation on VBAP help?   SELECT vbeln                                                               posnr                  

  • Mapping a CASE constraint gives error:The expression is not properly formed

    Hi I am hoping someone can help us with this as we cannot find it in the usual places: I have the following WHERE clause in my query: WHERE xd.cii_owner_account_id = hca.cust_account_id AND incidentb.incident_status_id = incident_status.incident_stat

  • Apparent Permissions problem

    I have a new iMac 27" which of course came with Yosemite and has been updated through Software Update.  I have a disk drive attached, which used to be attached with no problems to my previous iMac, running 10.9. Whenever I run a program that wants to