Setting Third-Party Saxon parser for parsing xml files

Hi,
          I wish to parse certain xhtml files using saxon parser because that serves our needs. In order to that in tomcat, I used to use the following code -
          System.getProperties().setProperty("javax.xml.parsers.SAXParserFactory","com.icl.saxon.aelfred.SAXParserFactoryImpl");
          System.getProperties().setProperty("javax.xml.transform.TransformerFactory","com.icl.saxon.TransformerFactoryImpl");
          However this does not work in Weblogic 8.1 SP5. Which means, it actually ignores the settings and uses the default parser (which fails to parse the documents).
          I noticed that in weblogic I need to include these in the weblogic-application.xml located under the application/META-INF folder. I update the file with the following -
          <xml>
          <parser-factory>
          <saxparser-factory>com.icl.saxon.aelfred.SAXParserFactoryImpl</saxparser-factory>
          <transformer-factory>com.icl.saxon.TransformerFactoryImpl</transformer-factory>
          </parser-factory>
          </xml>
          Everything was fine and the documents were parsed but for every server start up, I got an error message -
          <Apr 4, 2006 10:34:43 AM EDT> <Error> <HTTP> <BEA-101216> <Servlet: "action" failed to preload on startup in Web application: "HarvesterWeb".
          javax.servlet.UnavailableException: Parsing error processing resource path
          at com.bea.wlw.netui.pageflow.AutoRegisterActionServlet.initModuleConfig
          (AutoRegisterActionServlet.java:416)
          at org.apache.struts.action.ActionServlet.init(ActionServlet.java:470)
          at com.bea.wlw.netui.pageflow.AutoRegisterActionServlet.init(AutoRegisterActionServlet.java:103)
          at javax.servlet.GenericServlet.init(GenericServlet.java:258)
          at com.bea.wlw.netui.pageflow.AutoRegisterActionServlet.init(AutoRegisterActionServlet.java:109)
          at com.bea.wlw.netui.pageflow.PageFlowActionServlet.init(PageFlowActionServlet.java:107)
          at weblogic.servlet.internal.ServletStubImpl$ServletInitAction.run(ServletStubImpl.java:1094)
          at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
          at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
          at weblogic.servlet.internal.ServletStubImpl.createServlet(ServletStubImpl.java:970)
          at weblogic.servlet.internal.ServletStubImpl.createInstances(ServletStubImpl.java:949)
          at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:888)
          at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:3430)
          at weblogic.servlet.internal.WebAppServletContext.preloadServlets(WebAppServletContext.java:3375)
          at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:3356)
          at weblogic.servlet.internal.WebAppServletContext.setStarted(WebAppServletContext.java:6208)
          at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:864)
          at weblogic.j2ee.J2EEApplicationContainer.start(J2EEApplicationContainer.java:2134)
          at weblogic.j2ee.J2EEApplicationContainer.activate(J2EEApplicationContainer.java:2175)
          at weblogic.j2ee.J2EEApplicationContainer.activate(J2EEApplicationContainer.java:2122)
          at weblogic.management.deploy.slave.SlaveDeployer$Application.setActivation(SlaveDeployer.java:3099)
          at weblogic.management.deploy.slave.SlaveDeployer.setActivationStateForAllApplications(SlaveDeployer.java:1768)
          at weblogic.management.deploy.slave.SlaveDeployer.resume(SlaveDeployer.java:351)
          at weblogic.management.deploy.DeploymentManagerServerLifeCycleImpl.resume(DeploymentManagerServerLifeCycleImpl.java:229)
          at weblogic.t3.srvr.SubsystemManager.resume(SubsystemManager.java:136)
          at weblogic.t3.srvr.T3Srvr.resume(T3Srvr.java:965)
          at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:360)
          at weblogic.Server.main(Server.java:32)
          >
          And the server needs to be restarted after every couple of hits(particularly failures).
          Also, my other applications won't deploy throwing the same stack trace.
          At the end of all this, I get this message - Not sure if they are related but
          log4j:WARN No appenders could be found for logger (org.apache.commons.digester.Digester).
          log4j:WARN Please initialize the log4j system properly.
          Any ideas or anyone run into these kind of situations? Moderators, can you please help?

Try the following.
          1. Keep the 3rd party jars in your WLS classpath and not within your ear.
          2. Create an XML Registry through admin console.
          Services->XML.
          3. Enter appropriate values for the following
          Document Builder Factory:
          SAX Parser Factory:
          Transformer Factory:
          4. Restart WLS.
          Refer to this link. http://e-docs.bea.com/wls/docs81/ConsoleHelp/domain_xmlregistrytable.html
          cheers,
          Dips

