7.9 Using Other Grid Objects

Grid objects can be retrieved using jobs. This is done when facts from other objects are needed for job decision processing, or when joblets are executed on a resource.

The MatrixInfo grid object represents the system and from the MatrixInfo object, you can retrieve other grid objects in the system. For example, to retrieve the resource grid object named webserver and a fact named resource.id from this object, you would enter the following JDL code:

    webserver = getMatrix().getGridObject(TYPE_RESOURCE,"webserver")
    id = webserver.getFact("resource.id")

The MatrixInfo grid object also provides functions for creating other grid objects. For more complete information about these functions, see MatrixInfo.