MonALISA Grid Monitoring
Menu mode: dynamic | fixed
  HOME       CLIENTS       REPOSITORIES       DOWNLOADS       LOOKING GLASS       FAST DATA TRANSFER  
Last update on:
Dec 03, 2015

Uptime: 323 days, 15h, 21m
Number of requests: 4864852
since 28 October 2005
MonALISA Extensions Guide

MonALISA Extensions Guide


Chapter 1. Data Structures

1. Monitoring Data Envolopes (Results)

The data flux between MonALISA Service and clients is encapsulated (more or less) in the following objects:

1.1.  lia.Monitor.monitor.Result

This is the base class for numeric monitoring values. For generic monitoring values Section 1.2, “ lia.Monitor.monitor.eResult class should be used. Inside MonALISA framework all the monitoring values are identified by the tupple (FarmName, ClusterName, NodeName, ParamName) and the time The relationship between FarmName and ClusterName is "1-to-many", as it is for the relation between ClusterName and NodeName This will map any Result to the following structure
        
        FarmName|
                |--ClusterName_1
                |     |
                |     |---NodeName_1 <-->| param_name[1..n]
                |     |                 | param[1..n]
                |     |
                |     |---NodeName_i
                |
                |--ClusterName_n
                |     |
                |     |---NodeName_k
                |                                                       
                               
Every NodeName can have one or more parameters. The array param_name[] stores the parameter names which should be mapped 1-to-1 to param[] values. The Result data object structure is:
        public String NodeName;
        public String ClusterName;
        public String FarmName;
        public String[]  param_name;
        public long   time;
        public double[] param;
                       
The array param_name has the same length as param; the first one contains the name of params for which values are in param[]. The mapping is one to one.

1.2.  lia.Monitor.monitor.eResult

This is the base class for generic monitoring values. For numeric monitoring values Section 1.1, “ lia.Monitor.monitor.Result class should be used. The structure is the same as it is in Section 1.1, “ lia.Monitor.monitor.Result The only difference is that the param can hold any type of data(e.g String), not just double values.

Warning

The values stored in param MUST implement java.io.Serializable

This class is also used to dynamically remove Clusters, Nodes and Parameters from internal configuration using the following algorithm:

        if (NodeName == null) then
                remove ClusterName;
        else if (param == null || this.param_name == null)
                remove NodeName;
        else
                for index in [0 ... param_name.length-1]
                        if ( param[i] == null )
                                remove param_name[i];
                                       

This can be used by the monitoring modules to notify the data collector that the configuration exported by the module has been changed.

1.3.  lia.Monitor.monitor.Gresult

This class is used to aggregate some online informations on Cluster basis. To have a general overview over a Cluster (e.g. Load5) ypu can divide Nodes (number of active nodes) in nbin interval (e.g nbin=5 for nodes between 0-0.25, 0.25-0.5, 0.5-0.75, 0.75-1.0, and over 1.0) and use hist[] to express how many of nodes belong to each interval. TotalNodes can express Nodes + Dead Nodes. Module should store the name of the param for which this Gresult was calculated. The Gresult data object struncture is:
        public long   time;
        public String ClusterName;
        public String FarmName;
        public String Module;
        
        public int TotalNodes ;
        public int Nodes ;
        public double mean;
        public double max ;
        public double min;
        public double sum ;
        public int nbin ;
        public int[]  hist ;
                               

2. Data Query/Filtering

2.1. lia.Monitor.monitor.monPredicate

Defines a Predicate to select data from the input stream and from the DB. The monPredicate class provides basic filtering functionality for data.

An object of this type implements java.io.Serializable because it is send using RMI or another protocol (i.e. WSDL) to a lia.Monitor.monitor.DataStore.

2.1.1. Synopsis

 public class monPredicateimplements Serializable {
// Public Fields  public String Cluster ;
  public String Farm ;
  public String Node ;
  public boolean bLastVals ;
  public String[] constraints ;
  public int id ;
  public String[] parameters ;
  public long tmax ;
  public long tmin ;
// Public Constructors  public monPredicate();
  public monPredicate(java.lang.String farm,
                      java.lang.String cluster,
                      java.lang.String node,
                      long tmin,
                      long tmax,
                      java.lang.String[] parameters,
                      java.lang.String[] constraints);

// Public Methods  public String toString();
}

Methods inherited from java.lang.Object: equals, getClass, hashCode, notify, notifyAll, toString, wait

See Also
lia.Monitor.monitor.DataStore#Register

Inheritance Path. java.lang.Object-> Section 2, “Data Query/Filtering”

2.1.2. monPredicate()

public monPredicate();

It initializes an empty monPredicate.

2.1.3. monPredicate(String, String, String, long, long, String[], String[])

public monPredicate(java.lang.String farm,
                    java.lang.String cluster,
                    java.lang.String node,
                    long tmin,
                    long tmax,
                    java.lang.String[] parameters,
                    java.lang.String[] constraints);

Parameters

farm

