Package org.eclipse.steady.java.monitor
Class UploadScheduler
- java.lang.Object
-
- java.util.Observable
-
- org.eclipse.steady.java.monitor.UploadScheduler
-
public class UploadScheduler extends Observable implements Runnable, Observer
Calls a sequence methods of a givenExecutionMonitorin order upload collected information to the Vulas backend. TheUploadSchedulerruns either once or periodically, depending on the way it was constructed.
-
-
Constructor Summary
Constructors Constructor Description UploadScheduler(ExecutionMonitor _monitor)Constructor for UploadScheduler.UploadScheduler(ExecutionMonitor _monitor, long _millis, int _batch_size)Constructor for UploadScheduler.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddisable()disable.voidenabled()enabled.intgetBatchSize()Getter for the fieldbatchSize.longgetInterval()getInterval.booleanisEnabled()isEnabled.voidrun()Calls a sequence of methods of aExecutionMonitor.voidupdate(Observable obj, Object arg)Disables periodic uploads (called by the shutdown uploader).-
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
-
-
-
-
Constructor Detail
-
UploadScheduler
public UploadScheduler(ExecutionMonitor _monitor)
Constructor for UploadScheduler.
- Parameters:
_monitor- aExecutionMonitorobject.
-
UploadScheduler
public UploadScheduler(ExecutionMonitor _monitor, long _millis, int _batch_size)
Constructor for UploadScheduler.
- Parameters:
_monitor- aExecutionMonitorobject._millis- a long._batch_size- a int.
-
-
Method Detail
-
enabled
public void enabled()
enabled.
-
disable
public void disable()
disable.
-
isEnabled
public boolean isEnabled()
isEnabled.
- Returns:
- a boolean.
-
getInterval
public long getInterval()
getInterval.
- Returns:
- a long.
-
getBatchSize
public int getBatchSize()
Getter for the field
batchSize.- Returns:
- a int.
-
run
public void run()
Calls a sequence of methods of aExecutionMonitor.
-
update
public void update(Observable obj, Object arg)
Disables periodic uploads (called by the shutdown uploader).
-
-