SaxParser supports schema validation?

Does oracle.xml.parser.v2.SAXParser support XML schema validation?
Thanks!

Yes, you can do XML Schema Validation with the SAX Parser.

Similar Messages

  • Java Stored Procedure SAXParser XML Schema Validation

    Using Oracle XML Developers Kit 10.2.0.2.0 - Production.
    Attempting to validate using XML Schema in a Java stored procedure with the code:
                   if ( schemaDoc == null )
                        // Obtain default connection
                        Connection conn = new OracleDriver().defaultConnection();
                        OraclePreparedStatement stmt = (OraclePreparedStatement) conn.prepareStatement("SELECT XmlDocObj FROM XmlDoc WHERE XmlDocNbr = 2");
                        OracleResultSet rset = (OracleResultSet)stmt.executeQuery();
                        if ( rset.next() )
                             // get the XMLType
                             XMLType schemaXml = (XMLType)rset.getObject(1);
                             XSDBuilder builder = new XSDBuilder();
                             XMLSchema schemaDoc = (XMLSchema)builder.build(new InputSource(schemaXml.getInputStream()));
                   if ( inst == null )
                        inst = new ValidateCoreRequest();
                   ErrorHandlerImpl handler = inst.getNewErrorHandler();
    SAXParser saxParser = new SAXParser();
    saxParser.setXMLSchema(schemaDoc);
    saxParser.setValidationMode(XMLParser.SCHEMA_VALIDATION);
    saxParser.setErrorHandler(handler);
    saxParser.parse(new InputSource(new StringReader(docStr)));
    if( handler.validationError )
                        errorMsg[0] = handler.saxParseException.getMessage().substring(0, Math.min(199, handler.saxParseException.getMessage().length()));
    Never reports validation errors in the XML. Although the XDK Programmers Guide states "...you can use
    the oracle.xml.parser.schema.XSDBuilder class to build an XML schema and
    then configure the parser to use it by invoking the XMLParser.setXMLSchema()
    method. In this case, the XML parser automatically sets the validation mode to
    SCHEMA_STRICT_VALIDATION and ignores the schemaLocation and
    noNamespaceSchemaLocation attributes." No validation seems to occur. I have tried to set an xsi:noNamespaceSchemaLocation attribute on the root XML node, but this results in URL errors if the URL is not valid or schema build errors if the URL is valid, but does not point to a real location.
    It appears that without a schema location attribute, no schema validation occurs. Using setXMLSchema() with a database source does not seem to cause the schema location attributes to be ignored. At least for Java stored procedures.
    Does XML Schema validation work in the database for externally referenced schemas?
    Thank You,
    Art

    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Jan Vissers ([email protected]):
    I have two schemas A and B. A contains a java stored procedure which calls a java stored procedure stored in B. Upon resolving the "A" Java Stored Procedures I get the following error:
    ORA-29545: badly formed class: at offset 3093 of Adapter.TFADPBeschikbaarheid.sendAanvraag expecting a class-oracle.xml.parser.v2.XMLDocument but encountered a class-oracle.xml.parser.v2.XMLDocument.
    ... Question:
    it is expecting something which it has in fact encountered... SO!!!! What is the error.
    Thx,
    Jan<HR></BLOCKQUOTE>
    Try this:
    Edit your XSU installation script located on lib directory of Oracle XSU's distribution:
    Find the line:
    loadjava -r -v -u $USER_PASSWORD xmlparserv2.jar
    Replace by:
    loadjava -r -v -g public -u $USER_PASSWORD xmlparserv2.jar
    And installs your Oracle XSU again.
    Best regards, Marcelo.

  • JAXP API provides no way to enable XML Schema validation mode

    I am evaluating XDK 9.2.0.5.0 for Java and have encountered another
    problem with XML Schema support when using the JAXP API.
    Using the classes in oracle.xml.jaxp.*, it appears to be impossible to
    enable XML Schema validation mode. I can set the schema object, but
    the parser does not use it for validation.
    If I use DOMParser directly, I can call the setValidationMode(int)
    method to turn on schema validation mode. There is no equivalient
    means to enable XML Schema validation when using the JAXP API.
    Test case for JAXP API:
    === begin OracleJAXPSchemaTest.java ======
    package dfranklin;
    import java.io.*;
    import javax.xml.parsers.*;
    import javax.xml.transform.*;
    import javax.xml.transform.dom.*;
    import javax.xml.transform.stream.*;
    import oracle.xml.parser.schema.XMLSchema;
    import oracle.xml.parser.schema.XSDBuilder;
    import org.w3c.dom.*;
    import org.xml.sax.*;
    public class OracleJAXPSchemaTest
    private final static String xsd = ""
    +"<xsd:schema xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" targetNamespace=\"urn:dfranklin:test\">"
    +" <xsd:element name=\"amount\" type=\"xsd:integer\"/>"
    +"</xsd:schema>";
    private final static String xml =
    "<amount xmlns=\"urn:dfranklin:test\">1</amount>";
    public static void main(String[] args)
    throws Exception
    System.setProperty("javax.xml.parsers.DocumentBuilderFactory",
              "oracle.xml.jaxp.JXDocumentBuilderFactory");
    new OracleJAXPSchemaTest().run();
    public void run()
    throws Exception
    DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
    dbf.setValidating(true);
    dbf.setNamespaceAware(true);
    XMLSchema xmlSchema = buildXMLSchema(new StringReader(xsd));
    dbf.setAttribute("oracle.xml.parser.XMLParser.SchemaObject",
              xmlSchema);
    DocumentBuilder docbldr = dbf.newDocumentBuilder();
    Document doc = docbldr.parse(new InputSource(new StringReader(xml)));
    print(doc);
    private XMLSchema buildXMLSchema(Reader xsdin)
    throws Exception
    XSDBuilder xsdBuilder = new XSDBuilder();
    XMLSchema xmlSchema = (XMLSchema)xsdBuilder.build(xsdin, null);
    return xmlSchema;
    private void print(Document doc)
    throws
    javax.xml.transform.TransformerConfigurationException,
    javax.xml.transform.TransformerException
    Transformer xformer = TransformerFactory.newInstance().newTransformer();
    xformer.transform(new DOMSource(doc), new StreamResult(System.out));
    System.out.println();
    === end OracleJAXPSchemaTest.java ======
    Running that program:
    java dfranklin.OracleJAXPSchemaTest
    produces this output
    Exception in thread "main" oracle.xml.parser.v2.XMLParseException: Element 'amount' used but not declared.
    at oracle.xml.parser.v2.XMLError.flushErrors(XMLError.java:148)
    at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:269)
    at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:149)
    at oracle.xml.jaxp.JXDocumentBuilder.parse(JXDocumentBuilder.java:96)
    at dfranklin.OracleJAXPSchemaTest.run(OracleJAXPSchemaTest.java:40)
    at dfranklin.OracleJAXPSchemaTest.main(OracleJAXPSchemaTest.java:27)
    This shows that the parser is not using the XML Schema to validate the
    document. I think it's expecting to find a DTD.
    Here is the equivalent program using DOMParser directly, and setting
    validation mode to SCHEMA_VALIDATION.
    === begin OracleParserTest.java ====
    package dfranklin;
    import java.io.*;
    import javax.xml.transform.*;
    import javax.xml.transform.dom.*;
    import javax.xml.transform.stream.*;
    import oracle.xml.parser.schema.XMLSchema;
    import oracle.xml.parser.schema.XSDBuilder;
    import oracle.xml.parser.v2.DOMParser;
    import oracle.xml.parser.v2.XMLParser;
    import org.w3c.dom.*;
    import org.xml.sax.*;
    public class OracleParserTest
    private final static String xsd = ""
    +"<xsd:schema xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" targetNamespace=\"urn:dfranklin:test\">"
    +" <xsd:element name=\"amount\" type=\"xsd:integer\"/>"
    +"</xsd:schema>";
    private final static String xml =
    "<amount xmlns=\"urn:dfranklin:test\">1</amount>";
    public static void main(String[] args)
    throws Exception
    new OracleParserTest().run();
    public void run()
    throws Exception
    DOMParser dp = new DOMParser();
    XMLSchema xmlSchema = buildXMLSchema(new StringReader(xsd));
    dp.setXMLSchema(xmlSchema);
    dp.setValidationMode(XMLParser.SCHEMA_VALIDATION);
    dp.parse(new InputSource(new StringReader(xml)));
    Document doc = dp.getDocument();
    print(doc);
    private XMLSchema buildXMLSchema(Reader xsdin)
    throws Exception
    XSDBuilder xsdBuilder = new XSDBuilder();
    XMLSchema xmlSchema = (XMLSchema)xsdBuilder.build(xsdin, null);
    return xmlSchema;
    private void print(Document doc)
    throws
    javax.xml.transform.TransformerConfigurationException,
    javax.xml.transform.TransformerException
    Transformer xformer = TransformerFactory.newInstance().newTransformer();
    xformer.transform(new DOMSource(doc), new StreamResult(System.out));
    System.out.println();
    === end OracleParserTest.java ====
    Running that program
    java dfranklin.OracleParserTest
    produces this output
    <?xml version = '1.0'?>
    <amount xmlns="urn:dfranklin:test">1</amount>
    In this case, the parser has validated the document.
    I also tried this with version 10.1.0.0.0 beta, and got the same
    error.
    Darin Franklin

    Thanks for posting that. I tried that code and still got my problem. The big difference is that I'm reading a group of XML files each of which uses a large number of schema files. There are over 50 schema files organized so they can be included as needed. Each of the XML files has a noNamespaceSchemaLocation attribute specifying one of the ten top schma files, that includes many others.
    However, I did solve the problem. I added one line --
           saxb.setFeature( "http://apache.org/xml/features/validation/schema",
                    true);
            // next line is new
            saxb.setProperty( JAXPConstants.JAXP_SCHEMA_LANGUAGE,
                    JAXPConstants.W3C_XML_SCHEMA );after the setFeature to turn on schema validation.
    (It needs an import org.apache.xerces.jaxp.JAXPConstants; statement.)
    Note:With the feature set to true and the setProperty commented out, the EntityResolver is called at construction tiem, and for each schema file, but each element is flagged as needing to be declared.
    With the feature commented out, and the setProperty in place, the EntityResolver is not called, and there is no validation performed. (I added invalid content to one of the files and there were no errors listed.)
    With both the setFeature and the setProperty in place, however, I get the calls from the EntityResolver indicating that it is processing the schema files, and for the good files, I get no errror, but for the bad file, I get an error indicating a bad validation.
    Now I can make the EntityResolver quiet and get what I wanted. Maybe there are other ways to do this, but I've got one that works. :-)
    Thanks to all who have helped.
    Dave Patterson

  • Adapter Engine XML Schema Validation Error Surpression

    We recently developed a number of web services that are called by 3rd parties outside our network. The web service request once made is picked up by a Web Dispatcher which then forwards the request to the de-central adapter. Both of these components reside within within a DMZ.
    We have, as an additional security measure made use of the new Adapter Engine XML Schema validation available with PI 7.1, to ensure that the payload of incomming messages is checked to ensure that it is a known structure.
    Now here is my problem, we recently had these services penetration tested by a 3rd party to ensure that they were secure and whilst the report was very good showing no major weaknesses they did pickup on a couple of items including that the fact that if the XSD to be used during payload message validation cannot be found an 'ADAPTER.JAVA_EXCEPTION' is returned to the web service consumer that highlights the path details of where the XSD should be (but could not be found).
    This was viewed as useful to an attacker for a number of reasons:
    1. Feedback in SQL injection attempts via verbatim DB error messages greatly improves attacker efficiency
    2. Path information is useful to the attacker for OS fingerprinting, directory traversal attempts
    3. Other miscellaneous stack trace information is useful to an attacker to understand how the application works
    Is there anyway this can be surpressed so that the adapter does not show this information in the returned error message - see example message below ?
    com.sap.engine.interfaces.messaging.api.exception.MessagingException: com.sap.engine.interfaces.messaging.api.exception.MessageFormatException: Schema MaintenanceOrderByIDQuery_sync.xsd not found in E:\usr\sap\DPI\DVEBMGS40\j2ee\cluster\server0\validation\schema\f7cd3b50a87411e08830ed9d0af006a5\urnstw.contractor.wfm.workorderretrieval\MaintenanceOrderByIDQueryRequest_Out\httpsap.comxiSAPGlobal20~Global\MaintenanceOrderByIDQuery_sync.xsd  (validation\schema)
         at com.sap.aii.adapter.soap.ejb.XISOAPAdapterBean.process(XISOAPAdapterBean.java:1041)
         at sun.reflect.GeneratedMethodAccessor497.invoke(Unknown Source)
    com.sap.engine.interfaces.messaging.api.exception.MessagingException: com.sap.engine.interfaces.messaging.api.exception.MessageFormatException: Schema Schema1.xsd not found in E:\usr\sap\DPI\DVEBMGS40\j2ee\cluster\server0\validation\schema\f7cd3b50a87411e08830ed9d0af006a5\urnstw.contractor.wfm.workorderretrieval\MaintenanceOrderByIDQueryRequest_Out\httpsap.comxiEA-APPLSEGlobal\Schema1.xsd  (validation\schema)
         at com.sap.aii.adapter.soap.ejb.XISOAPAdapterBean.process(XISOAPAdapterBean.java:1041)

    Hi,
    We are having the same problem, so you are not alone.
    I had an extensive call with Azure premium support and we where able to determine that:
    - Nothing is missing or in the wrong place in my exported .xml file.
    - Any changes to the VNET's using the web gui interface of https://manage.windowsazure.com is not possible when you have dns servers and use an gateway
    - You can download the .xml configuration file of the network and make manual changes to it, then import it again , to add/remove dns servers and or subnet's. 
    I am currently waiting for an solution,  i have let them lower the urgency from A to B (because i can make changes trough xml) and responded to the next support contact (saying he will continue with the issue) that the problems seems to be with azure and
    he should speak with the previous person helping me.  I have not heard from Azure support since.
    SR Number:115021812414226
    Open on:02/18/2015 09:28
    > There are networks with and without gateways created and the issue is happening on all the networks.
    > We are unable to add or remove the DNS servers. (by web gui)
    > Also not able to add or remove any subnets. (by web gui)
    > Every time the error message is same but the DNS server name is different. (from another subnet then the one we are changing)
    > Created CRI- 3405931, but they said it will need WATS team.
    > Confirmed with WATS engineer as well and moving case to WATS.
    > Cx agreed to lower the severity of the case as they are able to make changes through the network configuration file.
    > But they still want to get this resolved soon.
    > Agreed and dropped off, reducing severity to B 24/7.
    I hope microsoft is going to resolve this soon, as i do not want to edit my xml for little things like adding a subnet all the time. I have requested an status update in the issue.
    Should anyone have more information on this, please share it here.

  • XML Schema validation Error

    Hi,
    Have a scenerio in which consecutive mapping needs to be done.The first mapping is a Java Mapping in which XML schema validation needs to be done.
    If XML Schema validation is sucessful(Mapping 1),then graphical message mapping(MM_Entry) needs to be performed.
    I have uploded a jar file in imported Archives which contains
    1)Schema file(inputSchema.xsd): This is an XSD file which is generated in XI....XSD fomat of Source message type
    2) The java Class file
    Following are few lines of code for better idea:
    public class SAXParser implements StreamTransformation {
    public void execute(InputStream input, OutputStream output) throws StreamTransformationException {
    SAXParserFactory saxParserFactory = SAXParserFactory.newInstance();
    InputStream mySchema = this.getClass().getClassLoader().getResourceAsStream("inputSchema.xsd");
    SAXParser saxParser = saxParserFactory.newSAXParser();
    saxParser.setProperty("http://java.sun.com/xml/jaxp/properties/schemaLanguage", "http://www.w3.org/2001/XMLSchema");
    saxParser.setProperty("http://java.sun.com/xml/jaxp/properties/schemaSource",mySchema);
    saxParser.parse(input, new HandlerBase());
    After above step(parsing),input is copied to output and streams are closed as follows:
    byte[] buf = new byte[4096];
    for(int len=-1;(len=input.read(buf))!=-1;)
    output.write(buf,0,len);
    input.close();
    output.close();
    After sending correct source message from input ,i am getting following error:
    Runtime exception occurred during execution of application mapping program com/sap/xi/tf/_MM_Entry_: com.sap.aii.utilxi.misc.api.BaseRuntimeException; Parsing an empty source. Root element expected!

    Daniel,
    As I've said, I've used it successfully in PI 7.0 SP10.
    You're right about documentation, it says that by default, Java 1.4.2 mark() and reset() methods of InputStream class are not fully implemented (mark() would do nothing and reset() would always throw an IOException). And that would be the expected behavior...
    ...unless the SAP developers have extended the InputStream class to include actual implementatios to the mark() and reset() methods.
    I'm not saying that they have, but it would be possible, wouldn't it?
    It does work, after all...
    Regards,
    Henrique.

  • Schema validation errors in Portal 10.3

    I downloaded, installed and configured a domain with an AdminServer and a ManagedServer for WebLogic Portal 10.3. When I start the AdminServer from NodeManager the following errors are reported:
    <Sep 24, 2008 12:50:41 PM CDT> <Error> <Management> <BEA-141244> <Schema validation errors while parsing /opt/Oracle/WL10gR3/user_projects/domains/web/config/config.xml - Invalid xsi:type qname: 'wsrp:wsrp-identity-asserterType' in element realm@http://www.bea.com/ns/weblogic/920/domain>
    <Sep 24, 2008 12:50:41 PM CDT> <Error> <Management> <BEA-141244> <Schema validation errors while parsing /opt/Oracle/WL10gR3/user_projects/domains/web/config/config.xml - /opt/Oracle/WL10gR3/user_projects/domains/web/<unknown>:13:9: error: failed to load java type corresponding to t=wsrp-identity-asserterType@http://www.bea.com/ns/wlp/90/security/wsrp>
    When I start the AdminServer using startWebLogic.sh there are no errors. Please advise.

    I have been at this for less than a month, so I may need a little more help. So are you saying that the product as installed has been reorganized and that all of the installed pieces may not reflect all of the changes?
    I have continued cutting down my scripts and NodeManager does not seem to be a factor. Starting from WLST does not work.
    This works:
    /opt/Oracle/WL10gR3/user_projects/domains/web/bin/startWebLogic.sh.
    JAVA Memory arguments: -Xms256m -Xmx768m
    WLS Start Mode=Production
    CLASSPATH=:/opt/Oracle/WL10gR3/patch_wlw1030/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/Oracle/WL10gR3/patch_wls1030/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/Oracle/WL10gR3/patch_wlp1030/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/Oracle/WL10gR3/patch_cie670/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/Oracle/WL10gR3/jrockit_160_05/lib/tools.jar:/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/weblogic_sp.jar:/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/weblogic.jar:/opt/Oracle/WL10gR3/modules/features/weblogic.server.modules_10.3.0.0.jar:/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/webservices.jar:/opt/Oracle/WL10gR3/modules/org.apache.ant_1.6.5/lib/ant-all.jar:/opt/Oracle/WL10gR3/modules/net.sf.antcontrib_1.0.0.0_1-0b2/lib/ant-contrib.jar::/opt/Oracle/WL10gR3/wlserver_10.3/common/eval/pointbase/lib/pbclient57.jar:/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/xqrl.jar:/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/xquery.jar:/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/binxml.jar:
    PATH=/opt/Oracle/WL10gR3/wlserver_10.3/server/bin:/opt/Oracle/WL10gR3/modules/org.apache.ant_1.6.5/bin:/opt/Oracle/WL10gR3/jrockit_160_05/jre/bin:/opt/Oracle/WL10gR3/jrockit_160_05/bin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin
    * To start WebLogic Server, use a username and *
    * password assigned to an admin-level user. For *
    * server administration, use the WebLogic Server *
    * console at http://hostname:port/console *
    starting weblogic with Java version:
    x86_64 is not a supported Linux hardware platform for Autonomy.
    java version "1.6.0_05"
    Java(TM) SE Runtime Environment (build 1.6.0_05-b13)
    BEA JRockit(R) (build R27.6.0-50_o-100423-1.6.0_05-20080626-2104-linux-ia32, compiled mode)
    Starting WLS with line:
    /opt/Oracle/WL10gR3/jrockit_160_05/bin/java -jrockit -Xms256m -Xmx768m -da -Dplatform.home=/opt/Oracle/WL10gR3/wlserver_10.3 -Dwls.home=/opt/Oracle/WL10gR3/wlserver_10.3/server -Dweblogic.home=/opt/Oracle/WL10gR3/wlserver_10.3/server -Dweblogic.wsee.bind.suppressDeployErrorMessage=true -Dweblogic.wsee.skip.async.response=true -Dweblogic.management.discover=true -Dwlw.iterativeDev=false -Dwlw.testConsole=false -Dwlw.logErrorsToConsole=true -Dweblogic.ext.dirs=/opt/Oracle/WL10gR3/patch_wlw1030/profiles/default/sysext_manifest_classpath:/opt/Oracle/WL10gR3/patch_wls1030/profiles/default/sysext_manifest_classpath:/opt/Oracle/WL10gR3/patch_wlp1030/profiles/default/sysext_manifest_classpath:/opt/Oracle/WL10gR3/patch_cie670/profiles/default/sysext_manifest_classpath:/opt/Oracle/WL10gR3/wlportal_10.3/p13n/lib/system:/opt/Oracle/WL10gR3/wlportal_10.3/light-portal/lib/system:/opt/Oracle/WL10gR3/wlportal_10.3/portal/lib/system:/opt/Oracle/WL10gR3/wlportal_10.3/info-mgmt/lib/system:/opt/Oracle/WL10gR3/wlportal_10.3/analytics/lib/system:/opt/Oracle/WL10gR3/wlportal_10.3/apps/lib/system:/opt/Oracle/WL10gR3/wlportal_10.3/info-mgmt/deprecated/lib/system:/opt/Oracle/WL10gR3/wlportal_10.3/content-mgmt/lib/system -Dweblogic.alternateTypesDirectory=/opt/Oracle/WL10gR3/wlportal_10.3/portal/lib/security -Dweblogic.Name=AdminServer -Djava.security.policy=/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/weblogic.policy weblogic.Server
    <Sep 25, 2008 11:34:35 AM CDT> <Notice> <WebLogicServer> <BEA-000395> <Following extensions directory contents added to the end of the classpath:
    /opt/Oracle/WL10gR3/wlportal_10.3/analytics/lib/system/analytics_sys.jar:/opt/Oracle/WL10gR3/wlportal_10.3/apps/lib/system/groupspace_system.jar:/opt/Oracle/WL10gR3/wlportal_10.3/content-mgmt/lib/system/content_system.jar:/opt/Oracle/WL10gR3/wlportal_10.3/info-mgmt/deprecated/lib/system/commerce_system.jar:/opt/Oracle/WL10gR3/wlportal_10.3/info-mgmt/lib/system/wlp-schemas.jar:/opt/Oracle/WL10gR3/wlportal_10.3/info-mgmt/lib/system/wlp_content_system.jar:/opt/Oracle/WL10gR3/wlportal_10.3/info-mgmt/lib/system/wps_system.jar:/opt/Oracle/WL10gR3/wlportal_10.3/light-portal/lib/system/netuix_common.jar:/opt/Oracle/WL10gR3/wlportal_10.3/light-portal/lib/system/netuix_schemas.jar:/opt/Oracle/WL10gR3/wlportal_10.3/light-portal/lib/system/netuix_system.jar:/opt/Oracle/WL10gR3/wlportal_10.3/light-portal/lib/system/wsrp-client.jar:/opt/Oracle/WL10gR3/wlportal_10.3/light-portal/lib/system/wsrp-common.jar:/opt/Oracle/WL10gR3/wlportal_10.3/p13n/lib/system/p13n-schemas.jar:/opt/Oracle/WL10gR3/wlportal_10.3/p13n/lib/system/p13n_common.jar:/opt/Oracle/WL10gR3/wlportal_10.3/p13n/lib/system/p13n_system.jar:/opt/Oracle/WL10gR3/wlportal_10.3/p13n/lib/system/wlp_services.jar:/opt/Oracle/WL10gR3/wlportal_10.3/portal/lib/system/netuix_system-full.jar>
    <Sep 25, 2008 11:34:36 AM CDT> <Info> <WebLogicServer> <BEA-000377> <Starting WebLogic Server with BEA JRockit(R) Version R27.6.0-50_o-100423-1.6.0_05-20080626-2104-linux-ia32 from BEA Systems, Inc.>
    <Sep 25, 2008 11:34:36 AM CDT> <Info> <Management> <BEA-141107> <Version: WebLogic Server Temporary Patch for CR376251 Wed Aug 06 09:19:34 PDT 2008
    WebLogic Server Temporary Patch for CR371247 Sat Aug 09 20:10:38 PDT 2008
    WebLogic Server Temporary Patch for CR377673 Tue Aug 12 20:39:50 EDT 2008
    WebLogic Server Temporary Patch for CR377673 Tue Aug 12 20:39:50 EDT 2008
    WebLogic Server Temporary Patch for CR376759 Thu Aug 14 14:53:02 PDT 2008
    WebLogic Server 10.3 Fri Jul 25 16:30:05 EDT 2008 1137967 >
    <Sep 25, 2008 11:34:38 AM CDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>
    This does not work:
    . /opt/Oracle/WL10gR3/user_projects/domains/web/bin/setDomainEnv.sh
    java weblogic.WLSTInitializing WebLogic Scripting Tool (WLST) ...
    Welcome to WebLogic Server Administration Scripting Shell
    Type help() for help on available commands
    wls:/offline> startServer()
    Starting weblogic server ...
    WLST-WLS-1222359153099: <Sep 25, 2008 11:12:34 AM CDT> <Info> <WebLogicServer> <BEA-000377> <Starting WebLogic Server with BEA JRockit(R) Version R27.6.0-50_o-100423-1.6.0_05-20080626-2104-linux-ia32 from BEA Systems, Inc.>
    WLST-WLS-1222359153099: <Sep 25, 2008 11:12:34 AM CDT> <Info> <Management> <BEA-141107> <Version: WebLogic Server Temporary Patch for CR376251 Wed Aug 06 09:19:34 PDT 2008
    WLST-WLS-1222359153099: WebLogic Server Temporary Patch for CR371247 Sat Aug 09 20:10:38 PDT 2008
    WLST-WLS-1222359153099: WebLogic Server Temporary Patch for CR377673 Tue Aug 12 20:39:50 EDT 2008
    WLST-WLS-1222359153099: WebLogic Server Temporary Patch for CR377673 Tue Aug 12 20:39:50 EDT 2008
    WLST-WLS-1222359153099: WebLogic Server Temporary Patch for CR376759 Thu Aug 14 14:53:02 PDT 2008
    WLST-WLS-1222359153099: WebLogic Server 10.3 Fri Jul 25 16:30:05 EDT 2008 1137967 >
    WLST-WLS-1222359153099: <Sep 25, 2008 11:12:36 AM CDT> <Error> <Management> <BEA-141244> <Schema validation errors while parsing /opt/Oracle/WL10gR3/user_projects/domains/web/config/config.xml - Invalid xsi:type qname: 'wsrp:wsrp-identity-asserterType' in element realm@http://www.bea.com/ns/weblogic/920/domain>
    AdminServer.out:
    <Sep 25, 2008 10:56:16 AM> <Info> <NodeManager> <Starting WebLogic server with command line: /opt/Oracle/WL10gR3/jrockit_160_05/jre/bin/java -Dweblogic.Name=AdminServer -Djava.security.policy=/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/weblogic.policy -Djava.library.path=/opt/Oracle/WL10gR3/jrockit_160_05/jre/lib/i386/jrockit:/opt/Oracle/WL10gR3/jrockit_160_05/jre/lib/i386:/opt/Oracle/WL10gR3/jrockit_160_05/jre/../lib/i386::/opt/Oracle/WL10gR3/wlserver_10.3/server/native/linux/i686:/opt/Oracle/WL10gR3/wlserver_10.3/server/native/linux/i686/oci920_8 -Djava.class.path=/opt/Oracle/WL10gR3/patch_wlw1030/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/Oracle/WL10gR3/patch_wls1030/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/Oracle/WL10gR3/patch_wlp1030/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/Oracle/WL10gR3/patch_cie670/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/Oracle/WL10gR3/jrockit_160_05/lib/tools.jar:/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/weblogic_sp.jar:/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/weblogic.jar:/opt/Oracle/WL10gR3/modules/features/weblogic.server.modules_10.3.0.0.jar:/opt/Oracle/WL10gR3/wlserver_10.3/server/lib/webservices.jar:/opt/Oracle/WL10gR3/modules/org.apache.ant_1.6.5/lib/ant-all.jar:/opt/Oracle/WL10gR3/modules/net.sf.antcontrib_1.0.0.0_1-0b2/lib/ant-contrib.jar::/opt/Oracle/WL10gR3 -Dweblogic.system.BootIdentityFile=/opt/Oracle/WL10gR3/user_projects/domains/web/servers/AdminServer/security/boot.properties -Dweblogic.nodemanager.ServiceEnabled=true weblogic.Server >
    <Sep 25, 2008 10:56:16 AM> <Info> <NodeManager> <Working directory is "/opt/Oracle/WL10gR3/user_projects/domains/web">
    <Sep 25, 2008 10:56:16 AM> <Info> <NodeManager> <Server output log file is "/opt/Oracle/WL10gR3/user_projects/domains/web/servers/AdminServer/logs/AdminServer.out">
    <Sep 25, 2008 10:56:17 AM CDT> <Info> <WebLogicServer> <BEA-000377> <Starting WebLogic Server with BEA JRockit(R) Version R27.6.0-50_o-100423-1.6.0_05-20080626-2104-linux-ia32 from BEA Systems, Inc.>
    <Sep 25, 2008 10:56:17 AM CDT> <Info> <Management> <BEA-141107> <Version: WebLogic Server Temporary Patch for CR376251 Wed Aug 06 09:19:34 PDT 2008
    WebLogic Server Temporary Patch for CR371247 Sat Aug 09 20:10:38 PDT 2008
    WebLogic Server Temporary Patch for CR377673 Tue Aug 12 20:39:50 EDT 2008
    WebLogic Server Temporary Patch for CR377673 Tue Aug 12 20:39:50 EDT 2008
    WebLogic Server Temporary Patch for CR376759 Thu Aug 14 14:53:02 PDT 2008
    WebLogic Server 10.3 Fri Jul 25 16:30:05 EDT 2008 1137967 >
    <Sep 25, 2008 10:56:19 AM CDT> <Error> <Management> <BEA-141244> <Schema validation errors while parsing /opt/Oracle/WL10gR3/user_projects/domains/web/config/config.xml - /opt/Oracle/WL10gR3/user_projects/domains/web/<unknown>:13:9: error: failed to load java type corresponding to t=wsrp-identity-asserterType@http://www.bea.com/ns/wlp/90/security/wsrp>

  • XML Schema validation error in network configuration. Missing DnsRef

    When ever we try to make changes to a Virtual network we receive
    XML Schema validation
    error in network configuration. Missing DnsRef
    We can't make any changes to the Virtual network.
    The DNS ref exists as well.
    Considering exporting network config and re-importing however we have a lot of networks configured and want to be sure this is the correct way to proceed.
    Any feedback much appreciated.
    Thanks

    Hi,
    We are having the same problem, so you are not alone.
    I had an extensive call with Azure premium support and we where able to determine that:
    - Nothing is missing or in the wrong place in my exported .xml file.
    - Any changes to the VNET's using the web gui interface of https://manage.windowsazure.com is not possible when you have dns servers and use an gateway
    - You can download the .xml configuration file of the network and make manual changes to it, then import it again , to add/remove dns servers and or subnet's. 
    I am currently waiting for an solution,  i have let them lower the urgency from A to B (because i can make changes trough xml) and responded to the next support contact (saying he will continue with the issue) that the problems seems to be with azure and
    he should speak with the previous person helping me.  I have not heard from Azure support since.
    SR Number:115021812414226
    Open on:02/18/2015 09:28
    > There are networks with and without gateways created and the issue is happening on all the networks.
    > We are unable to add or remove the DNS servers. (by web gui)
    > Also not able to add or remove any subnets. (by web gui)
    > Every time the error message is same but the DNS server name is different. (from another subnet then the one we are changing)
    > Created CRI- 3405931, but they said it will need WATS team.
    > Confirmed with WATS engineer as well and moving case to WATS.
    > Cx agreed to lower the severity of the case as they are able to make changes through the network configuration file.
    > But they still want to get this resolved soon.
    > Agreed and dropped off, reducing severity to B 24/7.
    I hope microsoft is going to resolve this soon, as i do not want to edit my xml for little things like adding a subnet all the time. I have requested an status update in the issue.
    Should anyone have more information on this, please share it here.

  • XML binary storage format impairs schema validation?

    I'm using Oracle 11g R1 on Windows Server 2003. I successfully registered schemas and created tables and indexes in the new binary storage format. However, when trying to load data, I'm running into problems. Schema validation behaves as if not the full feature set of XML Schema mysteriously isn't supported anymore.
    There is probably more but at least wildcard elements (xs:any) and element references (xs:element ref="STH") are simply ignored in the schema definition and data is rejected even when it conforms to the schema.
    Is there any solution for this or am I out of luck? I wanted to go back to CLOB storage as used in a previous installation but I'm running into problems when registering the schema. It complains about an empty SQL name although I don't have any defined. I'm pretty weirded out by all this.
    I created the schema and table in a straightforward way:
    begin
      dbms_xmlschema.registeruri(
        schemaurl => 'http://www.xxxhello.com/archive_tsd.xsd',
        schemadocuri => '/public/user/archive_tsd.xsd',
        gentypes => FALSE,
        options => DBMS_XMLSCHEMA.REGISTER_BINARYXML
    end;
    CREATE TABLE archive OF xmltype XMLTYPE STORE AS binary xml XMLSCHEMA
    "http://www.xxxhello.com/archive_tsd.xsd" ELEMENT "CompleteDocument";
    create index idx_lastmodified_archive on archive t
    (extractvalue(VALUE(t),'/CompleteDocument/DocContent/LastModified'));Because of xs:any or element references is ignored, I get errors like
    LSX-00213: only 0 occurrences of particle "REFDELEM", minimum is 1.
    Thanks for your help.

    The schema is very large (>200kb). Where should I upload it or can I send it to you? I'm bit concerned about confidentiality of company data. However, the instance is not valid yet. I'm in the process of modifying the schema to match all instances, but it breaks on places that should be already okay. No, I didn't use SchemaValidate ever.
    But I've made an example where at least xs:any doesn't work. Element references work, though.
    Sample schema:
    <?xml version = "1.0" encoding = "UTF-8"?>
    <xs:schema
      xmlns:tsd = "http://namespaces.softwareag.com/tamino/TaminoSchemaDefinition"
      xmlns:xs = "http://www.w3.org/2001/XMLSchema">
      <xs:annotation>
        <xs:appinfo>
          <tsd:schemaInfo name = "sbreak">
            <tsd:collection name = "sbreak"></tsd:collection>
            <tsd:doctype name = "CompleteDocument">
              <tsd:logical>
                <tsd:content>open</tsd:content>
                <tsd:systemGeneratedIdentity reuse = "false"></tsd:systemGeneratedIdentity>
              </tsd:logical>
            </tsd:doctype>
            <tsd:adminInfo>
              <tsd:server>4.4.1.1</tsd:server>
              <tsd:modified>2007-07-03T16:00:46.484+02:00</tsd:modified>
              <tsd:created>2007-07-03T15:29:04.968+02:00</tsd:created>
              <tsd:version>TSD4.4</tsd:version>
            </tsd:adminInfo>
          </tsd:schemaInfo>
        </xs:appinfo>
      </xs:annotation>
      <xs:element name = "CompleteDocument">
        <xs:complexType>
          <xs:choice minOccurs = "0" maxOccurs = "unbounded">
            <xs:element name = "ComplexNormal">
              <xs:complexType>
                <xs:choice minOccurs = "0" maxOccurs = "unbounded">
                  <xs:element name = "NormalElem1" type = "xs:string"></xs:element>
                  <xs:element name = "NormalElem2" type = "xs:string"></xs:element>
                </xs:choice>
              </xs:complexType>
            </xs:element>
            <xs:element name = "ComplexAny">
              <xs:complexType>
                <xs:choice minOccurs = "0" maxOccurs = "unbounded">
                  <xs:any minOccurs = "0" maxOccurs = "unbounded"></xs:any>
                </xs:choice>
              </xs:complexType>
            </xs:element>
            <xs:element name = "ComplexRef">
              <xs:complexType>
                <xs:choice minOccurs = "0" maxOccurs = "unbounded">
                  <xs:element ref = "RefdElem"></xs:element>
                </xs:choice>
              </xs:complexType>
            </xs:element>
            <xs:element name = "LastModified" type = "xs:string"></xs:element>
          </xs:choice>
        </xs:complexType>
      </xs:element>
      <xs:element name = "RefdElem">
        <xs:complexType>
          <xs:choice minOccurs = "0" maxOccurs = "unbounded">
            <xs:element name = "Elem1" type = "xs:string"></xs:element>
            <xs:element name = "Elem2" type = "xs:string"></xs:element>
          </xs:choice>
        </xs:complexType>
      </xs:element>
    </xs:schema>Sample instance:
    <?xml version="1.0" encoding="UTF-8" ?>
    <CompleteDocument>
         <ComplexNormal>
              <NormalElem1>Test1</NormalElem1>
              <NormalElem2>Test2</NormalElem2>
         </ComplexNormal>
         <ComplexAny>
              <AnyElem>Test3</AnyElem>
         </ComplexAny>
         <ComplexRef>
              <RefdElem>
                   <Elem1>Test4</Elem1>
                   <Elem2>Test5</Elem2>
              </RefdElem>
         </ComplexRef>
    </CompleteDocument>Log of what I did. First I confirmed, that I could enter the instance using clob storage:
    SQL> begin
      2    dbms_xmlschema.registeruri(
      3      schemaurl => 'http://www.xxxhello.com/sbreak_tsd.xsd',
      4      schemadocuri => '/public/sbreak_tsd.xsd'
      5    );
      6  end;
      7  /
    PL/SQL-Prozedur erfolgreich abgeschlossen.
    SQL> CREATE TABLE sbreak OF xmltype XMLTYPE STORE AS clob XMLSCHEMA
    "http://www.xxxhello.com/sbreak_tsd.xsd" ELEMENT "CompleteDocument";
    Tabelle wurde erstellt.
    SQL> create index idx_lastmodified_sbreak on sbreak t (extractvalue(VALUE(t),
    '/CompleteDocument/LastModified'));
    Index wurde erstellt.
    SQL> insert into sbreak values(xmltype(bfilename('DATA', 'sbreak/sbreakinstance.xml'),
    NLS_CHARSET_ID('AL32UTF8')));
    1 Zeile wurde erstellt.Then I deleted table and schema again:
    SQL> drop index idx_lastmodified_sbreak;
    Index wurde gelöscht.
    SQL> drop table sbreak;
    Tabelle wurde gelöscht.
    SQL> begin
      2    dbms_xmlschema.deleteschema(
      3      schemaurl => 'http://www.xxxhello.com/sbreak_tsd.xsd'
      4     ,delete_option => dbms_xmlschema.delete_cascade_force
      5    );
      6  end;
      7  /
    PL/SQL-Prozedur erfolgreich abgeschlossen.After that I created schema and table with binary XML storage and tried to insert the same instance again:
    SQL> begin
      2    dbms_xmlschema.registeruri(
      3      schemaurl => 'http://www.xxxhello.com/sbreak_tsd.xsd',
      4      schemadocuri => '/public/sbreak_tsd.xsd',
      5      gentypes => FALSE,
      6      options => DBMS_XMLSCHEMA.REGISTER_BINARYXML
      7    );
      8  end;
      9  /
    PL/SQL-Prozedur erfolgreich abgeschlossen.
    SQL> CREATE TABLE sbreak OF xmltype XMLTYPE STORE AS binary xml XMLSCHEMA
    "http://www.xxxhello.com/sbreak_tsd.xsd" ELEMENT "CompleteDocument";
    Tabelle wurde erstellt.
    SQL> create index idx_lastmodified_sbreak on sbreak t (extractvalue(VALUE(t),
    '/CompleteDocument/LastModified'));
    Index wurde erstellt.
    SQL> insert into sbreak values(xmltype(bfilename('DATA', 'sbreak/sbreakinstance.xml'),
    NLS_CHARSET_ID('AL32UTF8')));
    insert into sbreak values(xmltype(bfilename('DATA', 'sbreak/sbreakinstance.xml'),
    NLS_CHARSET_ID('AL32UTF8')))
    FEHLER in Zeile 1:
    ORA-31011: XML-Parsing nicht erfolgreich
    ORA-19202: Fehler bei XML-Verarbeitung
    LSX-00021: undefined element "AnyElem"
    aufgetretenSorry about the non-english text, but I think it can be guessed easily what's going on. Next I'll try a modifed schema without the tsd namespace added by the schema editor I use (the original large schema has been migrated from the Tamino XML database).

  • Problem in SAX XSD schema validator

    hi
    I've tried this code to validate XML using xsd file:
    public static void validate(String xmlFilePath, URL schemaFileUrl)
            try
                SAXParserFactory factory = SAXParserFactory.newInstance();
                factory.setValidating(false);// stop standard validation to allow
                                                // custom schema
                factory.setNamespaceAware(true);
                SchemaFactory schemaFactory = SchemaFactory
                        .newInstance(javax.xml.XMLConstants.W3C_XML_SCHEMA_NS_URI);
                factory.setSchema(schemaFactory.newSchema(schemaFileUrl));
                SAXParser parser = factory.newSAXParser();
                XMLReader reader = parser.getXMLReader();
                // Register the error handler
                reader.setErrorHandler(new JS_ValidationError());
                // Parse the file as the first argument on the command-line
                reader.parse(xmlFilePath);
            catch (SAXException e)
                System.out.println("Error: " + e.getMessage());
                e.printStackTrace();
            } catch (IOException e)
                System.out.println("Error: " + e.getMessage());
                e.printStackTrace();
            } catch (ParserConfigurationException e)
                // TODO Auto-generated catch block
                e.printStackTrace();
        } I have called this method ,but it issues this error :"unknown protocol" followed by windows partition name, in the debug I found that the value of the url is "*file://(*windows-partiton-char)/rest of path" !!!
    this should work but it doesn't!!
    so how can I fix this problem?
    thanks

    someone sent me this code to fix,it works:
    package schemaValidationPackage;
    * XsdSchemaSaxValidator.java
    * Copyright (c) 2007 by Dr. Herong Yang. All rights reserved.
    import javax.xml.validation.SchemaFactory;
    import javax.xml.validation.Schema;
    import javax.xml.XMLConstants;
    import javax.xml.parsers.ParserConfigurationException;
    import javax.xml.parsers.SAXParser;
    import javax.xml.parsers.SAXParserFactory;
    import javax.xml.transform.sax.SAXSource;
    import org.xml.sax.InputSource;
    import org.xml.sax.SAXException;
    import org.xml.sax.XMLReader;
    import javax.xml.validation.Validator;
    import java.io.*;
    import java.net.URL;
    //also thanks for developer Hind Abd-El-Khalek
    public class XsdSchemaSaxValidator {
         public static void validate(String xmlFilePath, URL schemaFileUrl)
            try
                SAXParserFactory factory = SAXParserFactory.newInstance();
                factory.setValidating(false);// stop standard validation to allow
                                                // custom schema
                factory.setNamespaceAware(true);
                SchemaFactory schemaFactory = SchemaFactory
                        .newInstance(javax.xml.XMLConstants.W3C_XML_SCHEMA_NS_URI);
                factory.setSchema(schemaFactory.newSchema(schemaFileUrl));
                SAXParser parser = factory.newSAXParser();
                XMLReader reader = parser.getXMLReader();
                // Register the error handler
                reader.setErrorHandler(new JS_ValidationError());
                // Parse the file as the first argument on the command-line
                reader.parse(xmlFilePath);
            catch (SAXException e)
                System.out.println("Error: " + e.getMessage());
                e.printStackTrace();
            } catch (IOException e)
                System.out.println("Error: " + e.getMessage());
                e.printStackTrace();
            } catch (ParserConfigurationException e)
                // TODO Auto-generated catch block
                e.printStackTrace();
      public static void validateXml(Schema schema, String xmlName) {
        try {
          // creating a Validator instance
          Validator validator = schema.newValidator();
          // preparing the XML file as a SAX source
          SAXSource source = new SAXSource(
            new InputSource(new java.io.FileInputStream(xmlName)));
          // validating the SAX source against the schema
          validator.validate(source);
          System.out.println();
          System.out.println("Validation passed.");
        } catch (Exception e) {
          // catching all validation exceptions
          System.out.println();
          System.out.println(e.toString());
      public static Schema loadSchema(String name) {
        Schema schema = null;
        try {
          String language = XMLConstants.W3C_XML_SCHEMA_NS_URI;
          SchemaFactory factory = SchemaFactory.newInstance(language);
          schema = factory.newSchema(new File(name));
        } catch (Exception e) {
          System.out.println(e.toString());
        return schema;
    }

  • Schema Validation with Java and Document object

    Hi, I am working on a project that will validate an xml Document object from a child class. I seem to have completed XSD validation with new DOMSource(doc) and using schema factory, which doesn't support DTD validation. And now I am attempting to validate the DTD. It seems like all the examples I've seen are trying to parse files, and I am struggling with finding a way to validate it directly against the document object.
    The child class creates the xml document which is passed back to the parent class, and I need to do the validation in the parent class, so I need away to validate against the document object. This will be an assertion in Fitnesse if anyone is familar with it.
    private void doSchemaValidationCommand(int rowCount, Document doc, String xpathExpression)
             String validationPath = getText(rowCount,1);
             String extensionSeparator = ".";
             Boolean error = false;
             String ext = null;
             try
             int dot = validationPath.lastIndexOf(extensionSeparator);
            ext = validationPath.substring(dot + 1);
             catch(Exception e)
                  this.wrong(rowCount, 1, e.getMessage());
             if (ext.equalsIgnoreCase("xsd"))
             try {
             SchemaFactory factory =
                SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
            File schemaLocation = new File(validationPath);
            Schema schema = factory.newSchema(schemaLocation);
            Validator validator = schema.newValidator();
            try {
                validator.validate(new DOMSource(doc));
            catch (SAXException ex) {
                this.wrong(rowCount, 1, ex.getMessage());
                error = true;
            catch (IOException ex)  {
                 this.wrong(rowCount, 1, ex.getMessage());
                 error = true;
           catch (SAXException ex) {
               this.wrong(rowCount, 1, ex.getMessage());
               error = true;
           catch (Exception ex){
                this.wrong(rowCount, 1, ex.getMessage());
                error = true;
             else if (ext.equalsIgnoreCase("dtd"))
                  try {
             }

    I tried this but it doesn't give me any validation of whether or not it was completed successfully, it just adds a tag for the dtd to the xml and doesn't seem to do anything further with it, am I missing any steps?
    else if (ext.equalsIgnoreCase("dtd"))
                  try {
                       DOMSource source = new DOMSource(doc);
                       StreamResult result = new StreamResult(System.out);
                       TransformerFactory tf = TransformerFactory.newInstance();
                       Transformer transformer = tf.newTransformer();
                       transformer.setOutputProperty(OutputKeys.DOCTYPE_SYSTEM, validationPath);
                       transformer.transform(source, result);
                  catch(Exception e)
                       this.wrong(rowCount, 1, e.getMessage());
                       error = true;
             }Edited by: sarcasteak on Apr 13, 2009 1:33 PM

  • Is schema validation on JDK 1.3.1 possible ?

    Hi
    I'm trying to get an XML parser to work on 1.3.1 with Schema validation.
    API xerces.jar doesn't seem to handle schema validation in that version.
    I tried my project with xercesImpl.jar on 1.4.2_09 => schema validation worked well.
    I tried xerces.jar on 1.3.1 => doesn't run
    Is there a .jar that can handle schema validation in 1.3.1 ?
    Thanks
    Montelieri

    Hey.
    In looking at their site, xerces 1.4.4 is the latest release, and is the one that provides support for XML Schema Version 1.0. This version likely requires JDK 1.4.x. You should double check the readme file in the dl.
    http://xml.apache.org/xerces-j/index.html
    Not a definate answer, but hope it helps anyway.
    Cheers.

  • Excel cannot open the new form. The Form contains schema validation errors.

    i am running the approval workflow on a document library, while trying to open Excel
    file i get the error.
    Excel cannot open the new form. The Form contains schema validation errors.
    Detailed error:
    Element '{http://schemas.microsoft.com/office/infopath/2009/WSSList/dataFields}Body' is
    unexpected according to content model of parent element '{http://schemas.microsoft.com/office/infopath/2009/WSSList/dataFields}SharePointListItem_RW'.<o:p></o:p>
    Expecting: {http://schemas.microsoft.com/office/infopath/2009/WSSList/dataFields}WorkflowLink,
    {http://schemas.microsoft.com/office/inf....
    neeraj

    Hi,
    According to your description, my understanding is that when you are running approval workflow and opening the Excel file, then it will occur the error above.
    For a better troubleshooting, I suggest you can try to create a new normal excel file and then run the workflow and open the file to test if it works. It will help to figure out if this is the file itself issue or the SharePoint issue.
    Also, please provide some more detailed information such as screen capture, it will easier to find the root cause of the issue.
    Thanks
    Best Regards
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • Trouble with notifications - failed schema validation

    I am trying to send an Email notification from a workflow and am getting the following error:
    System.Web.Services: System.Web.Services.Protocols.SoapException: The request failed schema validation: The element 'Message' in namespace 'http://schemas.microsoft.com/exchange/services/2006/types' has invalid child element 'Header' in namespace 'http://schemas.xmlsoap.org/soap/envelope/'.
    List of possible elements expected: 'Sensitivity, Body, Attachments, DateTimeReceived, Size, Categories, Importance, InReplyTo, IsSubmitted, IsDraft, IsFromMe, IsResend, IsUnmodified, InternetMessageHeaders, DateTimeSent, DateTimeCreated, ResponseObjects,
    ReminderDueBy, ReminderIsSet, ReminderMinutesBeforeStart, DisplayCc, DisplayTo, HasAttachments, ExtendedProperty, Culture, Sender, ToRecipients, CcRecipients, BccRecipients, IsReadReceiptRequested, IsDeliveryReceiptRequested, ConversationIndex, ConversationTopic,
    From, InternetMessageId, IsRead, IsResponseRequested, References, ReplyTo' in namespace 'http://schemas.microsoft.com/exchange/services/2006/types'.
       at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
       at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
       at Microsoft.ResourceManagement.WebServices.Mail.Exchange.ExchangeServiceBinding.CreateItem(CreateItemType CreateItem1)
       at Microsoft.ResourceManagement.Mail.ExchangeProxy.ExecuteCreateItem(CreateItemType request)
       at Microsoft.ResourceManagement.Mail.ExchangeServer.SendNotification(NotificationMessage message)
       at Microsoft.ResourceManagement.Mail.NotificationMessage.Send(Int32 timeoutInMilliseconds)
       at Microsoft.ResourceManagement.Workflow.Hosting.SendMailWorkItemProcessor.SendMailMessage(MessageContent messageContent, Int32 timeoutInMilliseconds)
       at Microsoft.ResourceManagement.Workflow.Hosting.SendMailWorkItemProcessor.ProcessWorkItem(WorkItem workItem
    It appears that the Exchange web service doesn't like the schema FIM is presenting. Anyone seen this? Is there a trace setting that will dump out the call to the Exchange
    server?
    I have tested that I can hit
    https://fqdn_server/ews/exchange.asmx
    from the FIM Service account and the certificate is correct.

    After getting product support involved, it turns out that we were pointing the FIM Service at an Exchange 2013 server but the mailbox had been created on and was physically stored on an Exchange 2010 server. By pointing FIM at the 2010 server or by trying
    to send notifications to mailboxes on the 2013 server, we could make it work. Moving the mailbox from the 2010 server to the 2013 server did not solve the problem. It had something to do with mailboxes that were originally created on a 2010 server but
    were accessed over EWS from a 2013 server.
    It also was not a FIM issue. We used an EWS diagnostic tool (EWSEditor) to test outside of FIM and saw the same results.
    The final result to get the specific user working for notifications was to create a new mailbox for them on the Exchange 2013 server.

  • Schema Validation Questions

    I'm not really sure if this is the proper forum, so please advise if I got that wrong.
    I'm quite the newbie on schema validations, but have had some success using them.  In the past, I've used tools such as XRay and Editix to do this.  Now I'm experimenting with doing this in my c# project using the XmlSchemaSet.
    One thing I have noticed, regardless of which tool being used, is that if namespaces don't match, the validation seems to give a "false positive", as it reports successful validation even if there are missing nodes as per the schema.
    It seems like if the namespaces don't match, the validation should either fail and advise of that, or ignore the namespaces and use the schema to simply validate against the xml being supplied.  It is misleading to report a successful validation just
    because the namespaces don't match.
    Am I totally misunderstanding this topic?  Are there any articles you can recommend to learn this stuff?
    Thanks for any help...
    Ron Mittelman

    Hello Ron,
    I am not familiar with XRay and EditiX, while for the xmlschemaset class, it is by designed that when validating a document the target namespace of the document must match the target namespace of the schema in the schema set, for details, you could check
    this article:
    XML Schema (XSD) Validation with XmlSchemaSet
    Or it will perform the behavior which seems to be false positive.
    Regards.
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Xmlparser_v2_1_0 beta - Schema validation

    I downloaded the beta java version of the xmlparser_v2_1_0.tar. In this version the classes for XSDBuilder and XMLSchema are not there. There is a class called XSDFactory however. The documentation that came with the download seems dated for it still contains the XSDBuilder and XSDSchema classes. Also the sample code contained no examples of how to use the XSDFactory class.
    I am trying to parse an XML doc using the SAXParser and want to validate it against a Schema. Am I using the right version of the XDK? Where are samples of schema validation located? I have looked through the Sample Code in the OTN pages and did not see any.

    Venator85 wrote:
    iphitus wrote:That said... to get that behaviour, add net-profiles and then net-auto to rc.conf, and change line 40 in /usr/bin/netcfg-wireless-auto from "netcfg2 $found" to "netcfg2 -c $found".
    Sorry, I was not meaning this. I was asking this because at home I have both wired and wireless connection, so the two profiles would be both activated, but I'd like to 'prioritize' the wired profile. I was thinking of letting net-profiles activate the wired profile but, if in case the cable was disconnected, to call net-auto to try the wireless. Note that the wireless should't be tried at all if the wired profile suceeds.
    This said, how do you test if any profile on any interface is active?
    Thanks for you help and your patience...
    Bye
    Oh, network priorities and heuristics of profiles is beyond netcfg, though I'm waiting for someone to write a really nice profile manager/autodetector that does all that
    An easy way to check is to use the functions in /usr/lib/network/network.subr under "Query". For example:
    source /usr/lib/network/network.subr
    if check_iface wlan0; then
    echo "oh no! a connected profile is using wlan0!"
    prof=$(get_iface_prof wlan0)
    echo "haha! The profile using it is: $prof"
    netcfg2 -d $prof
    else
    echo "yay wlan0 is free"
    fi
    if check_profile homewireless; then
    echo "/etc/network.d/homewireless is connected!!!"
    fi
    And there's a few more functions. You can also just check for file existance in /var/run/network/.. though the above are a bit easier. There's various useful wireless functions in /usr/lib/network/wireless.subr too... and some others in the other files.
    There's some cool stuff you can do with those functions. On my laptop, my xinitrc checks what network I'm connected to (check_profile). If i'm at uni, it starts up open office. If i'm at home, it'll start up pidgin.
    Last edited by iphitus (2008-06-28 10:11:12)

Maybe you are looking for