JDev 9.0.3_2: web.xml fails DTD validation

Hi all,
I just started using JDev 9.0.3_2 and found that it is trying to validate my web.xml when I build my Project.
It is complaining about the <distributable> Tag inside my web.xml file. It should NOT be complaining about this, but it is obviously using either an outdated DTD or the wrong one.
How can I either point JDev at the correct DTD or get it to stop attemting to validate web.xml?
Thanks!
Kevin Dougan

I think I have figured out a workaround: It appears that JDeveloper is extremely picking about web.xml and validates it in a strict sense. You MUST put your elements in EXACTLY the same order as specified in the DTD, or it throws an error.
However, that doesn't answer my original question: Is there a way to specify the DTD for web.xml (or other elements for that matter, Schema's aside for the moment) or at least turn off this form of validation? If not in the current release, is this coming in 9.0.4 or 9.0.5?
Thanks again,
Kevin

Similar Messages

  • XML SAX dtd Validation Problem

    Hi,
              I’m having problems getting an xml document to validate within Weblogic 8.1. I am trying to parse a document that references both a dtd and xsd. Both the schema and dtd reference need to be substituted so they use local paths. I specify the schema the parser should use and have created an entityResolver to change the dtd reference.
              When this runs as a standalone app from eclipse the file parses and validates without a problem. When deployed to the app server the process seems to be unable read the contents of the dtd. Its not that it cannot find the file (no FileNotFoundException is thrown but this can be created if I delete the dtd) rather it seems to find no declared elements.
              Initial thought was that the code didn’t have access to read the dtd from its location on disk, to check I moved the dtd to within the deployed war and reference as a resource. The problem still persists.
              Code Snippet:
              boolean isValid = false;
              try {
              // Create and configure factory
              SAXParserFactory factory = SAXParserFactoryImpl.newInstance();
              factory.setValidating(true);
              factory.setNamespaceAware(true);
              // To be notified of validation errors in the XML document,
              // add a custom error handler to the document builder
              PIMSFeedFileValidationHandler handler
              = new PIMSFeedFileValidationHandler();
              // Create and Configure Parser
              SAXParser parser = factory.newSAXParser();
              parser.setProperty(JAXP_SCHEMA_LANGUAGE, W3C_XML_SCHEMA);
              parser.setProperty(NAMESPACE_PROPERTY_KEY, getSchemaFilePath());
              // Set reader with entityResolver for dtd
              XMLReader xmlReader = parser.getXMLReader();
              xmlReader.setEntityResolver(new SAXEntityResolver(this.dtdPath));
              // convert file to URL, as it is a remote file
              URL url = super.getFile().toURL();
              // Open an input stream and parse
              InputStream is = url.openStream();
              xmlReader.setErrorHandler(handler);
              xmlReader.parse(new InputSource(is));
              is.close();
              // get the result of parsing the document by checking the
              // errorhandler's isValid property
              isValid = handler.isValid();
              if (!isValid) {
              LOGGER.warn(handler.getMessage());
              LOGGER.debug("XML file is valid XML? " + isValid);
              } catch (ParserConfigurationException e) {
              LOGGER.error("Error parsing file", e);
              } catch (SAXException e) {
              LOGGER.error("Error parsing file", e);
              } catch (IOException e) {
              throw new FeedException(e);
              return isValid;
              See stack trace below for a little more info.
              2005-01-28 10:24:09,217 [DEBUG] [file] - Attempting validation of file 'cw501205.wa1.xml' with schema at 'C:/pims-feeds/hansard/schema/hansard-v1-9.xsd'
              2005-01-28 10:24:09,217 [DEBUG] [file] - Entity Resolver is using DTD path file:C:/Vignette/runtime_services/8.1/install/common/nodemanager/
              VgnVCMServer/stage/pims-hansard/pims-hansard.war/WEB-INF/classes/com/morse/pims/cms/feed/sax/ISO-Entities.dtd
              2005-01-28 10:24:09,227 [DEBUG] [file] - Creating InputSource at: file:C:/Vignette/runtime_services/8.1/install/common/nodemanager/VgnVCMServer/stage/pims-hansard/pims-hansard.war/WEB-INF/classes/com/morse/pims/cms/feed/sax/ISO-Entities.dtd
              2005-01-28 10:24:09,718 [WARN ] [file] - org.xml.sax.SAXParseException: Element type "Hansard" must be declared.
              org.xml.sax.SAXParseException: Element type "Session" must be declared.
              org.xml.sax.SAXParseException: Element type "DailyRecord" must be declared.
              org.xml.sax.SAXParseException: Element type "Volume" must be declared.
              org.xml.sax.SAXParseException: Element type "Written" must be declared.
              org.xml.sax.SAXParseException: Element type "WrittenHeading" must be declared.
              org.xml.sax.SAXParseException: Element type "Introduction" must be declared.
              … continues for all the elements in the doc
              2005-01-28 10:24:10,519 [DEBUG] [file] - XML file is valid XML? false
              2005-01-28 10:24:10,519 [WARN ] [file] - Daily Part file 'cw501205.wa1.xml' was not valid XML and was not processed.
              Has anybody seen this behavior before with weblogic and if so how have you resolved the issue.
              Thanks in Advance
              Adam

    It looks like you clicked on "Post" before you got around to explaining your problem. I don't see any error messages or any description of what was supposed to happen and what happened instead.
    Now, I don't know anything about XML Schema, but just guessing at how that unique name feature might be designed, and just guessing that your unique name is actually in the <userId> element, I would suggest that this:
    <xsd:unique name="un_name"> 
      <xsd:selector xpath="USER"/> 
      <xsd:field xpath="."/> 
    </xsd:unique> is at fault because it doesn't mention the <userId> element anywhere.

  • How to disable XML´s DTD validation in Weblogic10?

    Hello folks, we are trying to upgrade our server to Weblogic10, but it´s XML parser is validating XML´s DTD and ´cause we are behind a firewall we receive a error like:
    Tried all: ´6´ address, but could not connect over HTTP to server: 'www.w3.org', port: '80'
    Does anyone here known how to disable DTD validation in WL10?
    Regards,
    lottalava

    Well you can create non validating parser programatically .
    http://edocs.bea.com/wls/docs100/xml/programming.html#wp1069856
    i.e.
    SAXParserFactory spf = SAXParserFactory.newInstance();
    spf.setValidating(false);
    Hope this helps.

  • SAXParseException in web.xml, not allowing the env-entry tag?????

              Dears, I have a WLS 5.1 sp6, and added a
              weblogic.httpd.webApp.demowar=/temp/alphaworks/servlet/demo_feat.war
              in weblogic.properties, and when I start the weblogic server occuring
              [ServletEntityResolver] : Could not resolve entity '-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN'. Check your
              dtd reference.
              ..<HTTP> Error parsing descriptor in Web application '/temp/alphaworks/servlet/demo_feat.war'
              org.xml.sax.SAXParseException: Element "web-app" does not allow "env-entry" here.
                   at com.sun.xml.parser.Parser.error(Parser.java:2775)
              --------------- nested within: ------------------
              Received SAXParseException from Sun Parser at line 283, column -1: org.xml.sax.SAXParseException: Element "web-app" does not allow "env-entry" here.
                   at weblogic.xml.dom.SunDOMParser.getDocument(SunDOMParser.java:72)
              Wed Dec 06 18:50:17 GMT-02:00 2000:<E> <HTTP> Error creating servlet context for Web application '/temp/alphaworks/servlet/demo_feat.war'
              java.lang.NullPointerException
                   at weblogic.t3.srvr.HttpServer.initServletContexts(HttpServer.java:626)
              any other default servlet (that comes with weblogic) works fine, and this .war runs good in
              Orion 1.4.4, adn J2EE RI 1.2.1 !
              in web.xml the dtd is from java.sun.com, and I chaged to http://localhost/servlet_2_2.dtd (where the url is fine, because I can download).
              

    Double-check the DTD. WebLogic likes the XML to be in the same exact order
              as found in the DTD.
              Peace,
              Cameron Purdy
              Tangosol, Inc.
              http://www.tangosol.com
              +1.617.623.5782
              WebLogic Consulting Available
              "Claudio" <[email protected]> wrote in message
              news:[email protected]...
              >
              > Dears, I have a WLS 5.1 sp6, and added a
              >
              > weblogic.httpd.webApp.demowar=/temp/alphaworks/servlet/demo_feat.war
              >
              > in weblogic.properties, and when I start the weblogic server occuring
              >
              > [ServletEntityResolver] : Could not resolve entity '-//Sun Microsystems,
              Inc.//DTD Web Application 2.2//EN'. Check your
              > dtd reference.
              >
              > ..<HTTP> Error parsing descriptor in Web application
              '/temp/alphaworks/servlet/demo_feat.war'
              > org.xml.sax.SAXParseException: Element "web-app" does not allow
              "env-entry" here.
              > at com.sun.xml.parser.Parser.error(Parser.java:2775)
              > .
              > .
              > .
              >
              > --------------- nested within: ------------------
              > Received SAXParseException from Sun Parser at line 283, column -1:
              org.xml.sax.SAXParseException: Element "web-app" does not allow "env-entry"
              here.
              > at weblogic.xml.dom.SunDOMParser.getDocument(SunDOMParser.java:72)
              > .
              > .
              > .
              >
              > Wed Dec 06 18:50:17 GMT-02:00 2000:<E> <HTTP> Error creating servlet
              context for Web application '/temp/alphaworks/servlet/demo_feat.war'
              > java.lang.NullPointerException
              > at weblogic.t3.srvr.HttpServer.initServletContexts(HttpServer.java:626)
              >
              > any other default servlet (that comes with weblogic) works fine, and this
              .war runs good in
              > Orion 1.4.4, adn J2EE RI 1.2.1 !
              >
              > in web.xml the dtd is from java.sun.com, and I chaged to
              http://localhost/servlet_2_2.dtd (where the url is fine, because I can
              download).
              >
              >
              

  • JDev 10.1.3 compile error in servlet 2.4 web.xml

    I built a Servlet 2.4/JSP 2.0 application in JDev 10.1.3. When I try to make/compile/deploy it the compiler gives me errors like the following for every JSP file that has a JSTL 1.1 taglib:
    Error(2,9): Element "web-app' used but not declared
    Error(2,63): Attribute 'xmlns:xsi' used but not declared
    Error(3,103): Attribute 'xsi:schemaLocation' used but not declared
    Error(4,16): Attribute 'version' used but not declared
    Error(4,56): Attribute 'xmlns' used but not declared
    Error(4,57): Can not build schema 'http://java.sun.com/xml/ns/j2ee' located at 'http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd'
    Error(5,15): Element 'description used but not declared
    It is obviously havng problems with the web.xml file (which is in the servlet 2.4 format) and is probably not finding the web.xml DTD document. How do I fix it?
    Installation is on Solaris 9 using J2SDK 1.4.2_04-b05
    By the way, this system is on a disconnected network. How do I get JDeveloper updates for a system not connected to the Internet?

    Allen,
    A JSP with web.xml web-app element
    <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">
    runs in JDeveloper 10.1.3
    thanks,
    Deepak

  • Unmarshaller failed for web.xml - weblogic 8.1 to weblogic 9.2

    Hi ,
    I am also getting the same Unmarshaller Failed Exception as given below.
    Unable to load descriptor myapplication\app.ear\app.war/WEB-INF/web.xml of module app.war . The error is weblogic.descriptor.DescriptorException: Unmarshaller failed.....
    Please let me know
    Thanks in advance
    I verified that there is no duplicate entry in web.xml
    Binu
    I am atatching the error log
    <Aug 8, 2006 12:55:47 PM IST> <Error> <J2EE> <BEA-160197> <Unable to load descriptor \app.ear\app.w
    ar/WEB-INF/web.xml of module app.war. The error is weblogic.descriptor.DescriptorException: Unmarshaller failed
    at weblogic.descriptor.internal.MarshallerFactory$1.createDescriptor(MarshallerFactory.java:147)
    at weblogic.descriptor.DescriptorManager.createDescriptor(DescriptorManager.java:280)
    at weblogic.descriptor.DescriptorManager.createDescriptor(DescriptorManager.java:248)
    at weblogic.application.descriptor.AbstractDescriptorLoader2.getDescriptorBeanFromReader(AbstractDescriptorLoader2.jav
    a:749)
    at weblogic.application.descriptor.AbstractDescriptorLoader2.createDescriptorBean(AbstractDescriptorLoader2.java:376)
    at weblogic.application.descriptor.AbstractDescriptorLoader2.loadDescriptorBeanWithoutPlan(AbstractDescriptorLoader2.j
    ava:720)
    at weblogic.application.descriptor.AbstractDescriptorLoader2.loadDescriptorBean(AbstractDescriptorLoader2.java:729)
    at weblogic.servlet.internal.WebAppDescriptor.getWebAppBean(WebAppDescriptor.java:134)
    at weblogic.application.compiler.WARModule.processLibraries(WARModule.java:286)
    at weblogic.application.compiler.WARModule.merge(WARModule.java:303)
    at weblogic.application.compiler.flow.MergeModuleFlow.compile(MergeModuleFlow.java:23)
    at weblogic.application.compiler.FlowDriver$FlowStateChange.next(FlowDriver.java:69)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
    at weblogic.application.compiler.FlowDriver.nextState(FlowDriver.java:36)
    at weblogic.application.compiler.FlowDriver$CompilerFlowDriver.compile(FlowDriver.java:96)
    at weblogic.application.compiler.ReadOnlyEarMerger.merge(ReadOnlyEarMerger.java:41)
    at weblogic.application.compiler.flow.AppMergerFlow.mergeInput(AppMergerFlow.java:94)
    at weblogic.application.compiler.flow.AppMergerFlow.compile(AppMergerFlow.java:47)
    at weblogic.application.compiler.FlowDriver$FlowStateChange.next(FlowDriver.java:69)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
    at weblogic.application.compiler.FlowDriver.nextState(FlowDriver.java:36)
    at weblogic.application.compiler.FlowDriver$CompilerFlowDriver.compile(FlowDriver.java:96)
    at weblogic.application.compiler.AppMerge.runBody(AppMerge.java:130)
    at weblogic.utils.compiler.Tool.run(Tool.java:158)
    at weblogic.utils.compiler.Tool.run(Tool.java:115)
    at weblogic.application.compiler.AppMerge.merge(AppMerge.java:142)
    at weblogic.deploy.api.internal.utils.AppMerger.merge(AppMerger.java:70)
    at weblogic.deploy.api.internal.utils.AppMerger.getMergedApp(AppMerger.java:51)
    at weblogic.deploy.api.model.internal.WebLogicDeployableObjectFactoryImpl.createDeployableObject(WebLogicDeployableObj
    ectFactoryImpl.java:177)
    at weblogic.deploy.api.model.internal.WebLogicDeployableObjectFactoryImpl.createLazyDeployableObject(WebLogicDeployabl
    eObjectFactoryImpl.java:150)
    at weblogic.deploy.api.tools.SessionHelper.inspect(SessionHelper.java:629)
    at com.bea.console.actions.app.install.Flow.appSelected(Flow.java:450)
    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 org.apache.beehive.netui.pageflow.FlowController.invokeActionMethod(FlowController.java:869)
    at org.apache.beehive.netui.pageflow.FlowController.getActionMethodForward(FlowController.java:808)
    at org.apache.beehive.netui.pageflow.FlowController.internalExecute(FlowController.java:477)
    at org.apache.beehive.netui.pageflow.PageFlowController.internalExecute(PageFlowController.java:305)
    at org.apache.beehive.netui.pageflow.FlowController.execute(FlowController.java:335)
    at org.apache.beehive.netui.pageflow.internal.FlowControllerAction.execute(FlowControllerAction.java:51)
    at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:419)
    at org.apache.beehive.netui.pageflow.PageFlowRequestProcessor.access$201(PageFlowRequestProcessor.java:95)
    at org.apache.beehive.netui.pageflow.PageFlowRequestProcessor$ActionRunner.execute(PageFlowRequestProcessor.java:2042)
    at org.apache.beehive.netui.pageflow.interceptor.action.internal.ActionInterceptors$WrapActionInterceptorChain.continu
    eChain(ActionInterceptors.java:63)
    at org.apache.beehive.netui.pageflow.interceptor.action.ActionInterceptor.wrapAction(ActionInterceptor.java:167)
    at org.apache.beehive.netui.pageflow.interceptor.action.internal.ActionInterceptors$WrapActionInterceptorChain.invoke(
    ActionInterceptors.java:49)
    at org.apache.beehive.netui.pageflow.interceptor.action.internal.ActionInterceptors$WrapActionInterceptorChain.continu
    eChain(ActionInterceptors.java:57)
    at org.apache.beehive.netui.pageflow.interceptor.action.internal.ActionInterceptors.wrapAction(ActionInterceptors.java
    :86)
    at org.apache.beehive.netui.pageflow.PageFlowRequestProcessor.processActionPerform(PageFlowRequestProcessor.java:2114)
    at com.bea.console.internal.ConsolePageFlowRequestProcessor.processActionPerform(ConsolePageFlowRequestProcessor.java:
    221)
    at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:224)
    at org.apache.beehive.netui.pageflow.PageFlowRequestProcessor.processInternal(PageFlowRequestProcessor.java:554)
    at org.apache.beehive.netui.pageflow.PageFlowRequestProcessor.process(PageFlowRequestProcessor.java:851)
    at org.apache.beehive.netui.pageflow.AutoRegisterActionServlet.process(AutoRegisterActionServlet.java:630)
    at org.apache.beehive.netui.pageflow.PageFlowActionServlet.process(PageFlowActionServlet.java:157)
    at com.bea.console.internal.ConsoleActionServlet.process(ConsoleActionServlet.java:241)
    at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)
    at com.bea.console.internal.ConsoleActionServlet.doGet(ConsoleActionServlet.java:130)
    at org.apache.beehive.netui.pageflow.PageFlowUtils.strutsLookup(PageFlowUtils.java:1169)
    at com.bea.portlet.adapter.scopedcontent.ScopedContentCommonSupport.executeAction(ScopedContentCommonSupport.java:688)
    at com.bea.portlet.adapter.scopedcontent.ScopedContentCommonSupport.processActionInternal(ScopedContentCommonSupport.j
    ava:144)
    at com.bea.portlet.adapter.scopedcontent.PageFlowStubImpl.processAction(PageFlowStubImpl.java:107)
    at com.bea.portlet.adapter.NetuiActionHandler.raiseScopedAction(NetuiActionHandler.java:99)
    at com.bea.netuix.servlets.controls.content.NetuiContent.raiseScopedAction(NetuiContent.java:180)
    at com.bea.netuix.servlets.controls.content.NetuiContent.raiseScopedAction(NetuiContent.java:168)
    at com.bea.netuix.servlets.controls.content.NetuiContent.handlePostbackData(NetuiContent.java:222)
    at com.bea.netuix.nf.ControlLifecycle$2.visit(ControlLifecycle.java:178)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:351)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walkRecursive(ControlTreeWalker.java:361)
    at com.bea.netuix.nf.ControlTreeWalker.walk(ControlTreeWalker.java:128)
    at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:361)
    at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:339)
    at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:330)
    at com.bea.netuix.nf.Lifecycle.runInbound(Lifecycle.java:162)
    at com.bea.netuix.nf.Lifecycle.run(Lifecycle.java:137)
    at com.bea.netuix.servlets.manager.UIServlet.runLifecycle(UIServlet.java:370)
    at com.bea.netuix.servlets.manager.UIServlet.doPost(UIServlet.java:229)
    at com.bea.netuix.servlets.manager.UIServlet.service(UIServlet.java:183)
    at com.bea.netuix.servlets.manager.SingleFileServlet.service(SingleFileServlet.java:221)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
    at weblogic.servlet.AsyncInitServlet.service(AsyncInitServlet.java:124)
    at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:225)
    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:127)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:283)
    at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
    at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:26)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3212)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:1983)
    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:1890)
    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1344)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)
    Caused by: com.bea.xml.XmlException: weblogic.descriptor.BeanAlreadyExistsException: Bean already exists: "weblogic.j2ee.descr
    iptor.ServletBeanImpl@bb49014(/Servlets[navigationTree])"
    at com.bea.staxb.runtime.internal.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:54)
    at com.bea.staxb.runtime.internal.RuntimeBindingType$BeanRuntimeProperty.setValue(RuntimeBindingType.java:483)
    at com.bea.staxb.runtime.internal.AttributeRuntimeBindingType$QNameRuntimeProperty.fillCollection(AttributeRuntimeBind
    ingType.java:385)
    at com.bea.staxb.runtime.internal.MultiIntermediary.getFinalValue(MultiIntermediary.java:52)
    at com.bea.staxb.runtime.internal.AttributeRuntimeBindingType.getFinalObjectFromIntermediary(AttributeRuntimeBindingTy
    pe.java:145)
    at com.bea.staxb.runtime.internal.UnmarshalResult.unmarshalBindingType(UnmarshalResult.java:185)
    at com.bea.staxb.runtime.internal.UnmarshalResult.unmarshalDocument(UnmarshalResult.java:154)
    at com.bea.staxb.runtime.internal.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:65)
    at weblogic.descriptor.internal.MarshallerFactory$1.createDescriptor(MarshallerFactory.java:136)
    ... 123 more
    Caused by: weblogic.descriptor.BeanAlreadyExistsException: Bean already exists: "weblogic.j2ee.descriptor.ServletBeanImpl@bb49
    014(/Servlets[navigationTree])"
    at weblogic.descriptor.internal.ReferenceManager.registerBean(ReferenceManager.java:207)
    at weblogic.j2ee.descriptor.WebAppBeanImpl.setServlets(WebAppBeanImpl.java:1096)
    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.bea.staxb.runtime.internal.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:48)
    ... 131 more
    .>
    Thanks
    Binu

    Thanks Rob for youir response.
    I had actually duplicate url pattern entry in web.xml.
    Now I am facing an issue with security principal.
    I am getting anoynymous principal for the sessionContext.getCallerPrincipal() .
    I am using the same security module which used to work with weblogic 8.1 (I have generated respctive jar file with 9.2 jar though and I could configure a new provider)
    Any thoughts on this?
    Thanks
    Binu

  • JDev 10.1.3 Preview Create orion-web.xml Problem

    When I use JDev 10.1.3 to create an orion-web.xml file, it generates something like this:
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <orion-web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://xmlns.oracle.com/oracleas/schema/orion-web-10_0.xsd" schema-major-version="10" schema-minor-version="0" servlet-webdir="/servlet/"/>
    Shouldn't it create something without the closing "/>" marker on the <orion-web-app> line?
    9.0.5 did something like:
    <orion-web-app servlet-webdir="/servlet/">
    </orion-web-app>

    If the orion-web-app element does not have sub-elements
    <orion-web-app servlet-webdir="/servlet/"/>
    is equivalent to
    <orion-web-app servlet-webdir="/servlet/">
    </orion-web-app>

  • JDev 10g - Security - web.xml - URL pattern matching

    Hello,
    I use JDeveloper 10.1.3.4. It's 4 hours I try to figure out what is going on:
    I set security constraint in web.xml:
    &lt;security-constraint&gt;
    &lt;web-resource-collection&gt;
    &lt;web-resource-name&gt;books&lt;/web-resource-name&gt;
    &lt;url-pattern&gt;faces/app/books/*&lt;/url-pattern&gt;
    &lt;url-pattern&gt;faces/*/app/books/*&lt;/url-pattern&gt;
    &lt;/web-resource-collection&gt;
    &lt;auth-constraint&gt;
    &lt;role-name&gt;books&lt;/role-name&gt;
    &lt;/auth-constraint&gt;
    &lt;/security-constraint&gt;
    User is logged in with role "books" for sure.
    http://192.168.0.109:8988/lib/faces/app/books/page.jspx can be seen
    but dialogs can't be seen, url is : http://192.168.0.109:8988/lib/faces/__ADFv__?_afPfm=1.5&_t=fred&_vir=/app/books/Search.jspx&loc=en&_rtrnId=2it redirects to login page.
    Another thing, when I set only one url pattern : faces/app/books/*.jspx
    I can't even see faces/app/books/page.jspx page!
    It's very curious, have to be something else somewhere to set, because in SRDemo app this 2 cases don't cause problems.
    Bart
    snowface.net - snowboard equipement reviews

    Hi,
    dialogs are not opened by a GET request, which is what container managed authorization looks at. It basically bypasses this kind of security, which means that developers should check manually on teh command component that launches teh dialog if the authenticated user is allowed to do this. Also note that the default JSfnavigation is by postback which means you have to set all navigation to use the redirect flag to make it work with container managed security
    Frank

  • Error while deploying in web.xml with web-app_2_5.xsd

    Weblogic version 10.3.5 and java is 1.6.0_31
    context root is - "/" (slash)
    Web.xml - old
    has following declaration and works fine
    <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
    <web-app>
    i am trying to change web.xml's web-app definition as below
    Web.xml - new
    <web-app xmlns="http://java.sun.com/xml/ns/javaee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
         version="2.5">
    and to accommodate above change i enclosed all "tag libs" inside <jsp-config> tag which is as per 2.5
    when i try to deploy with above changes, i am getting following error but with old definition i am not getting any error.
    <Error> <Deployer> <clbblr-4423> <StoreFront> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1358234763292> <BEA-149205> <Failed to initialize the application 'shopstr' due to error weblogic.application.ModuleException: Failed to load webapp: '/'.
    weblogic.application.ModuleException: Failed to load webapp: '/'
         at weblogic.servlet.internal.WebAppModule.prepare(WebAppModule.java:393)
         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:613)
    Caused By: java.lang.ClassNotFoundException: atg.web.tagsupport.CollectionTagSupport
         at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:297)
         at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:270)
         at weblogic.utils.classloaders.ChangeAwareClassLoader.findClass(ChangeAwareClassLoader.java:64)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
         at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClassLoader.java:179)
         at weblogic.utils.classloaders.ChangeAwareClassLoader.loadClass(ChangeAwareClassLoader.java:43)
         at java.lang.ClassLoader.defineClass1(Native Method)
    Would appreciate suggestions. Thanks

    added JAR file pwsTaglib2_0.jar and now problems are resolved. will open this thread if i see any other error

  • Web.xml clarification

    Hello,
    in a servlet we would like to read web.xml sections which are not accessible through the servlet/context-getParameter methods. So we wrote a utility to get access to these elements. The problem is, that we receive an error, if the parser has no access to the DTD defined in the DOCUMENT section of the web.xml file (which is normal in an intranet).
    Error: javax.xml.parsers.DocumentBuilder.parse(Unknown Source)
    If we remove the DOCUMENT part then the parser works correctly but the application does not start and we receive
    SAXParseException: Element type "web-app" must be declared.
    We do not get this error even if there is no access to the Internet!!! How does the application server handle this situation?
    Question: What is the usual proceeding
    a) make a copy of the DTD file and store it locally?
    b) is it possible to switch the validation off (I tried this and failed code below).
    Any suggestions and clarifications welcome.
    Regards, Rainer
    ----------------------- code snippet ------------------------
    DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
    factory.setIgnoringComments(true); //No need for comments
    factory.setIgnoringElementContentWhitespace(true); //No need for WS
    factory.setNamespaceAware(true); //No need for Namespaces
    factory.setValidating(false); //No need for DTD ??????? DocumentBuilder builder = factory.newDocumentBuilder();
    Document document = builder.parse( FileName );

    You've added these to a <servlet> element right? And I'm assuming that this isnt' your servlet or you'd have seen them being used in the code.
    Basically, they're initialization parameters that are passed to your servlet via the ServletConfig object and which you can access.
    For example, you could define your DB URL ( though that would probably be better off as a <context-param> instead ) here, in your web.xml and then use the string in your servlet instead of hardcoding it. This way, changes would be easier.
    In your case, you're adding two parameters, debug=3 and detail=3. When you use ServletConfig.getInitParameter("debug") or ServletConfig.getInitParameter("detail"), you'll get values of 3 and 3.

  • Editing web.xml OR weblogic.xml programmatically

    Hi there,
    I am trying to edit the web.xml and weblogic.xml programmatically. I am trying to load the above deployment descriptors in DOM object. But as DTD is mentioned externally, connection to URL is failing.
    But weblogic.jar contains all DTD in local machine. Is there any way to make parser to refer DTD in weblogic.jar. Or any weblogic API available to edit the deployment descriptors programatically.
    Thanks in advance.
    I am getting following error.
    java.net.ConnectException: Connection timed out: connect
    at java.net.PlainSocketImpl.socketConnect(Native Method)
    at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:305)
    at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:171)
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:158)
    at java.net.Socket.connect(Socket.java:452)
    at java.net.Socket.connect(Socket.java:402)
    at sun.net.NetworkClient.doConnect(NetworkClient.java:139)
    at sun.net.www.http.HttpClient.openServer(HttpClient.java:402)
    at sun.net.www.http.HttpClient.openServer(HttpClient.java:618)
    at sun.net.www.http.HttpClient.<init>(HttpClient.java:306)
    at sun.net.www.http.HttpClient.<init>(HttpClient.java:267)
    at sun.net.www.http.HttpClient.New(HttpClient.java:339)
    at sun.net.www.http.HttpClient.New(HttpClient.java:320)
    at sun.net.www.http.HttpClient.New(HttpClient.java:315)
    at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConne
    ction.java:512)
    at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection
    .java:489)
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLCon
    nection.java:617)
    at java.net.URL.openStream(URL.java:913)
    at weblogic.apache.xerces.impl.XMLEntityManager.startEntity(XMLEntityMan
    ager.java:836)
    at weblogic.apache.xerces.impl.XMLEntityManager.startDTDEntity(XMLEntity
    Manager.java:796)
    at weblogic.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(XMLDTDSc
    annerImpl.java:275)
    at weblogic.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.disp
    atch(XMLDocumentScannerImpl.java:841)
    at weblogic.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocume
    nt(XMLDocumentFragmentScannerImpl.java:329)
    at weblogic.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguratio
    n.java:525)
    at weblogic.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguratio
    n.java:581)
    at weblogic.apache.xerces.parsers.XMLParser.parse(XMLParser.java:152)
    at weblogic.apache.xerces.parsers.DOMParser.parse(DOMParser.java:257)
    at weblogic.apache.xerces.jaxp.DocumentBuilderImpl.parse(DocumentBuilder
    Impl.java:201)
    at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:151)
    at JAXPandDOM.main(JAXPandDOM.java:39)

    I believe you could get around this with a custom EntityResolver. It's possible that Tomcat does something like this.
    However, I would question why you are trying to do this. If your container is set to Development mode, you might get away with the container automatically reloading your changes, but it certainly won't happen in Production mode, and even in Development mode, I don't know that I could predict how that would work.
    You'd be better off, with respect to portability and flexibility, if you store dynamic resources in an external file, not in the web.xml or weblogic.xml file. You could have a timed "watcher" for the file, to see when it's modified.

  • Orion-web.xml -- web-app-class-loader

    Hi all, I posted this in the jDeveloper section and someone suggested that I ask you guys what the importance of the orion-web.xml file is. Currently my files looks like ...
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <!DOCTYPE orion-web-app PUBLIC "-//Evermind//DTD Orion Web Application 2.3//EN" "http://xmlns.oracle.com/ias/dtds/orion-web.dtd">
    <orion-web-app servlet-webdir="/servlet/">
    </orion-web-app>
    But it keeps adding the line that I mention below...
    I have a system that consists of multiple projects. When I deploy all projects they all work fine except for one. We discovered that this is due to the following line in the orion-web.xml file in that project ....
    <web-app-class-loader search-local-classes-first="true"/>
    I removed that line and everything is now fine. However, whenever I open up the application in jDev is puts that line back (even if I don't make changes).
    Is there a setting somewhere that is forcing this line to be put there and, if so, why? And how do I switch it off?
    Thanks,
    Russell

    Hey Steve,
    I must admit that this post confused me a bit.
    I can find no deployment plan editor. We have a WAR Deployment Profile, an EAR Deployment Profile and an EJB JAR Deplyment Profile.
    I use the debug functionality (using the embedded OC4J) to test the application locally during development and then deply the EAR Deployment Profile to an EAR file which then gets deployed using an Application Server.
    Further to this I have tried deleting the file (from everywhere), changing the EAR Deployment Properties and even changing the code within the ORION-WEB.XML to say <web-app-class-loader search-local-classes-first="false"/> all to no avail.
    If I remove the file completed, it add its back when I reopen the project. If I change it to false, it changes it back to True.
    Very confused I must admit.
    Thanks,
    Russell

  • Strange web.xml tag error deploying on jBoss 4.0.5 / java5 / ejb3 : local-h

    Hi.
    We have an ejb3 / jsf / Java5 app that lives quite happily on OC4J standalone.
    When i try to deploy it on BEA 10 (tech preview) or jBoss 4.0.5 - ejb3 it throws the following:
    [org.jboss.web.tomcat.tc5.Tomcat5] Problem in init
    org.jboss.deployment.DeploymentException: Failed to parse WEB-INF/web.xml; - nested throwable: (org.jboss.deployment.DeploymentException: expected one local-home tag)
    It's asking for the local-home tag.
    We have quite a few <local> tags spread around, but no need for <local-home> (that seems to me as a ejb 2.x web.xml DTD tag for me).
    Why doesn't oc4j bother me, and bea or jboss do ??
    What is the standard ?? And/Or why isn't it implemented the same way ??
    Any clues ..?
    servlet motor (2.4, 2.5 ??)
    Thanks a lot.
    js.

    Do your standard deployment descriptors (ejb-jar.xml, web.xml, etc.) refer to the latest
    Java EE 5 schema versions? The ejb-ref element was changed in
    Java EE 5 to make local-home optional, since it's not needed to express a business interface
    dependency. It's either that or the schema versions in the tech preview itself are not up to date.
    --ken                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • WEB.XML gives me an error while deploying a Web Application in Weblogic 5.1

    I have a Web.xml which I copied the one from their documentation and edited for my servlet specific data. When I try to deploy it I am getting the following error.
              Wed Nov 15 17:10:37 EST 2000:<E> <HTTP> Error reading Web application 'C:/tomcat
              /webapps/La/'
              java.net.UnknownHostException: java.sun.com
              Can you throw some light on this? I have included the first three lines from the WEB,XML file where weblogic is choking.
              <?xml version="1.0" encoding="UTF-8"?>
              <!DOCTYPE web-app PUBLIC '-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN'
              'http://java.sun.com/j2ee/dtds/webapp_2_2.dtd'>
              Thank You
              Trisula P. Siripurapu
              

              Hi Jacek,
              Thank you for your suggestion. I changed the Web App version to 1.2 instead of 2.2. It worked. Thanks once again for the timely response. I really do appreciate it.
              Trisula Pani Siripurapu.
              Jacek Laskowski <[email protected]> wrote:
              >"Trisula P. Siripurapu" wrote:
              >>
              >> I have a Web.xml which I copied the one from their documentation and edited for my servlet specific data. When I try to deploy it I am getting the following error.
              >> Wed Nov 15 17:10:37 EST 2000:<E> <HTTP> Error reading Web application 'C:/tomcat
              >> /webapps/La/'
              >> java.net.UnknownHostException: java.sun.com
              >
              >I remember having the same problem before I added the latest service
              >pack (SP 6). If you don't want to download it, just change DOCTYPE to
              >
              ><!DOCTYPE web-app PUBLIC '-//Sun Microsystems, Inc.//DTD Web Application
              >1.2//EN' 'http://java.sun.com/j2ee/dtds/webapp_2_2.dtd'>
              >
              >and it should work. Notice the change of Web Application version - 1.2
              >rather then 2.2. I'm (almost) sure, I saw one example - examples/webapp
              >(?) - with this header. Take a look at the accompanying examples.
              >
              >When you apply SP6, things should work as they suppose to.
              >
              >> Trisula P. Siripurapu
              >
              >Jacek Laskowski
              

  • Java 7 Web start fails to download Java 1.6 version

    Sorry for the almost exact duplication of a previous thread, but that was closed (Java 7 Web start fails to download Java 1.6 version
    When launching an application requiring Java 1.6 with a Java 1.7 web start it fails when it tries to download 1.6 with the following message:
    "Unable to download http://javadl-esd.sun.com/update/1.6.0/1.6.0_29-b11.xml for installation"
    Problem only seems to occur on Windows 7 (64 bit), seems fine on Windows XP.
    Bug has been raised with Oracle by poster Matt Taylor - http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7168311
    Does anybody have any ideas?
    Thanks,
    Lee.

    igor wrote:
    Could you please collect and provide more info.
    In particular:
    0) Explain how exactly you launch JNLP when it does not work.We have a website with a link to a jnlp file. User clicks on the link the jnlp file downloads and installs.
    "install the jnlp from the dos window" - do you mean run "javaws applicationURL"?Yes. But actually that only worked because we had already installed a Java 6 version.
    When it does not work do you use Deployment Toolkit to embed link into web page?
    1) screenshot of the errorHere are links to several screenshots of errors we get:
    http://dl.waterford.org/pics/error_install.png
    http://dl.waterford.org/pics/error2.png
    http://dl.waterford.org/pics/error3.png
    Here is a link to the error in the java webstart failure dialog (details):
    http://dl.waterford.org/pics/errormsg.txt
    2) Enable full trace details (see http://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-Desktop/html/plugin.html#gcexdf)
    and post trace fileHere is a link to the java console with full trace details:
    http://dl.waterford.org/pics/javaconsole.txt
    3) Install WireShark and see what http requests are made. Please post all request/response pairshttp://dl.waterford.org/pics/packets.pcap
    Edited by: 933472 on May 10, 2012 1:30 PM

Maybe you are looking for