Class BundleStartTask
java.lang.Object
org.apache.sling.installer.api.tasks.InstallTask
org.apache.sling.installer.core.impl.AbstractInstallTask
org.apache.sling.installer.core.impl.tasks.AbstractBundleTask
org.apache.sling.installer.core.impl.tasks.BundleStartTask
- All Implemented Interfaces:
Comparable<InstallTask>
Start a bundle given its bundle ID
Restarts if the bundle does not start on the first try,
but only after receiving a bundle or framework event,
indicating that it's worth retrying
-
Field Summary
Fields inherited from class org.apache.sling.installer.core.impl.tasks.AbstractBundleTask
ATTRIBUTE_BUNDLE_LOCATIONFields inherited from class org.apache.sling.installer.api.tasks.InstallTask
ASYNC_ATTR_NAME -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidThis is the heart of the task - it performs the actual task.Tasks are sorted according to this key.voidsetFinishedState(ResourceState state, String alias, String error) Set the finish state for the active resource and alias (may be null).toString()Methods inherited from class org.apache.sling.installer.core.impl.tasks.AbstractBundleTask
getBundleLocation, getBundleStartLevel, getSortableStartLevel, setBundleLocationMethods inherited from class org.apache.sling.installer.core.impl.AbstractInstallTask
getBundleContext, getBundleRefresher, getLogger, getTaskSupportMethods inherited from class org.apache.sling.installer.api.tasks.InstallTask
compareTo, equals, getResource, getResourceGroup, hashCode, isAsynchronousTask, setFinishedState, setFinishedState
-
Constructor Details
-
BundleStartTask
-
-
Method Details
-
getSortKey
Description copied from class:InstallTaskTasks are sorted according to this key. Therefore this key must uniquely identify this task. A typical sort key contains the entity id of the resource in execution.- Specified by:
getSortKeyin classInstallTask- Returns:
- The sorting key.
-
toString
- Overrides:
toStringin classInstallTask
-
setFinishedState
Description copied from class:InstallTaskSet the finish state for the active resource and alias (may be null). In addition set an error text (may benull).- Overrides:
setFinishedStatein classInstallTask- Parameters:
state- The new state.alias- The new alias (may benull).error- An error text (may benull).- See Also:
-
execute
Description copied from class:InstallTaskThis is the heart of the task - it performs the actual task.- Specified by:
executein classInstallTask- Parameters:
ctx- The installation context.- See Also:
-