Class ProbeController

java.lang.Object
kieker.monitoring.core.controller.AbstractController
kieker.monitoring.core.controller.ProbeController
All Implemented Interfaces:
IProbeController

public class ProbeController extends AbstractController implements IProbeController
Since:
1.6
Author:
Jan Waller, Bjoern Weissenfels, Nils Christian Ehmke
  • Constructor Details

    • ProbeController

      protected ProbeController(Configuration configuration)
      Creates a new instance of this class using the given configuration to initialize the class.
      Parameters:
      configuration - The configuration used to initialize this controller.
  • Method Details

    • init

      protected void init()
      Description copied from class: AbstractController
      This method should to the initialization work.
      Specified by:
      init in class AbstractController
    • cleanup

      protected void cleanup()
      Description copied from class: AbstractController
      This method should clean up.
      Specified by:
      cleanup in class AbstractController
    • toString

      public String toString()
      Specified by:
      toString in class AbstractController
    • activateProbe

      public boolean activateProbe(String pattern)
      Activates a probe.
      Specified by:
      activateProbe in interface IProbeController
      Parameters:
      pattern - pattern for the probe
      Returns:
      true on success
    • deactivateProbe

      public boolean deactivateProbe(String pattern)
      Deactivates a probe.
      Specified by:
      deactivateProbe in interface IProbeController
      Parameters:
      pattern - pattern for the probe
      Returns:
      true on success
    • isProbeActivated

      public boolean isProbeActivated(String signature)
      Tests if a probe is active. This test is ignorant of the fact whether monitoring itself is enabled/disabled/terminated.
      Specified by:
      isProbeActivated in interface IProbeController
      Parameters:
      signature - signature of the probe
      Returns:
      true if the probe with this signature is active
    • setProbePatternList

      protected void setProbePatternList(List<String> strPatternList, boolean updateConfig)
      Sets the list of probe patterns.
      Parameters:
      strPatternList - The new list with pattern strings.
      updateConfig - Whether the pattern file should be updated or not.
    • setProbePatternList

      public void setProbePatternList(List<String> strPatternList)
      Overwrites the current list of patterns with a new pattern list.
      Specified by:
      setProbePatternList in interface IProbeController
      Parameters:
      strPatternList - list of strings with patterns where each string starts either with a + or -. The list can be empty (in which case the internal pattern list and the internal cache are cleared) - but not null.
    • getProbePatternList

      public List<String> getProbePatternList()
      Returns the current list of patterns with a prefix indicating whether the pattern is active or not.
      Specified by:
      getProbePatternList in interface IProbeController
      Returns:
      list of strings with patterns where each string starts either with a + or -
    • getAllPatternParameters

      public Map<String,List<String>> getAllPatternParameters(String pattern)
      Looks up the parameters for a probe /the pattern of the probe and returns them, may be null.
      Specified by:
      getAllPatternParameters in interface IProbeController
      Parameters:
      pattern - The pattern of the probe.
      Returns:
      The parameters of the probe, may be null.
    • deletePatternParameter

      public void deletePatternParameter(String pattern, String name)
      Deletes a parameter from the given pattern.
      Specified by:
      deletePatternParameter in interface IProbeController
      Parameters:
      pattern - The parameters to be deleted.
      name - The name of the parameter.
    • clearPatternParameters

      public void clearPatternParameters(String pattern)
      Deletes all parameters from the given pattern.
      Specified by:
      clearPatternParameters in interface IProbeController
      Parameters:
      pattern - The parameters to be deleted.
    • addPatternParameter

      public void addPatternParameter(String pattern, String name, List<String> values)
      Adds or updates a parameter for the given pattern.
      Specified by:
      addPatternParameter in interface IProbeController
      Parameters:
      pattern - The pattern of the probe.
      name - The name of the parameter.
      values - a List of entries for this parameter.
    • addPatternParameterValue

      public void addPatternParameterValue(String pattern, String name, String value)
      Description copied from interface: IProbeController
      Add one value to a list of parameter values for a pattern.
      Specified by:
      addPatternParameterValue in interface IProbeController
      Parameters:
      pattern - identifying the pattern for the parameter
      name - name of the parameter
      value - value to be added to the list of parameter values.
    • removePatternParameterValue

      public void removePatternParameterValue(String pattern, String name, String value)
      Description copied from interface: IProbeController
      Remove one value to a list of parameter values for a pattern.
      Specified by:
      removePatternParameterValue in interface IProbeController
      Parameters:
      pattern - identifying the pattern for the parameter
      name - name of the parameter
      value - value to be removed from the list of parameter values.