|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ow2.jasmine.monitoring.mbeancmd.osgi.internal.ProbeServiceImpl
public class ProbeServiceImpl
This class exposes an OSGi service bundle that implements the JasmineProbeManager interface. It reads its configuration in a probe-config.xml file. Called today by the jasmine-eos module ProbeManager. It replaces the former part embedded in the jasmine eventswitch.
| Constructor Summary | |
|---|---|
ProbeServiceImpl(org.osgi.framework.BundleContext bc)
Inject the BundleContext in the IPojo |
|
| Method Summary | |
|---|---|
void |
addProbeListener(org.ow2.jasmine.probe.api.JasmineProbeListener listener)
Register a ProbeListener in order to be notified by probe state changes. |
void |
changeOutput(org.ow2.jasmine.probe.api.JasmineOutput newoutput)
|
void |
changeProbe(org.ow2.jasmine.probe.api.JasmineProbe newprobe)
|
void |
changeTarget(org.ow2.jasmine.probe.api.JasmineTarget newtarget)
|
void |
createOutput(org.ow2.jasmine.probe.api.JasmineOutput newoutput)
Create a new Output |
int |
createProbe(org.ow2.jasmine.probe.api.JasmineProbe probe)
Create a Probe defined by a JasmineProbe object value |
void |
createTarget(org.ow2.jasmine.probe.api.JasmineTarget newtarget)
Create a new Target |
java.util.Collection<java.lang.String> |
execCommand(org.ow2.jasmine.probe.api.JasmineCommand command)
Execute a command. |
java.util.Collection<java.lang.String> |
execMbeanCommand(org.ow2.jasmine.probe.api.JasmineMbeanCommand command)
Execute a JasmineMbeanCommand |
org.ow2.jasmine.probe.api.JasmineOutput |
findOutput(java.lang.String name)
Get an OutputProbe by its Id |
org.ow2.jasmine.probe.api.JasmineTarget |
findTarget(java.lang.String targetId)
Get a TargetProbe by its Id |
java.util.Collection<org.ow2.jasmine.probe.api.JasmineOutput> |
getOutputs()
|
java.util.Collection<org.ow2.jasmine.probe.api.JasmineProbe> |
getProbes()
|
java.util.Collection<org.ow2.jasmine.probe.api.JasmineTarget> |
getTargets()
|
void |
loadConfig(java.lang.String path)
Load configuration from the specified file |
void |
publishChange(org.ow2.jasmine.probe.api.JasmineProbe probe)
|
void |
removeAllProbes()
Remove all probes |
void |
removeOutput(java.lang.String name)
remove an output |
void |
removeProbe(int probeId)
|
void |
removeTarget(java.lang.String name)
remove an target |
void |
saveConfig(java.lang.String path)
Save back configuration in probe-config.xml |
void |
start()
Read the configuration when module is set. |
void |
startAllProbes()
Start all the probes Continues starting probe even if one is in error (maybe already started) |
void |
startProbe(int probeId)
|
void |
stop()
module is invalidated. |
void |
stopAllProbes()
Stop all the probes Continues stopping probe even if one is in error |
void |
stopProbe(int probeId)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ProbeServiceImpl(org.osgi.framework.BundleContext bc)
bc - | Method Detail |
|---|
public void start()
public void stop()
public void createOutput(org.ow2.jasmine.probe.api.JasmineOutput newoutput)
throws org.ow2.jasmine.probe.api.JasmineProbeException
createOutput in interface org.ow2.jasmine.probe.api.JasmineProbeManagernewoutput - output description
org.ow2.jasmine.probe.api.JasmineProbeException
public void changeOutput(org.ow2.jasmine.probe.api.JasmineOutput newoutput)
throws org.ow2.jasmine.probe.api.JasmineProbeException
changeOutput in interface org.ow2.jasmine.probe.api.JasmineProbeManagerorg.ow2.jasmine.probe.api.JasmineProbeException
public void removeOutput(java.lang.String name)
throws org.ow2.jasmine.probe.api.JasmineProbeException
removeOutput in interface org.ow2.jasmine.probe.api.JasmineProbeManagername - ident of the output to remove
org.ow2.jasmine.probe.api.JasmineProbeExceptionpublic org.ow2.jasmine.probe.api.JasmineOutput findOutput(java.lang.String name)
findOutput in interface org.ow2.jasmine.probe.api.JasmineProbeManagername - ident of the output
public java.util.Collection<org.ow2.jasmine.probe.api.JasmineOutput> getOutputs()
throws org.ow2.jasmine.probe.api.JasmineProbeException
getOutputs in interface org.ow2.jasmine.probe.api.JasmineProbeManagerorg.ow2.jasmine.probe.api.JasmineProbeException
public void createTarget(org.ow2.jasmine.probe.api.JasmineTarget newtarget)
throws org.ow2.jasmine.probe.api.JasmineProbeException
createTarget in interface org.ow2.jasmine.probe.api.JasmineProbeManagernewtarget - target description
org.ow2.jasmine.probe.api.JasmineProbeException
public void changeTarget(org.ow2.jasmine.probe.api.JasmineTarget newtarget)
throws org.ow2.jasmine.probe.api.JasmineProbeException
changeTarget in interface org.ow2.jasmine.probe.api.JasmineProbeManagerorg.ow2.jasmine.probe.api.JasmineProbeException
public void removeTarget(java.lang.String name)
throws org.ow2.jasmine.probe.api.JasmineProbeException
removeTarget in interface org.ow2.jasmine.probe.api.JasmineProbeManagername - ident of the target to remove
org.ow2.jasmine.probe.api.JasmineProbeExceptionpublic org.ow2.jasmine.probe.api.JasmineTarget findTarget(java.lang.String targetId)
findTarget in interface org.ow2.jasmine.probe.api.JasmineProbeManagertargetId - ident of the targetpublic java.util.Collection<org.ow2.jasmine.probe.api.JasmineTarget> getTargets()
getTargets in interface org.ow2.jasmine.probe.api.JasmineProbeManager
public int createProbe(org.ow2.jasmine.probe.api.JasmineProbe probe)
throws org.ow2.jasmine.probe.api.JasmineProbeException
createProbe in interface org.ow2.jasmine.probe.api.JasmineProbeManagerprobe - the object value
org.ow2.jasmine.probe.api.JasmineProbeException
public void changeProbe(org.ow2.jasmine.probe.api.JasmineProbe newprobe)
throws org.ow2.jasmine.probe.api.JasmineProbeException
changeProbe in interface org.ow2.jasmine.probe.api.JasmineProbeManagerorg.ow2.jasmine.probe.api.JasmineProbeException
public void removeProbe(int probeId)
throws org.ow2.jasmine.probe.api.JasmineProbeException
removeProbe in interface org.ow2.jasmine.probe.api.JasmineProbeManagerorg.ow2.jasmine.probe.api.JasmineProbeException
public void removeAllProbes()
throws org.ow2.jasmine.probe.api.JasmineProbeException
removeAllProbes in interface org.ow2.jasmine.probe.api.JasmineProbeManagerorg.ow2.jasmine.probe.api.JasmineProbeException
public void startProbe(int probeId)
throws org.ow2.jasmine.probe.api.JasmineProbeException
startProbe in interface org.ow2.jasmine.probe.api.JasmineProbeManagerorg.ow2.jasmine.probe.api.JasmineProbeException
public void stopProbe(int probeId)
throws org.ow2.jasmine.probe.api.JasmineProbeException
stopProbe in interface org.ow2.jasmine.probe.api.JasmineProbeManagerorg.ow2.jasmine.probe.api.JasmineProbeException
public void stopAllProbes()
throws org.ow2.jasmine.probe.api.JasmineProbeException
stopAllProbes in interface org.ow2.jasmine.probe.api.JasmineProbeManagerorg.ow2.jasmine.probe.api.JasmineProbeException
public void startAllProbes()
throws org.ow2.jasmine.probe.api.JasmineProbeException
startAllProbes in interface org.ow2.jasmine.probe.api.JasmineProbeManagerorg.ow2.jasmine.probe.api.JasmineProbeExceptionpublic java.util.Collection<org.ow2.jasmine.probe.api.JasmineProbe> getProbes()
getProbes in interface org.ow2.jasmine.probe.api.JasmineProbeManager
public void saveConfig(java.lang.String path)
throws org.ow2.jasmine.probe.api.JasmineProbeException
saveConfig in interface org.ow2.jasmine.probe.api.JasmineProbeManagerpath - LATER: path where configuration will be saved.
org.ow2.jasmine.probe.api.JasmineProbeException
public void loadConfig(java.lang.String path)
throws org.ow2.jasmine.probe.api.JasmineProbeException
loadConfig in interface org.ow2.jasmine.probe.api.JasmineProbeManagerpath - File where config will be loaded
org.ow2.jasmine.probe.api.JasmineProbeException
public java.util.Collection<java.lang.String> execCommand(org.ow2.jasmine.probe.api.JasmineCommand command)
throws org.ow2.jasmine.probe.api.JasmineProbeException
execCommand in interface org.ow2.jasmine.probe.api.JasmineProbeManagercommand - command definition containing the command's arguments
org.ow2.jasmine.probe.api.JasmineProbeException - ..public void addProbeListener(org.ow2.jasmine.probe.api.JasmineProbeListener listener)
addProbeListener in interface org.ow2.jasmine.probe.api.JasmineProbeManagerlistener - object that treats the probe state changepublic void publishChange(org.ow2.jasmine.probe.api.JasmineProbe probe)
public java.util.Collection<java.lang.String> execMbeanCommand(org.ow2.jasmine.probe.api.JasmineMbeanCommand command)
throws org.ow2.jasmine.probe.api.JasmineProbeException
command - command definition containing the command's arguments
org.ow2.jasmine.probe.api.JasmineProbeException - ..
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||