0 Replies Latest reply on Dec 12, 2006 7:39 AM by Sreejith PS

    Java Persistence : EntityMananger Lifetime

    Sreejith PS Newbie

      Hi,
      I am new to Persistence. I would like to know is there restrictions in the declaration of EntityManger and EntityManagerFactory in the class, ie can I declare it as an instance variable or should I declare it locally on each method and after the operation performed should I close it? Is there any performance issue or any other problems in doing so? Can anybody give a solution. The solution to this will be greatly appreciated.

      Thanks,
      Sreejith