users@glassfish.java.net

RE: Call Constructor of Web Service on Glassfish Container load

From: Patel, Ronak \(US SSA\) <"Patel,>
Date: Wed, 20 Sep 2006 15:28:35 -0400

1. We're using Glassfish-V1 Milestone 7
2. Servlet endpoint
3. We can put together a sample war that illustrates what we're doing. It's really just a simple endpoint with a no-arg constructor or a @PostConstruct annotated method.
 
When the war file is first deployed, does the no-arg constructor or @PostConstruct method get called? All we have is a simple endpoint with a no-arg constructor and it does not get called after deployment. Is there something else that needs to be done after deployment?

        -----Original Message-----
        From: Vijay Ramachandran [mailto:Vijay.Ramachandran_at_Sun.COM]
        Sent: Wed 09/20/2006 03:15 PM
        To: users_at_glassfish.dev.java.net
        Cc:
        Subject: Re: Call Constructor of Web Service on Glassfish Container load
        
        

        This feature should work - if it does not, then it is a bug.
        
        Can you please give us more information :
        
        1. Are you trying with latest GlassFish-v1 or GlassFish-v2 ?
        
        2. What kind of endpoint are you using - servlet or EJB ?
        
        3. Is it possible to mail your sample WAR/JAR ?
        
        Vijay
        
        On Wed, 2006-09-20 at 12:02, Patel, Ronak (US SSA) wrote:
> Hello all,
>
> I just upgraded to the latest Glassfish Milestone build. I am looking for the container to call my no-arg constructor on container load time (i.e. when I start Glassfish).
>
> I tried the <load-on-startup> option in the web.xml file and the @postConstruct annotation, but the container fails to call the constructor when Glassfish starts.
>
> Is there some thing that I am not doing correctly? Is this feature currently supported in Glassfish?
>
> Any help would be greatly appreciated,
>
> Ronak Patel
>
> Software Engineer; BAE Systems
>
> ronak.patel_at_baesystems.com
>
>
> ______________________________________________________________________
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
        
        ---------------------------------------------------------------------
        To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
        For additional commands, e-mail: users-help_at_glassfish.dev.java.net