Hi Andrus,
is there a property in cayenne, witch can be set during initialization of
application, where a Path for the cayenne-Configuration can be stored?
Your mail:
Tue, 27 Jul 2004 10:04:16-0400(Andrus Adamchik[Andrus
Adamchik<andru..bjectstyle.org>]):
> Hi Sarvesh,
>
> > Does this mean that it expects the other xml files to be in the
> > classpath, that is the map.xml and the driver.xml? If so then I have
> > tried that out too and also put the driver jar in the classpath.
> > Could anymore please help me out.
>
> Yes, in standalone applications Cayenne XML files must be accessible
> via CLASSPATH (at least this is the default situation). Looks like
> cayenne.xml file is located properly, however two other files
> (RoleResource.map.xml and Pointbase.driver.xml) are not. Generally if
> you put all three files in the "root" of the CLASSPATH, Cayenne just
> works.
>
> But you are saying you've tried that already... Could you provide some
> details please? Where exactly you store those three files? What is the
> CLASSPATH used? Also before throwing this exception, Cayenne prints
> some startup info. Analyzing that might be helpful too (if it is not
> printed, you can set a higher log level programmatically before loading
> stuff in Cayenne, e.g.: "Configuration.setLoggingLevel(Level.WARN)").
>
> And finally for your evaluation I recommend upgrading to the latest 1.1
> Beta 2. Cayenne 1.1 is so much nicer, and I consider Beta 2 to be
> fairly stable.
>
> Andrus
>
> On Jul 27, 2004, at 4:41 AM, <sarvesh.naid..t.com> wrote:
>
> > Hi,
> > I am completely new to Cayenne, and frankly speaking have found it
> > quite interesting. I am facing a few problems, hope someone can help
> > me out. I have made a simple role schema using cayenne and then mapped
> > the class to that schema. Now I am running it using a standalone
> > application so have written a class which instantiates an the role
> > class and then populates it with some values.
> > Everything complies well, but when I try running it, I realised that
> > the cayenne.xml has to be in the classpath. After doing that, there
> > were some more issues like jaxp-api.jar and sax.jar also are expected.
> > After solving this, now I am getting this error
> >
> > Exception in thread "main"
> > org.objectstyle.cayenne.ConfigurationException: [v.1.0.7 March 27
> > 2004] Error during Configuration initialization. [v.1.0.7 March 27
> > 2004] Load failures. Main configuration class:
> > org.objectstyle.cayenne.conf.DefaultConfigu
> > ration, details:
> > domain.map.name=RoleResource,
> > domain.map.location=RoleResource.map.xml, reason: map location not
> > found
> > domain.node.name=Pointbase,
> > domain.node.datasource=Pointbase.driver.xml, reason: DataSource load
> > failed - [v.1.0.7 March 27 2004] Can't find DataSource configuration
> > file at Pointbase.driver.xml
> > at
> > org.objectstyle.cayenne.conf.Configuration.initializeSharedConfiguratio
> > n(Configuration.java:287)
> > at
> > org.objectstyle.cayenne.conf.Configuration.initializeSharedConfiguratio
> > n(Configuration.java:261)
> > at
> > org.objectstyle.cayenne.conf.Configuration.initializeSharedConfiguratio
> > n(Configuration.java:244)
> > at
> > org.objectstyle.cayenne.conf.Configuration.getSharedConfiguration(Confi
> > guration.java:207)
> > at
> > org.objectstyle.cayenne.access.DataContext.createDataContext(DataContex
> > t.java:151)
> > at test.Main.<init>(Unknown Source)
> > at test.Main.main(Unknown Source)
> > Caused by: org.objectstyle.cayenne.ConfigurationException: [v.1.0.7
> > March 27 2004] Load failures. Main configuration class:
> > org.objectstyle.cayenne.conf.DefaultConfiguration, details:
> > domain.map.name=RoleResource,
> > domain.map.location=RoleResource.map.xml, reason: map location not
> > found
> > domain.node.name=Pointbase,
> > domain.node.datasource=Pointbase.driver.xml, reason: DataSource load
> > failed - [v.1.0.7 March 27 2004] Can't find DataSource configuration
> > file at Pointbase.driver.xml
> > at
> > org.objectstyle.cayenne.conf.RuntimeLoadDelegate.finishedLoading(Runtim
> > eLoadDelegate.java:557)
> > at
> > org.objectstyle.cayenne.conf.ConfigLoader.loadDomains(ConfigLoader.java
> > :117)
> > at
> > org.objectstyle.cayenne.conf.DefaultConfiguration.initialize(DefaultCon
> > figuration.java:185)
> > at
> > org.objectstyle.cayenne.conf.Configuration.initializeSharedConfiguratio
> > n(Configuration.java:279)
> > ... 6 more
> >
> > Does this mean that it expects the other xml files to be in the
> > classpath, that is the map.xml and the driver.xml? If so then I have
> > tried that out too and also put the driver jar in the classpath.
> > Could anymore please help me out.
> > Thanks.
> > Regards,
> > Sarvesh Naidu
> > Wholesale Portal Team
> > British Telecom
>
>
>
-- Viele GrüßeDirk Wellmann ---------------------------- PD Software GmbH Amalung Straße 16 37688 Beverungen
fon.: +49 5275 98 78 0 fax.: +49 5275 98 78 18 mail: d..dsoft.de www: www.pdsoft.de
This archive was generated by hypermail 2.0.0 : Tue Jul 27 2004 - 10:34:42 EDT