RE: Starting a keel/avalon component/model automatically

"Louis Moore" <[email protected]> Thu, 15 Jul 2004 17:45:40 -0700
Newsgroups gmane.comp.java.keel.user
Message-ID <C5E6D04B7C014946B7CCBFC2AF30DB62C096DE@corpmail01.corp.walmart.com>
Your config looks right. Try having your component implement
Initializable instead of Startable, that's how my service that starts up
on the first model access works.

-Lou



-----Original Message-----
From: user-keelframework.org-admin-rI8AND0JKYOgdSakss0wQjfEH8FBEnyy@public.gmane.org
[mailto:user-keelframework.org-admin-rI8AND0JKYOgdSakss0wQjfEH8FBEnyy@public.gmane.org] On Behalf
Of Nathan Kontny
Sent: Thursday, July 15, 2004 4:47 PM
To: user-6VIttnCrOeJXNEnpj1eHPNi2O/[email protected]
Subject: RE: [Keel User] Starting a keel/avalon component/model
automatically

Lou, can you please speak some more on this.  So in my Xdoclet meta data
of my
model that I would like to activate on startup, I have the
activation="startup"
attribute.  I checked the merged system.xconf, and now I see this in
there: 

<iron.close-auctions logger="iron" activation="startup"
id="iron.close-auctions"></iron.close-auctions>
    
But it isn't working yet.  This should startup when I access any model
in my
system right?  Does that model have to implement Startable? 

Thank you, 
Nate


Quoting Louis Moore <[email protected]>:

> You can define activation for a component in its system.xconf file. If
> you want it to startup when the server does, do something like this
(I'm
> not sure but you might be able to do it in the metadata for your class
> instead as well):
> 
> <keel>
> 
> <my-component id="my-component-id" activation="startup"
> logger="my-component-logger">
> </my-component>
> 
> </keel>
> 
> hth,
> Lou
> 
> -----Original Message-----
> From: user-keelframework.org-admin-rI8AND0JKYOgdSakss0wQjfEH8FBEnyy@public.gmane.org
> [mailto:user-keelframework.org-admin-rI8AND0JKYOgdSakss0wQjfEH8FBEnyy@public.gmane.org] On
Behalf
> Of maxxam-cuDQgYkrLFxfAa1EqD/[email protected]
> Sent: Thursday, July 15, 2004 2:55 PM
> To: user-keelframework.org-rI8AND0JKYOgdSakss0wQjfEH8FBEnyy@public.gmane.org
> Subject: [Keel User] Starting a keel/avalon component/model
> automatically
> 
> Hi,
> 
> I have an application which receives JMS messages (from an external
> system) which in turn needs to call a keel model/s. I have a class
that
> implements the JMS queue receive and I need this class to start up
> automatically after the server is started. At present I am starting it
> by
> manually opening a jsp page that calls a keel model which in turn
> instantiates my object.
> 
> I have tried implementing the Startable interface hoping that
> Avalon/keel
> will start my component for me - I really don't have a good idea at
all
> about how this Avalon stuff works! No luck so far.
> 
> I guess that it is possible to start components automatically as the
> quartz scheduler somehow starts up but I can't figure out how it
manages
> to do this.
> 
> Can anyone help please.
> Max
> _______________________________________________
> User mailing list
> [email protected]
> http://lists.keelframework.org/listinfo.cgi/user-keelframework.org
> 
> _______________________________________________
> User mailing list
> [email protected]
> http://lists.keelframework.org/listinfo.cgi/user-keelframework.org
> 


_______________________________________________
User mailing list
[email protected]
http://lists.keelframework.org/listinfo.cgi/user-keelframework.org