Results 1 to 3 of 3

Thread: @Interceptors Startup Time

  1. #1

    Default @Interceptors Startup Time

    I have a stateless session bean that utilizes the @Interceptors(SpringBeanAutowiringInterceptor.clas s) annotation. It seems as if the creation of the Spring context does not occur until the 1st usage of a given bean which leads to a startup cost to the first client. Is there any way to pre-init the Spring context?

  2. #2
    Join Date
    Mar 2009
    Posts
    15

    Default

    In your beanRefContext.xml, does setting does setting lazy-init=false on the wrapped context do anything? If not, I bet you could extend the interceptor to fix this.

  3. #3

    Default

    What I found is that, the EJB's do not execute the Intereceptors until the first invocation. So in order to get around this limitation, I create an initial bean pool explicitly and added a PostConstruct method that ensure this initialization occurs.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •