2 Replies Latest reply on Jun 18, 2007 4:47 AM by paata lominadze

    @Predestroy In Stateless Session Bean

    paata lominadze Master

      hi all,
      i have one stateless session bean and into this bean i have one destroy method :

       @PreDestroy
       public void destroy() {
       try {
       sender.disconnect(); // This is my Fuction fot some busness logic
       com.magti.common.srvprov.Constants.printErrorComment("tibrv disconnecting ... ");
       } catch (Exception e) {
       com.magti.common.srvprov.Constants.printErrorComment("error in disconnect");
       }
       }
      

      but when i tried to redeploy my project this method is not called automatically, is there any mistake ????
      also i tried to @Preremove annotation but problem is not resolved.

      i need method which is automatically called by container before redeployment.


      Regards,
      Paata.