Did you generate code in your core module and run "mvn install"? Matt
On 10/29/07, mschipperheyn <[EMAIL PROTECTED]> wrote: > > You're right! Well, off course. So, now, when I run the same command from the > web directory, I get the error message that I mentioned in my initial post. > The Archive reference is actually the first element in the list of Pojos in > my hibernate.cfg.xml. > > > [INFO] Unable to load class declared as <mapping class="xyz. > model.Archive"/> in the configuration: > [INFO] > ------------------------------------------------------------------------ > [INFO] Trace > org.hibernate.MappingException: Unable to load class declared as <mapping > class= > "xyz.model.Archive"/> in the configuration: > at > org.hibernate.cfg.AnnotationConfiguration.parseMappingElement(Annotat > ionConfiguration.java:545) > at > org.hibernate.cfg.Configuration.parseSessionFactory(Configuration.jav > a:1479) > > > > mraible wrote: > > > > You should use the simple name of your class, not the fully-quallified > > name. In your case, you should use "Barr". > > > > Matt > > > > On 10/29/07, mschipperheyn <[EMAIL PROTECTED]> wrote: > >> > >> So, the above error occurs when I run appfuse:gen from the web dir. WhenI > >> run > >> it from the core dir, I get this error: > >> > >> What is the name of your pojo (i.e. Person)?: > >> nl.msw.compraventa.core.model.Barr > >> io > >> [INFO] Configuration XML file loaded: > >> D:\Java\Projects\CompraVenta\core\src\main > >> \resources\hibernate.cfg.xml > >> [INFO] Configuration XML file loaded: > >> D:\Java\Projects\CompraVenta\core\src\main > >> \resources\hibernate.cfg.xml > >> [INFO] src/main/resources/database.properties not found within the > >> project. > >> Tryi > >> ng absolute path. > >> [INFO] No hibernate properties file loaded. > >> [info] [AppFuse] Installing generated files (pattern: **/*.java)... > >> [INFO] > >> ------------------------------------------------------------------------ > >> [ERROR] FATAL ERROR > >> [INFO] > >> ------------------------------------------------------------------------ > >> [INFO] D:\Java\Projects\CompraVenta\core\target\appfuse\generated-sources > >> not fo > >> und. > >> [INFO] > >> ------------------------------------------------------------------------ > >> [INFO] Trace > >> D:\Java\Projects\CompraVenta\core\target\appfuse\generated-sources not > >> found. > >> at > >> org.apache.tools.ant.types.AbstractFileSet.getDirectoryScanner(Abstra > >> ctFileSet.java:349) > >> at org.apache.tools.ant.taskdefs.Copy.execute(Copy.java:404) > >> at > >> org.appfuse.tool.ArtifactInstaller.copyGeneratedObjects(ArtifactInsta > >> ller.java:116) > >> at > >> org.appfuse.tool.ArtifactInstaller.execute(ArtifactInstaller.java:44) > >> > >> at > >> org.appfuse.mojo.exporter.AppFuseGeneratorMojo.doExecute(AppFuseGener > >> atorMojo.java:260) > >> at > >> org.appfuse.mojo.HibernateExporterMojo.execute(HibernateExporterMojo. > >> java:138) > >> at > >> org.appfuse.mojo.exporter.AppFuseGeneratorMojo.execute(AppFuseGenerat > >> orMojo.java:204) > >> at > >> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPlugi > >> nManager.java:443) > >> at > >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa > >> ultLifecycleExecutor.java:539) > >> at > >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandalone > >> Goal(DefaultLifecycleExecutor.java:493) > >> at > >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defau > >> ltLifecycleExecutor.java:463) > >> at > >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan > >> dleFailures(DefaultLifecycleExecutor.java:311) > >> at > >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen > >> ts(DefaultLifecycleExecutor.java:278) > >> at > >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi > >> fecycleExecutor.java:143) > >> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:334) > >> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:125) > >> at org.apache.maven.cli.MavenCli.main(MavenCli.java:272) > >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > >> at > >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. > >> java:39) > >> at > >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces > >> sorImpl.java:25) > >> at java.lang.reflect.Method.invoke(Method.java:597) > >> at > >> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) > >> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) > >> at > >> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) > >> > >> at org.codehaus.classworlds.Launcher.main(Launcher.java:375) > >> > >> > >> could it be that I need to create a seperate hibernate properties file, > >> b/c > >> I have all my hibernate properties and database connection stuff in a > >> spring > >> applicationcontext.xml file? > >> > >> Cheers, > >> > >> Marc > >> -- > >> View this message in context: > >> http://www.nabble.com/app%3Agen--Unable-to-load-class-declared-as-mapping-class%3D%22xyz%22-in-the-configuration-tf4700458s2369.html#a13470583 > >> Sent from the AppFuse - User mailing list archive at Nabble.com. > >> > >> --------------------------------------------------------------------- > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > > > > > > -- > > http://raibledesigns.com > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > > The hibernate part of my applicationcontext.xml looks like this > > <bean id="sessionFactory" > > class="org.springframework.orm.hibernate3.LocalSessionFactoryBean"> > <property name="configLocation"> > <value>classpath:hibernate.cfg.xml</value> > </property> > <property name="hibernateProperties"> > <ref bean="hibernateProperties" /> > </property> > <property name="dataSource"> > <ref bean="MyDataSource" /> > </property> > <property name="configurationClass"> > > <value>org.hibernate.cfg.AnnotationConfiguration</value> > </property> > </bean> > > <bean id="hibernateProperties" > > class="org.springframework.beans.factory.config.PropertiesFactoryBean"> > <property name="properties"> > <props> > <prop > key="hibernate.hbm2ddl.auto">update</prop> > <prop key="hibernate.dialect"> > org.hibernate.dialect.MySQLDialect > </prop> > <prop key="hibernate.show_sql">true</prop> > <prop > key="hibernate.c3p0.minPoolSize">5</prop> > <prop > key="hibernate.c3p0.maxPoolSize">20</prop> > <prop key="hibernate.c3p0.timeout">600</prop> > <prop > key="hibernate.c3p0.max_statement">50</prop> > <prop > key="hibernate.c3p0.testConnectionOnCheckout"> > false > </prop> > </props> > </property> > </bean> > > <bean id="propertyConfigurer" > > class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"> > <property name="locations"> > <list> > <value>classpath:jdbc.properties</value> > <value>classpath:mail.properties</value> > </list> > </property> > </bean> > > <bean id="MyDataSource" > > class="org.springframework.jdbc.datasource.DriverManagerDataSource"> > <property name="driverClassName" > value="${jdbc.driverClassName}" /> > <property name="url" value="${jdbc.url}" /> > <property name="username" value="${jdbc.username}" /> > <property name="password" value="${jdbc.password}" /> > </bean> > > <bean id="hibernateTemplate" > class="org.springframework.orm.hibernate3.HibernateTemplate"> > <property name="sessionFactory"> > <ref bean="sessionFactory" /> > </property> > </bean> > > <bean id="hibernateInterceptor" > > class="org.springframework.orm.hibernate3.HibernateInterceptor"> > <property name="sessionFactory"> > <ref bean="sessionFactory" /> > </property> > </bean> > > Cheers, > > Marc > -- > View this message in context: > http://www.nabble.com/app%3Agen--Unable-to-load-class-declared-as-mapping-class%3D%22xyz%22-in-the-configuration-tf4700458s2369.html#a13470902 > Sent from the AppFuse - User mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- http://raibledesigns.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
