Fw: Failed to load domain and/or its maps/nodes

From: Troy McKinnon (tmckinno..rise.com)
Date: Mon Mar 31 2003 - 19:27:55 EST

  • Next message: Dave Paules: "RE: Failed to load domain and/or its maps/nodes"

    I have been trying to get this on my own... but I feel I have hit the wall, and would appreciate any input.

    I am getting the following error:

    ERROR Configuration: Error initializing shared Configuration
    org.objectstyle.cayenne.ConfigException: [org.objectstyle.cayenne.conf.DefaultConfiguration] : Failed to load domain and/or its maps/nodes.
     at org.objectstyle.cayenne.conf.RuntimeLoadDelegate.finishedLoading(RuntimeLoadDelegate.java:420)
     at org.objectstyle.cayenne.conf.ConfigLoader.loadDomains(ConfigLoader.java:125)
     at org.objectstyle.cayenne.conf.Configuration.init(Configuration.java:278)
     at org.objectstyle.cayenne.conf.Configuration.initSharedConfig(Configuration.java:228)
     at org.objectstyle.cayenne.conf.Configuration.initSharedConfig(Configuration.java:219)
     at org.objectstyle.cayenne.conf.Configuration.initSharedConfig(Configuration.java:197)
     at org.objectstyle.cayenne.conf.Configuration.getSharedConfig(Configuration.java:168)
     at org.objectstyle.cayenne.access.DataContext.createDataContext(DataContext.java:155)

    I debugged the source code and it looks like my issue is with the sax XMLParser/Impl.
    I am using java version 1.4.1_02 and think this might be the issue?

    My xml files are all being loaded correctly, I have verified this by outputting the file data from the cayenne.util.ResourceLocator.findResourceStream() using the URL found there.

    Should I roll back to a specific version of java or am I doing something else wrong.

    I am also using Intellij to compile and run the program. I have a simple test class with the following:

    Construct {{{{
        Configuration.bootstrapSharedConfig(this.getClass());
        DataDomain sharedDomain = Configuration.getSharedConfig().getDomain();
    }}}

    I basically can't get past the construct. i.e. createContext()

    I have included my xml files below:

    --------------- cayenne.xml -----------------------
    <?xml version="1.0" encoding="utf-8"?>
    <domains project-version="1.0">
        <domain name="DSHOPZ">
            <map name="DSHOPZMAP" location="DSHOPZMAP.map.xml"/>
            <node name="DSHOPZDATANODE"
                datasource="DSHOPZDATANODE.driver.xml"
                adapter="org.objectstyle.cayenne.dba.oracle.OracleAdapter"
                factory="org.objectstyle.cayenne.conf.DriverDataSourceFactory">
                <map-ref name="DSHOPZMAP"/>
            </node>
        </domain>
    </domains>

    --------------------------------- DSHOPZDATANODE.driver.xml -----------------
    <driver project-version="1.0" class="oracle.jdbc.OracleDriver">
     <url value="jdbc:oracle:thin..XX:1521:XXX"/>
     <connectionPool min="1" max="10" />
     <login userName="XXX" password="XXX"/>
    </driver>

    ------------------------------ DSHOPZMAP.map.xml -------------------------------

    <?xml version="1.0" encoding="UTF-8"?>
    <data-map project-version="1.0">
     <db-entity name="TABLE_1">
      <db-attribute name="ACTIVE" type="CHAR" isMandatory="true" length="1"/>
       ...
      </db-entity>
     <db-entity name="TABLE_2">
                   ...
     </db-entity>
     
    etc etc..

     </data-map>



    This archive was generated by hypermail 2.0.0 : Mon Mar 31 2003 - 19:32:42 EST