Hi,
Is it possible to add new persistent classes to an existing SessionFactory? I know you can use the Configuration class to dynamically add mapping files before you create the SessionFactory, but once the SessionFactory is created, is it possible to add new mapping?
In our case, we have some persistent classes which our user may develop and we will load through a URL class loader dynamically to our running system. The mapping file will be generated on the fly. But we are not sure if it's possible to the new mapping files to the existing SessionFactory, or we have to create a new SessionFactory to load the new mapping files. The destroy/recreate of session factory seems to be a little bit expensive to us.
Thanks for your help.
--Jiunjiun
Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp
[b]Hibernate version:[/b]
[b]Mapping documents:[/b]
[b]Code between sessionFactory.openSession() and session.close():[/b]
[b]Full stack trace of any exception that occurs:[/b]
[b]Name and version of the database you are using:[/b]
[b]The generated SQL (show_sql=true):[/b]
[b]Debug level Hibernate log excerpt:[/b]