Hello Leif!
1)
The matter has attracted my interest too.
Please tell me, what did you end up with?
If I understand correctly you wanted your
system not to startup if any of the components
failed to initialize and you wanted
the log to be quite, right?
So, what do you do now?
Pass in your own CommandFailureHandler that returns true
for PrepareHandlerCommand?
2)
Looks like the current Fortress is sort out of line now:
* if initialization fails for an inline-initialized
component the system just refuses to startup
(although the stack traces are still long) -
an exception is thrown from AbstractContainer.initialize()
* if initialization fails for a background-initialized
component the system runs up (with the default
CommandFailureHandler)
Am I correct?
There was an idea of using the CommandFailureHandler
for the AbastractContainer.initialize() too, wasn't it?
Is it still "on the table"?
If yes, how do we pass this handler to the container,
it seems
* not proper in contextualize() - not a constant
* a bit more proper service() ? But still somewhat
awkward...
3)
BTW if this handler is to be made available to
AbstractContainer the CommandFailureHandler
interface seems too general - we do not need
to handle general Command failures but specifically
component configuration/initialization exceptions..
This has all set me up thinking on the matter...
4)
LM> config.setCommandFailureHandlerClass( String );
How about adding
FortressConfig.setCommandFailureHandler( CommandFailureHandler )
for symmetry?
- Anton
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]