views:

32

answers:

1

I have following problem: I'm trying to implement Spring in existing ear application (using Jboss as App Server and Hibernate as ORM). The ear application consists of war(basically few simple servlets), har(hibernate archive which has only the data model-as classes and the corresponding hibernate mapping files - as xmls), sar(only one parsing class as scheduled task). So, I'm interested how can I share the eventual appContext of the har archive in the war (because servlets are retrieving data from the database) and in the sar(because the parser is "filling" the database). On that note, both (war and sar) should use the singleton SessionFactory bean that would be defined in the har's context. A code example or snippet would be highly appreciated.