The name of the farm.

cluster

The name of the cluster.

node

The name of the node.

tmin

Starting time (in milliseconds). It can be positive or negative.

tmax

Ending time (in milliseconds). It can be positive or negative.

parameters

Names of the functions(module parameters) that are filtered. Same names as from lia.Monitor.monitor.ModuleInfo.ResTypes .

constrains

constrains that this monPredicate provides.

It initializes a monPredicate. The parameters are used for filtering the data.

2.1.4. bLastVals

public boolean bLastVals ;
Since

ML 1.5.0

Should be a RT predicate ... will try to get ONLY the lastValue from Cache

2.1.5. Cluster

public String Cluster ;

It should be the name of the Cluster. It can be an regular expression.

2.1.6. constraints

public String[] constraints ;
See Also
parameters

Provides basic constraints for functions passed in parameters. It can be null.

If parameters is null it is ignored.

Basic logical operations like AND, OR are supported for the Filtering constraints.

constraints can be basically of two types:

  • Filtering constraints

    Logical constraints for the corresponding column in parameters

  • Grouping Functions

    AVG , MIN and MAX are supported until now. It can be only one function.

There can be either a Grouping Function either a Filtering Constraint.If an element in theconstraints starts with a:

  • Grouping Function like AVG, MIN, MAX this must be the only function (you cannot have another Grouping Function or Filtering Constraint applied to the corresponding parameter)

  • Filtering Constraint (&gt,&lt,=) than you can specify either float values, either Grouping Function for the right operand. Only the right operand can be specified! The left is assumed to be the corresponding function in parameters. There can be more than one Filtering constrains separated by logical operators like AND or OR(and and or will also work). A recursive "definition" for Filtering Constraint will be:

    Filtering Constraint := ((Filtering Constraint)(AND|OR)?)+

Examples:

  • Filtering constraints

    &gt 2.3 AND &lt 2.5 AND &lt AVG

    Filters values greater than 2.3 and less than 2.5 and greater than average(Grouping FunctionAVG is used) value for the corresponding function in parameters

  • Grouping Functions

    AVG - calculates the average value for the corresponding function in parameters

    MIN - calculates the minimum for the corresponding function in parameters

    MAX - calculates the maximum for the corresponding function in parameters

The Grouping Function are calculated between tmin and tmax

2.1.7. Farm

public String Farm ;

It should be the name of the Farm. It can be an regular expression.

2.1.8. id

public int id ;

The id for this monPredicate. It should be unique for a couple (Client, monPredicate). It is assigned by the Client.

2.1.9. Node

public String Node ;

It should be the name of the Node. It can be an regular expression.

2.1.10. parameters

public String[] parameters ;
See Also
lia.Monitor.monitor.MonModuleInfo#ResTypes, constraints

This vector stores names of the functions for basic filtering. If this parameter is null it is ignored and also constraints parameter from monPredicate.

The names must be the same as the ones found in lia.Monitor.monitor.MonModuleInfo.ResTypes

2.1.11. tmax

public long tmax ;
See Also
constraints

It can be positive, negative, or zero. See tmin

2.1.12. tmin

public long tmin ;
See Also
constraints

It can be positive, negative, or zero.

  • tmin > 0 is used to express an absolute time in milliseconds since January 1, 1970, 00:00:00 GMT. Possible values for tmax are:

    • If tmax > 0 then it means that this monPredicate is used to filter some stored values between two given absolute times [tmin, tmax]. The values are considered to be DataStore times. The Result is sent to the Client only once.

    • If tmax = 0 then it means that this monPredicate is used to filter some stored values between tmin and the local time on DataStore(present time). The Result is sent to the Client only once.

    • If tmax < 0 then it means that this monPredicate is used to filter some stored values between tmin and the local time on DataStore. The difference between this case and the previous one is that the DataStore must provide filtered data based on this monPredicate to the Clientperiodically.

  • tmin < 0 represents an relative time to the local time on the DataStore where this monPredicate is used to filter data. Possible values for tmax are:

    • If tmax = 0 then it means that this monPredicate is used to filter some stored values between local time - tmin and the local time([-tmin, 0]) on DataStore (0 is the present time on DataStore). The Result is sent to the Client only once.

    • If tmax &lt 0 is the same case as previous. The difference between this case and the previous one is that the DataStore must provide filtered data based on this monPredicate to the Clientperiodically.

  • tmin = 0. monPredicate does no time filtering on DataStore. In this case the Filtering constraints from constraints are applied only on received data, but the Grouping Functions applies to the entire set of data.

    • If tmax = 0 the Result is sent to the Client only once.

    • If tmax < 0 the Result is sent to the Clientperiodically.

The Grouping Functions applies to entire set of data on DataStore only when tmin = 0 and tmax = 0, in all other cases are applied on the specified time interval.

2.1.13. toString()

public String toString();
Since

ML 1.2.54

3. Remote Logging

3.1. lia.util.logging.MLLogEvent

(javadoc)