Class MaintenanceTaskComponent
- java.lang.Object
-
- org.apache.avalon.framework.logger.AbstractLogEnabled
-
- org.ametys.workspaces.repository.maintenance.MaintenanceTaskComponent
-
- All Implemented Interfaces:
Component
,LogEnabled
,Serviceable
public class MaintenanceTaskComponent extends AbstractLogEnabled implements Component, Serviceable
Component to launch and follow the maintenance tasks on the repository
-
-
Constructor Summary
Constructors Constructor Description MaintenanceTaskComponent()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,Object>
getInformation(String taskName)
Get the information of a running taskMap<String,Object>
isRunning(String taskName)
Check if a task is running or notvoid
service(ServiceManager smanager)
Map<String,Object>
startTask(String taskName)
Start a Maintenance Task-
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
-
-
-
Constructor Detail
-
MaintenanceTaskComponent
public MaintenanceTaskComponent()
-
-
Method Detail
-
service
public void service(ServiceManager smanager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
startTask
public Map<String,Object> startTask(String taskName)
Start a Maintenance Task- Parameters:
taskName
- the name of the task- Returns:
- a JSon object
-
isRunning
public Map<String,Object> isRunning(String taskName)
Check if a task is running or not- Parameters:
taskName
- The task name- Returns:
- true if the task is running
-
getInformation
public Map<String,Object> getInformation(String taskName)
Get the information of a running task- Parameters:
taskName
- the task name- Returns:
- the information
-
-