Package org.nuxeo.runtime
Class RuntimeMessageHandlerImpl
java.lang.Object
org.nuxeo.runtime.RuntimeMessageHandlerImpl
- All Implemented Interfaces:
ComponentManager.Listener
,RuntimeMessageHandler
public class RuntimeMessageHandlerImpl
extends Object
implements RuntimeMessageHandler, ComponentManager.Listener
Handles runtime messages by taking care of component manager lifecycle in order to work correctly with hot reload.
This is interesting to not store several time the same message in case of hot reload.
- Since:
- 9.10
-
Nested Class Summary
Modifier and TypeClassDescriptionprotected static enum
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Deprecated.void
addMessage
(RuntimeMessage message) Adds the following message.void
addWarning
(String message) Deprecated.void
afterStart
(ComponentManager mgr, boolean isResume) Called just after all components were startedvoid
Called just before activating components.void
Called just before activating components.void
beforeStart
(ComponentManager mgr, boolean isResume) Called just before starting components.void
beforeStop
(ComponentManager mgr, boolean isStandby) Called just before stopping components.protected void
Deprecated.getMessages
(Predicate<RuntimeMessage> predicate) Returns all messages strings, filtered by given predicate.getMessages
(RuntimeMessage.Level level) Returns all messages strings, filtered by given level.getRuntimeMessages
(Predicate<RuntimeMessage> predicate) Returns all messages, filtered by given predicate.Returns all messages, filtered by given level.Deprecated.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.nuxeo.runtime.model.ComponentManager.Listener
afterActivation, afterDeactivation, afterStop, install, uninstall
-
Field Details
-
step
-
messages
-
-
Constructor Details
-
RuntimeMessageHandlerImpl
public RuntimeMessageHandlerImpl()
-
-
Method Details
-
addWarning
Deprecated.Description copied from interface:RuntimeMessageHandler
Warning messages don't block server startup.- Specified by:
addWarning
in interfaceRuntimeMessageHandler
-
getWarnings
Deprecated.- Specified by:
getWarnings
in interfaceRuntimeMessageHandler
- Returns:
- an unmodifiable
List
of warning messages
-
addError
Deprecated.Description copied from interface:RuntimeMessageHandler
Add new error.Error messages block server startup in strict mode.
- Specified by:
addError
in interfaceRuntimeMessageHandler
-
getErrors
Deprecated.- Specified by:
getErrors
in interfaceRuntimeMessageHandler
- Returns:
- an unmodifiable
List
of error messages
-
beforeActivation
Description copied from interface:ComponentManager.Listener
Called just before activating components. This is fired when enteringComponentManager.start()
- Specified by:
beforeActivation
in interfaceComponentManager.Listener
-
beforeStart
Description copied from interface:ComponentManager.Listener
Called just before starting components.- Specified by:
beforeStart
in interfaceComponentManager.Listener
isResume
- true if the event was initiated by aComponentManager.resume()
call, false otherwise.
-
afterStart
Description copied from interface:ComponentManager.Listener
Called just after all components were started- Specified by:
afterStart
in interfaceComponentManager.Listener
isResume
- true if the event was initiated by aComponentManager.resume()
call, false otherwise.
-
beforeStop
Description copied from interface:ComponentManager.Listener
Called just before stopping components.- Specified by:
beforeStop
in interfaceComponentManager.Listener
isStandby
- true if the event was initiated by aComponentManager.standby()
call, false otherwise
-
beforeDeactivation
Description copied from interface:ComponentManager.Listener
Called just before activating components.- Specified by:
beforeDeactivation
in interfaceComponentManager.Listener
-
changeStep
-
addMessage
Description copied from interface:RuntimeMessageHandler
Adds the following message.- Specified by:
addMessage
in interfaceRuntimeMessageHandler
-
getMessages
Description copied from interface:RuntimeMessageHandler
Returns all messages strings, filtered by given level.- Specified by:
getMessages
in interfaceRuntimeMessageHandler
-
getMessages
Description copied from interface:RuntimeMessageHandler
Returns all messages strings, filtered by given predicate.- Specified by:
getMessages
in interfaceRuntimeMessageHandler
-
getRuntimeMessages
Description copied from interface:RuntimeMessageHandler
Returns all messages, filtered by given level.- Specified by:
getRuntimeMessages
in interfaceRuntimeMessageHandler
-
getRuntimeMessages
Description copied from interface:RuntimeMessageHandler
Returns all messages, filtered by given predicate.- Specified by:
getRuntimeMessages
in interfaceRuntimeMessageHandler
-