Re: Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
Hvala! :) From: Boris Horvat To: Tapestry users ; Andjela Djenic Sent: Friday, May 17, 2013 12:06 AM Subject: Re: Unknown entity and SessionFactory null Srecno u projektu... Zanimljivo da se tapestry radi sada na fon-u ja sam ga radio u 4toj On Fri

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Boris Horvat
Srecno u projektu... Zanimljivo da se tapestry radi sada na fon-u ja sam ga radio u 4toj On Fri, May 17, 2013 at 12:02 AM, Andjela Djenic wrote: > It was wrong hibernate mapping. It works now without adding entities to > hibernate.config.xml and without adding the contribution > to Hibernate

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
It was wrong hibernate mapping. It works now without adding entities to hibernate.config.xml and without adding the contribution to  HibernateEntityPackageManager class.  I know that tapestry-hibernate covers tapestry-core and tapestry-hibernate-core, but for some reason my app won't work with t

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Thiago H de Paula Figueiredo
On Thu, 16 May 2013 18:18:37 -0300, Boris Horvat wrote: This error looks to be generic to hibernate. Basically you have mapped the objects wrong do the inheritance. Definitely a pure Hibernate error (specifically mapping) completely unrelated to Tapestry. -- Thiago H. de Paula Figueire

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Boris Horvat
rom:* Boris Horvat > > *To:* Tapestry users ; Andjela Djenic < > > andjel...@yahoo.com> > > *Sent:* Thursday, May 16, 2013 9:46 PM > > *Subject:* Re: Unknown entity and SessionFactory null > > > > Can you try adding in AppModule.jav

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
Here's the link to console output http://justpaste.it/2n2r Thanks, Angela From: Boris Horvat To: Andjela Djenic Cc: Tapestry users Sent: Thursday, May 16, 2013 10:29 PM Subject: Re: Unknown entity and SessionFactory null What exception? On Thu, M

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Boris Horvat
days ago, and I don't know which changes could > disrupt that. > > Thanks, > Angela > > -- > *From:* Boris Horvat > *To:* Tapestry users ; Andjela Djenic < > andjel...@yahoo.com> > *Sent:* Thursday, May 16, 2013 9:46 PM > *Su

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
Thanks, Angela From: Boris Horvat To: Tapestry users ; Andjela Djenic Sent: Thursday, May 16, 2013 9:46 PM Subject: Re: Unknown entity and SessionFactory null Can you try adding in AppModule.java     @Contribute(HibernateEntityPackageManager.class)     pub

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
Thanks Robert, I will take a look.  Angela From: Robert Lentz To: Tapestry users Sent: Thursday, May 16, 2013 9:40 PM Subject: Re: Unknown entity and SessionFactory null Angela, have a look at https://github.com/rlentz/tahi_jndi. This is a very simple

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Robert Lentz
ursday, May 16, 2013 9:14 PM > Subject: Re: Unknown entity and SessionFactory null > > > I don't know about Hibernate, but JPA has an option to either scan for all > the entities, > or provide them in configuration. Perhaps there is the same thing for > Hibernate, > or i

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Boris Horvat
name="hibernate.current_session_context_class">thread > > > > > > I added only one entity to try if it works. > > ________________ > From: Boris Horvat > To: Tapestry users ; Andjela Djenic < > andjel...@yahoo.com>

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
    true         org.hibernate.transaction.JDBCTransactionFactory             thread                          I added only one entity to try if it works.  From: Boris Horvat To: Tapestry users ; Andjela Djenic Sent: Thursday, May 16, 2013 9:32 PM Subject: Re: Unknown entity and SessionFact

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Boris Horvat
help folks! > > Angela > > > > From: Lenny Primak > To: Tapestry users > Sent: Thursday, May 16, 2013 9:14 PM > Subject: Re: Unknown entity and SessionFactory null > > > I don't know about Hibernate, but JPA has an option to either scan for all > t

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
e: Unknown entity and SessionFactory null I don't know about Hibernate, but JPA has an option to either scan for all the entities, or provide them in configuration.  Perhaps there is the same thing for Hibernate, or it's turned off somewhere On May 16, 2013, at 3:10 PM, Boris Horv

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
Hi Ken, The entities that I use are in the entities package. From Igor Drobiazko's book: "...by convention, the entities sub-package of the application's package is scanned for persistent classes. Any class annotated with @Entity, @Embeddable or @MappedSuperclass annotation is automatically ad

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Lenny Primak
I don't know about Hibernate, but JPA has an option to either scan for all the entities, or provide them in configuration. Perhaps there is the same thing for Hibernate, or it's turned off somewhere On May 16, 2013, at 3:10 PM, Boris Horvat wrote: > I would be more interested in seeing why

Re: Re : Unknown entity and SessionFactory null

2013-05-16 Thread Boris Horvat
I would be more interested in seeing why doesn't this work out of the box. I also dont provide entities in config.xml instead I let tapestry grab them from my package... On Thu, May 16, 2013 at 8:42 PM, Ken in Nashua wrote: > Hi Angela, > > Looks liek you didnt specify any entities in your hibe

RE: Re : Unknown entity and SessionFactory null

2013-05-16 Thread Ken in Nashua
Hi Angela, Looks liek you didnt specify any entities in your hibernate cfg mapping file. If you model an entity under your model/entity package, yes you need to tell your AppModule.JAVA about that directory... But you also need to tell hibernate about those entities. We do this by specifying t

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
I already tried with that dependency, and it won't work for me. Thanks for the hmac-passphrase. Thanks, Angela 

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Boris Horvat
Try replacing org.apache.tapestry tapestry-core 5.3.6 org.apache.tapestry tapestry-hibernate-core 5.3.6 with org.apache.tapestry tapestry-hibernate 5.3.

Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
All my entities are in myapp/entities package. "By default, the package application-root-package.entities is scanned as described above. If you have additional packages containing entities, you must contribute them to the tapestry.hibernate.HibernateEntityPackageManager service configuration.

Re: Unknown entity and SessionFactory null

2013-05-16 Thread Boris Horvat
Well I dont really see any entities defined in your config. btw did you tell tapestry where to lock for the entities? You should provide an a method in AppModule.java @Contribute(HibernateEntityPackageManager.class) public static void addHibernateEntityPackageManager(Configuration configurati

Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
Here is my hibernate.cfg.xml file: http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd";>             com.mysql.jdbc.Driver         jdbc:mysql://localhost:3306/library         org.hibernate.dialect.MySQLDialect         root         books         update         true         true  

Re : Unknown entity and SessionFactory null

2013-05-16 Thread Ken in Nashua
well its trying to configure from hibernate.cfg.xml did you spell it out properly in the config file ?

Unknown entity and SessionFactory null

2013-05-16 Thread Andjela Djenic
Hi, I'm newbie in Tapestry and Hibernate and I cannot realize why Hibernate don't see my entities. My entity classes have @Entity annotation and are in entities package. Dependencies for hibernate-tapestry that I use:                    org.apache.tapestry             tapestry-core