Similar Messages

  • Sax Parser for loading XML file

    We have a requirment by which we need to load huge XMl file in our DB everyday.
    THe XML file format is like --
    <?xml version="1.0" encoding="UTF-8"?>
    <root>
    <emp>
    <ename>aaa</ename>
    <sal>3000</sal>
    </emp>
    <emp>
    <ename>bbb</ename>
    <sal>5000</sal>
    </emp>
    <dept>
    <name>productiong</name>
    <location>USA</location>
    <dept>
    I have written XMl SAX parser to load this file into DB -
    import org.xml.sax.helpers.DefaultHandler;
    import javax.xml.parsers.SAXParser;
    import javax.xml.parsers.SAXParserFactory;
    import org.xml.sax.XMLReader;
    import org.xml.sax.InputSource;
    import org.xml.sax.SAXException;
    import org.xml.sax.Attributes;
    import java.io.*;
    import java.sql.*;
    import oracle.jdbc.driver.*;
    import oracle.xml.sql.*;
    import oracle.sql.*;
    import oracle.jdbc.*;
    import oracle.jdbc.pool.OracleDataSource;
    import java.util.*;
    public class test extends DefaultHandler
    String thisElement="";
    String table_name="";
    String table_name_2="";
    String sql="";
    String value_clause="";
    StringBuffer value_clauseBuffer;
    String Insert_sql="";
    int flag;
    String columnNames="";
    String questionmarks="";
    static String conStr = "jdbc:oracle:thin:@abcd1234:1521:dss501";
    static Connection conn;
    String arrayValues[] = new String[30];
    int j = 0;
    int emptyElementFlag = 0;
    public SurveyReader() throws SQLException, FileNotFoundException, IOException{
    DBConnect("username", "password");
    public static void DBConnect(String username, String password)
    throws SQLException, FileNotFoundException, IOException {
    DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
    conn = DriverManager.getConnection(conStr, username, password);
    conn.setAutoCommit(true);
    public void startElement(String namespaceURI, String localName,
    String qName, Attributes atts) throws SAXException {
    thisElement = qName;
    if (thisElement!=table_name){
    columnNames = columnNames + ", " + qName;
    questionmarks = questionmarks +", " + "?";
    emptyElementFlag =0;
    public void characters(char[] ch, int start, int length)
    throws SAXException {
    if (thisElement !="root"){     
    if ((length == 0) && (thisElement !="") ){
    table_name = thisElement;
    sql = " Insert into "+ table_name +"(";
    value_clause="";
    value_clauseBuffer =null;
    columnNames = "";
    questionmarks ="";
    j =0;
    if ((length != 0) && (thisElement!="") && (thisElement!=table_name)){
    emptyElementFlag = 1;
    String s = new String(ch, start, length);
    String newString = s.replaceAll("'", "''");
    // String newString = s;
    if (value_clauseBuffer== null){
    value_clauseBuffer = new StringBuffer(newString);
    else{
    value_clauseBuffer.append(newString);
    public void endElement(String namespaceURI, String localName, String qName)
    throws SAXException {
    if (thisElement !="root"){
    if ((!(value_clauseBuffer == null))||((emptyElementFlag ==0) && (qName !=table_name))) {
    try{
    //value_clauseBuffer.append("', '");
    if (value_clauseBuffer == null){
    arrayValues[j]="";
    else{
    arrayValues[j]=""+value_clauseBuffer;
    j = j+1;
    value_clauseBuffer = null;
    emptyElementFlag =0;
    }catch(Exception e){
    System.err.println(e);
    System.exit(2);
    if (qName == table_name){
    if (!(value_clauseBuffer == null)){
    value_clause = "'"+value_clauseBuffer;
    columnNames =columnNames.substring(1, columnNames.length());
    int paramNumber = j;
    questionmarks =questionmarks.substring(1, questionmarks.length());
    sql = sql + columnNames + " ) values (" + questionmarks +"); ";
    Insert_sql=Insert_sql + sql;
    sql = "Begin "+sql + " End; ";
         try{
         PreparedStatement pstat = conn.prepareStatement(sql);
    for (int i=0; i<=j-1; i++ ){
    int k = i+1;
    pstat.setObject(k, arrayValues);
         ResultSet rset = pstat.executeQuery();
         rset.close();
         pstat.close();
    catch (Exception e) {
    System.err.println(e);
    System.out.print("sql " + sql);
    System.exit(1);
    table_name_2 = table_name;
    thisElement = "";
    public static void main (String args[]) {
    XMLReader xmlReader = null;
    System.out.println("Time " + new java.util.Date());
    try {
    SAXParserFactory spfactory = SAXParserFactory.newInstance();
    spfactory.setValidating(false);
    SAXParser saxParser = spfactory.newSAXParser();
    xmlReader = saxParser.getXMLReader();
    xmlReader.setContentHandler(new SurveyReader());
    xmlReader.setErrorHandler(new SurveyReader());
    InputSource source = new InputSource("short.xml");
    xmlReader.parse(source);
    conn.close();
    } catch (Exception e) {
    System.err.println(e);
    System.exit(1);
    This parser takes 2 hours to laod file of size around 8MB.
    ANy suggestions on improving performance of the parser.
    ANy other approach I should be taking to load this file into DB.
    We are using ORacle 9i DB with Character set UTF 8.
    Thanks!

    String buf = (new String(ch, start, length)).trim();
    if (thisElement != "root"){   
    if ((buf.length() == 0) && (thisElement !="") ){
    It run ok!
    Thanks 58871!
    Now, i want to export oracle table to xml file like :
    <?xml version="1.0" encoding="UTF-8"?>
    <root>
    <emp>
    <ename>aaa</ename>
    <sal>3000</sal>
    </emp>
    <emp>
    <ename>bbb</ename>
    <sal>5000</sal>
    </emp>
    </root>
    Can SAX export to xml format?
    Pham Thanh Tung

  • Non-blocking parsing of multiple xml files

    Hi there,
    I'm trying to parse multiple huge XML files concurrently for a query system over multiple xml streaming systems.
    For each huge xml file, I read them into the memory gradually (the new data would cover the old data in the buffer if the buffer is full). Two questions here:
    1. Do I have to set up a socket and write the buffered data to the socket in order to simuate that the parser can parse infinitely? It sounds not good to use socket across two threads just for the "infinite" nature.
    2. I want to simulate concurrently parsing multiple streams. A straightforward way is to have each parser sit in a thread. Is there any otherway that I can put all parsers in one thread and alternately call them? This requires that each individual parser could parse whatever they have seen so far rather and resume when they are called again.
    I'm curiously awaiting for your answers.
    thanks a lot,
    hong

    just taking a guess: create your own reader by extending java.io.Reader ; and let this reader taking care of fetching the data that the parser will use.

  • How to connect to third party using PI for outbound and inbound interfaces

    Hello,
    I have scenarios where I have data coming in from third party EDI subsystem and sent to SAP. And also from SAP to EDI subsystem. We need to send the XMLs to the EDI subsystema nd also receive XMLs.
    Can someone please suggest the ways I can connect to EDI subsytem for both Outbound and Inbound interfaces.
    Thanks

    Hi Prabhu,
    EDI file is different from the normal flat or xml file. Hope you understand the difference.
    Now if your EDI subsytem has the capability of converting the xml file to edi file viceversa then create and receive the xml file from the EDI subsystem. For the xml file you may use the file adapter as an option.
    If it doesnot have the capability then seeburger adapter needs to  be used. This is not an inbuilt adapter. So your company needs to purchase it.
    Regards,
    ---Satish

  • What are the third party tools available for Encryption in Oracle database?

    Dear All,
    Can you please help me with the below question?
    What are the third party tools available for Encryption in Oracle database? Please let me know if you know their feedback and also licensing/cost information

    Why would you spend money to purchase a third-party tool that will be, almost by definition, less secure than the tools inside the product you already own and paid for?
    http://www.morganslibrary.org/reference/pkgs/dbms_crypto.html
    But were I to have any to recommend one I would not do so without knowing information you seem to consider unimportant such as:
    1. Operating system
    2. Database edition and version
    3. What type of data needs to be secured
    4. What level of security is required

  • How can I add my software in Adobe's Third-party plug-ins for Adobe Premiere Pro ?

    Hi,
    Our company have a software called Moyea Importer for Adobe Premiere.
    Moyea Importer for Adobe Premiere is a recommended FLV, MPG, RMVB, HD  video import plugin for Adobe Premiere Pro. This plug-in enables users  to import FLV videos with various codec like AVC/H.264, AAC, Screen  Video, Nellymoser, MP3, PCM, and Sorenson H.263. Besides FLV video, the  plug-in allows AVCHD import and HD video import in MTS, M2TS, TP, TS,  and MKV formats.
    Moyea Importer for Adobe Premiere do not convert your video so it keeps  video quality for you. The plug-in automatically detects the Adobe Premiere versions on your  machine and you can choose the versions to install the plug-in. It  currently supports Adobe Premiere Pro 1.0/1.5/2.0/CS3/CS4 and Elements  3.0/4.0/7.0/8.0.
    I notice in Third-party plug-ins for Adobe Premiere Pro this part, Adobe didn't get any such plug-ins. They only have two file support plug-ins and Moyea Importer can fill the blank.
    Now I want to submit this software on Adobe's site but I don't know where to submit or who I should to contact. Any suggestions? I really need your help and I am sure it is really good software.

    Any suggestion? Admin of this board? Who can help me

  • Third Party Payment Gateway for Physical Services

    I am very curious to learn on the validity of Integrating a Third Party Payment Gateway for offering the Physical services to the app users.
    One of my clients need to integrate a Payment Gateway for the User registration where the User's will be offered to play a physical shooting game upon registration with the app. What is the likelihood of the app rejection in this kind of scenario ?

    Hi Ahmed,
    I don't understand what exactly you need to do on your CSS because, from what you explained, the original URL and the second one are the same, and both requests are even done using SSL.
    Can you be more specific on what are your requirements?
    Daniel

  • How to parse contents from XML file in Java

    Hi All,
    I have a scenario like this . I have one xml file with key value pairs of ( name , URL ) . I have retrieved contents from XML file , now I want to parse these contents and store in a bean object.
    How to parse Contents of XML file??
    Thanks in advance,
    Rajendra.

    Hi All,
    I have a scenario like this . I have one xml file with key value pairs of ( name , URL ) . I have retrieved contents from XML file , now I want to parse these contents and store in a bean object.
    How to parse Contents of XML file??
    Thanks in advance,
    Rajendra.

  • The best third party recovery software for  OS X?

    Can someone please recommend the best third party recovery software for  OS X. Accidentally emtied my trash when I shouldn't have.
    Thank you for your help.

    General File Recovery
    If you stop using the drive it's possible to recover deleted files that have not been overwritten by using recovery software such as Data Rescue II, File Salvage or TechTool Pro.  Each of the preceding come on bootable CDs to enable usage without risk of writing more data to the hard drive.  Two free alternatives are Disk Drill and TestDisk.  Look for them and demos at MacUpdate or CNET Downloads.
    The longer the hard drive remains in use and data are written to it, the greater the risk your deleted files will be overwritten.
    Also visit The XLab FAQs and read the FAQ on Data Recovery.

  • JAXB parsing an incomplete xml file

    hi folks,
    i am trying to parse a incomplete xml file (e.g some attribute and child elements are missing) in order to complete it via jaxb. however, parsing throws a SAXParseException (premature end of file), which interally is marked as unrecoverable, and a unmarshaller isn't capable of returning a result. not even the objects created so far.
    so my question is if there a way of getting the (incomplete) object tree no matter if the parsing was successfully or not. (i am aware of the fact, that this object tree might be invalid)
    cheer, johannes

    Thanks, works like a charm :)
    Another question.
    I have an index.jsp page with an HTML form (a simple "search" form, made of a text area and a submit button). Now, what I want to do is passing the parameter to two distinct servlets, each one dealing with a web service (one with ebay, the other one with last.fm).
    Unfortunately, in the action tag of the form only one value can be specified.
    Any suggestions?

  • Third party sales scenario for Service.

    Dear Friends,
                    Is it possible to create third party sales scenario for Service. If it is possible Please up date me the configuration process.
    Regards,
    Bhanu

    Hi Banu,
    Please go through this link it will help you about third party process in SAP R/3
    You need to create the service material with BANS itemctegory group.
    http://help.sap.com/saphelp_47x200/helpdata/en/dd/560287545a11d1a7020000e829fd11/frameset.htm
    I hope it will help you,
    Regards,
    Murali.

  • Third-party search engines for indexing BI data

    Has anyone had experience using third-party search engines for indexing data in BI7? We are looking into a product by QuePlix that uses a Google search appliance to index data in BI as well as other OLAP tools, and we'd be interested in hearing anyone else who is using QuePlix or any other search tool.
    SAP is working on its own TREX-based search tool, but it looks like it's still a ways off.
    Our goal is near-instant response for search queries - for example, if a user enters a cost center into the search engine, it would bring back financials, headcount, etc. for that cost center.
    Thanks,
    Jason

    The BI Accelerator has been renamed to BW Accelerator (BWA)...
    BWA does index the data - the data is indexed and stored in a proprietary file system on a high speed SAN. This is done because the BWA does not have a database of its own and is designed as an appliance.
    The index file is loaded onto main memory while querying and then TREX searched the indices and the data is returned by the BWA to the OLAP processor.
    The BWA main memory is a FIFO system where the index files are loaded into.
    I have seen TREX being used for metadata but sparingly ... the only place I have seen TREX being used for data is in the BWA. will read through the links on netweaver search technology and see if I can find anything more. thanks for the links...
    Edited by: Arun Varadarajan on Jun 17, 2009 2:07 AM

  • Re : Third-Party Order Processing for Subcontracting ( Enhancement Pack 5)

    Hi,
    In Third-Party Order Processing for subcontracting - Purchase orders for products that are finished by a subcontractor and sent straight to the end customer. PR created in Sales system are processed further in this scenario where you direct your SC Vendor to send the material to your customer.
    Although its a standard third party scenario with sub contracting job involved in it.
    There is not much information we have in SAP help. This is ECC6 Enhancement pack 5 feature.
    If any one has worked on this, I need a process flow to understand this process.
    Response is apprecited,
    Regards,
    Dipak
    Edited by: Dipak Kumar on Apr 13, 2011 6:43 AM
    Any idea is appreciated?

    Hi,
    Here you can treat this two procedures are diffrent
    For Contractor
    Create P.O >> send semifinish goods to vendor
    For sales Point
    Sales order >> PR >> PO >> Vendor invoice reciept >> Customer invoice Issue wrt order.

  • Best Third party Fax Server for integration with SOA

    Hi
    Which is the best third party fax server for integration with SOA ??
    I am having requirement to configure Fax for client..
    Edited by: 910947 on Feb 16, 2012 4:12 AM

    i am having following option
    Using Java API like InterFAX
    or
    Using Fax Server like SilentFax or RightFax
    or
    Using Virtual Fax Server like GreenFax or myfax
    Which is the best solution, i should go for that will best fit with my SOA Suite???

  • XML publisher report not generating output for huge XML files

    Changed Depreciation Projections Report output type to XML.
    Defined a Data Definition and a new Data Template (RTF) for this report.
    Ran the Depreciation Projection Report to generate the XML output.
    Ran the XML Report Publisher report to generate teh PDF/Excel output of the above report.
    Output generated for smaller XML files. When XML size is big, the program is running for hours without generating the output.
    Teh RTF template is basically a matrix report in which the number of columns in the report is based on the number of periods the report is run for.
    The same is not working in the Desktop version also. The system is hanging when i try to view the preview pdf.
    The XML file size is approximately 33 MB.
    Please let me know if there is any way we can increase the memory size to see the output.
    Thanks,
    Ram.

    for publisher use Category: E-Business Suite

Maybe you are looking for

  • HOW CAN I GET MY CHANGE IN PROCESSING(got it)?

    Hi all....    please understand my requiement and get back with your valueble answers... iam having one table control in one of my screen.... in that....table control it contains three fields.... so as we know three columns... middle column is for se

  • ALV ERROR in Function Module Fieldcatlog Merge .

    Hi I have added 2 more fileds in internral table . this is alv report there is no syntax error . i have user function module CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE' EXPORTING i_program_name = w_repid i_internal_tabname = 'T_BSIK' I_STRUCTURE_NAM

  • RFC to RFC testing!!

    Hi, How to test the RFC to RFC scenario? Also the necessary configurations settings on the sender adapter side? Is RFC going to support async mode. Please guide me in this issue. Thanks in Advance, Kiran

  • What happen to my setting??????

    I try to type in this line using the JCE java -classpath ".:/usr/java1.2/jre/lib/ext/jce1_2_2.jar:/usr/java1.2 /e/lib/ext/sunjce_provider.jar" Blowfishkey i got the error Exception in thread "main" java.security.NoSuchAlgorithmException: Algorithm Bl

  • Panel tab navigation using javascript

    hi all, im using jdev 11.1.2.3 version.... i have requirement on navigation .. my use case is i have a table in first tab when ever i select user name in the column(luser name) the tab should navigated  another tab...........