Startup code [message #26554] |
Mon, 21 May 2007 17:17 |
Eclipse User |
|
|
|
Originally posted by: kendotlarson.mindspring.com
I'm looking to run some code right away when my RAP application is
loaded, before the IEntryPoint even gets called. Any pointers on how to
do this?
Thanks,
Ken Larson
|
|
|
|
Re: Startup code [message #26646 is a reply to message #26613] |
Tue, 22 May 2007 06:37 |
Eclipse User |
|
|
|
Originally posted by: fappel.innoopract.com
Hi,
the static initializer code of Roberto will work if you need an let me call
it 'application scope one time setup mechanism'. Nevertheless I think that
static initializers are a little bit unpractically and inflexible in case
that larger initialization steps are needed. But that may only be a question
of taste.
The standard java web-app approach would be to use an ServletContextListener
implementation that will be executed at application startup. Unfortunately
and as far as I know there is no such mechanism provided by the
OSGi-http-service yet. It should not be that difficult to map the context
listener calls into the OSGi instance, but that's something you'd better ask
the equinox-folks.
Ciao
Frank
"Roberto S
|
|
|
Powered by
FUDForum. Page generated in 0.03484 seconds