Re: cayenne.xml not found

From: Michael Gentry (mgentr..asslight.net)
Date: Sun Jul 25 2010 - 17:40:08 UTC

  • Next message: masjab: "Re: cayenne.xml not found"

    I think, in addition to what Evgeny said, that you have to add
    src/main/resources to your Eclipse source path. I don't have my
    Eclipse setup handy at the moment, but I've had to do this in the past
    (manually add it). Also, make sure you have Eclipse set up to
    auto-refresh the Workspace.

    mrg

    On Sun, Jul 25, 2010 at 10:03 AM, masjab <mjabba..astech-solutions.com> wrote:
    >
    > Hey all,
    >
    > I am trying to complete the "getting started" tutorial but I canīt.
    > Everything was easy but when I run the Main.java I get the following error:
    >
    > Exception in thread "main" org.apache.cayenne.ConfigurationException:
    > [v.3.0RC2 Feb 03 2010 13:38:54] Error during Configuration initialization.
    > [v.3.0RC2 Feb 03 2010 13:38:54]
    > [org.apache.cayenne.conf.DefaultConfiguration] : Domain configuration file
    > "cayenne.xml" is not found.
    >        at
    > org.apache.cayenne.conf.Configuration.initializeSharedConfiguration(Configuration.java:168)
    >        at
    > org.apache.cayenne.conf.Configuration.initializeSharedConfiguration(Configuration.java:141)
    >        at
    > org.apache.cayenne.conf.Configuration.initializeSharedConfiguration(Configuration.java:121)
    >        at
    > org.apache.cayenne.conf.Configuration.getSharedConfiguration(Configuration.java:91)
    >        at
    > org.apache.cayenne.access.DataContext.createDataContext(DataContext.java:143)
    >        at org.example.cayenne.Main.main(Main.java:12)
    > Caused by: org.apache.cayenne.ConfigurationException: [v.3.0RC2 Feb 03 2010
    > 13:38:54] [org.apache.cayenne.conf.DefaultConfiguration] : Domain
    > configuration file "cayenne.xml" is not found.
    >        at
    > org.apache.cayenne.conf.DefaultConfiguration.initialize(DefaultConfiguration.java:141)
    >        at
    > org.apache.cayenne.conf.Configuration.initializeSharedConfiguration(Configuration.java:159)
    >        ... 5 more
    >
    >
    > I did search and I saw that I am not the only one...
    > But after readying still donīt know what to do.
    >
    >
    > In Eclipse the cayenne.xml is in src/main/resources
    > My pom.xml looks like this:
    >
    > <project xmlns="http://maven.apache.org/POM/4.0.0"
    > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    > xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
    > http://maven.apache.org/xsd/maven-4.0.0.xsd">
    >  <modelVersion>4.0.0</modelVersion>
    >  <groupId>org.example.cayenne</groupId>
    >  <artifactId>tutorial</artifactId>
    >  <version>0.0.1-SNAPSHOT</version>
    >
    >  <dependencies>
    >                <dependency>
    >                        <groupId>org.apache.cayenne</groupId>
    >                        <artifactId>cayenne-server</artifactId>
    >   <!-- Here specify the version of Cayenne you are actually using -->
    >                        <version>3.0RC2</version>
    >                </dependency>
    >
    >                <dependency>
    >                        <groupId>mysql</groupId>
    >                        <artifactId>mysql-connector-java</artifactId>
    >                        <version>5.1.13</version>
    >                </dependency>
    >        </dependencies>
    > </project>
    >
    >
    > The tables are created in my database, no prob...
    >
    > THX 2 ALL Your HELP
    >
    >
    >
    > --
    > View this message in context: http://cayenne.195.n3.nabble.com/cayenne-xml-not-found-tp993821p993821.html
    > Sent from the Cayenne - User mailing list archive at Nabble.com.
    >



    This archive was generated by hypermail 2.0.0 : Sun Jul 25 2010 - 17:40:58 UTC