2 Replies Latest reply on Sep 4, 2008 1:19 PM by skajotde

    Stateful SB Passivation

    freejohn22

      Hi all !
      I'd like to know, is it possible to passivate a Stateful SB programmatically, so that you can save resources from the AS ?
      thanks
      john

        • 1. Re: Stateful SB Passivation

          no as far as you know you can't. But why worring ? the AS takes care of saving resources. You can fine tune the idle time with the @CacheConfig annotation. The idleTimeoutSeconds parameter configures the amount of idle time before the bean is passivated and the removalTimeoutSeconds configures the amount of idle time before the bean is permanently removed.

          • 2. Re: Stateful SB Passivation
            skajotde

            In EJB container passivation is invoked by container. If you make public method with annotation @Passivate I think you make them additionally invoke. But look out that this method maybe additional twice invoked by container so it should be written in safe style to check it is second time pasivation...