Infoblox::DTC::Monitor::ICMP - A DTC ICMP Health Monitor object.
A DTC ICMP Health Monitor object.
my $icmp_monitor = Infoblox::DTC::Monitor::ICMP->new( name => $string, #Required comment => $string, #Optional / Default is undefined interval => $uint, #Optional / Default is undefined retry_down => $uint, #Optional / Default is undefined retry_up => $uint, #Optional / Default is undefined timeout => $uint, #Optional / Default is undefined extattrs => { $string => $extattr, ... }, #Optional / Default is undefined extensible_attributes => { $string => $string | $num, $string => [ $string | $num, ... ], ... } #Optional / Default is undefined );
You cannot set both extattrs and extensible_attributes attributes at the same time.
This section describes all the methods in a Session module that you can apply to a DTC ICMP Monitor object
Use this method to add an object to the Infoblox appliance. See Infoblox::Session->add() for parameters and return values.
#construct an object my $icmp_monitor = Infoblox::DTC::Monitor::ICMP->new( name => 'icmp_monitor1', );
#submit for addition my $response = $session->add($icmp_monitor);
Use this method to retrieve all the matching objects from the Infoblox appliance. See Infoblox::Session->get() for parameters and return values.
Apply the following attribute to get a specific object:
name - Optional. A DTC ICMP Monitor name in a string format. comment - Optional. A DTC ICMP Monitor comment. extattrs - Optional. A hash reference containing extensible attributes. extensible_attributes - Optional. A hash reference that contains extensible attributes.
my @retrieved_objs = $session->get( object => 'Infoblox::DTC::Monitor::ICMP', name => 'icmp_monitor1', );
my @retrieved_objs = $session->get( object => 'Infoblox::DTC::Monitor::ICMP', extensible_attributes => { 'Site' => 'Santa Clara' } );
Use this method to modify an object in the Infoblox appliance. See Infoblox::Session->modify() for parameters and return values.
#Use method to modify the comment. $icmp_monitor->comment('this is a modified comment'); #Submit modification my $response = $session->modify($icmp_monitor);
Use this method to remove an object from the Infoblox appliance. See Infoblox::Session->remove() for parameters and return values.
To remove a specific object, first use get()
or search()
to retrieve the specific object, and then submit this object for removal.
#Get the objects with the same name my @retrieved_objs = $session->get( object => 'Infoblox::DTC::Monitor::ICMP', name => 'icmp_monitor1', ); #Find the desired object from the retrieved list. my $desired_icmp_monitor = $retrieved_objs[0]; #Submit for removal my $response = $session->remove($desired_icmp_monitor);
Use this method to search for objects in the Infoblox appliance. See Infoblox::Session->search() for parameters and return values.
Apply the following attribute to get a specific object:
name - Optional. A DTC ICMP Monitor name in a string format. comment - Optional. A DTC ICMP Monitor comment. extattrs - Optional. A hash reference containing extensible attributes. extensible_attributes - Optional. A hash reference that contains extensible attributes.
my @retrieved_objs = $session->search( object => 'Infoblox::DTC::Monitor::ICMP', name => 'icmp_monitor1', );
my @retrieved_objs = $session->search( object => 'Infoblox::DTC::Monitor::ICMP', extensible_attributes => { 'Site' => 'Santa Clara' } );
This section describes all the methods that you can use to set or retrieve the attribute values of the object.
Use this method to set or retrieve a DTC ICMP Health Monitor object comment.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid value is a comment in string format (UTF-8) with a maximum of 256 bytes.
If you specified a parameter, the method returns 'true' when the modification succeeds, and returns 'false' when the operation fails.
If you did not specify a parameter, the method returns the attribute value.
#get comment value my $comment = $icmp_monitor->comment();
#modify comment value $icmp_monitor->comment('desired comment');
Use this method to set or retrieve the extensible attributes associated with a DTC ICMP Health Monitor object.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
Valid value is a hash reference containing the names of extensible attributes and their associated values (Infoblox::Grid::Extattr objects).
If you specified a parameter, the method returns 'true' when the modification succeeds, and returns 'false' when the operation fails.
If you did not specify a parameter, the method returns the attribute value.
#get extattrs value my $ref_extattrs = $icmp_monitor->extattrs();
#Modify extattrs $icmp_monitor->extattrs({ 'Site' => $extattr1, 'Administrator' => $extattr2 });
Use this method to set or retrieve the extensible attributes associated with a DTC ICMP Health Monitor object.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
For valid values for extensible attributes, see Infoblox::Grid::ExtensibleAttributeDef/Extensible Attribute Values.
If you specified a parameter, the method returns 'true' when the modification succeeds, and returns 'false' when the operation fails.
If you did not specify a parameter, the method returns the attribute value.
#Get extensible attributes my $ref_extensible_attributes = $icmp_monitor->extensible_attributes();
#Modify extensible attributes $icmp_monitor->extensible_attributes({'Site' => 'Santa Clara', 'Administrator' => ['Peter', 'Tom']});
Use this method to set or retrieve the time interval for the ICMP health check.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid value is an unsigned integer.
If you specified a parameter, the method returns 'true' when the modification succeeds, and returns 'false' when the operation fails.
If you did not specify a parameter, the method returns the attribute value.
#get interval value my $interval = $icmp_monitor->interval();
#modify interval value $icmp_monitor->interval(10);
Use this method to set or retrieve a DTC ICMP Health Monitor name.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid value is a desired name in a string format.
If you specified a parameter, the method returns 'true' when the modification succeeds, and returns 'false' when the operation fails.
If you did not specify a parameter, the method returns the attribute value.
#get name value my $name = $icmp_monitor->name();
#modify name value $icmp_monitor->name('icmp_monitor1');
Use this method to set or retrieve the number of times the server appears offline after it was online so it is treated as dead.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid value is an unsigned integer between 1 and 10.
If you specified a parameter, the method returns 'true' when the modification succeeds, and returns 'false' when the operation fails.
If you did not specify a parameter, the method returns the attribute value.
#get retry_down value my $retry_down = $icmp_monitor->retry_down();
#modify retry_down value $icmp_monitor->retry_down(3);
Use this method to set or retrieve the number of times the server appears online after it was offline so it is treated as alive.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid value is an unsigned integer between 1 and 10.
If you specified a parameter, the method returns 'true' when the modification succeeds, and returns 'false' when the operation fails.
If you did not specify a parameter, the method returns the attribute value.
#get retry_up value my $retry_up = $icmp_monitor->retry_up();
#modify retry_up value $icmp_monitor->retry_up(3);
Use this method to set or retrieve the value of a timeout for ICMP health check.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid value is an unsigned integer between 1 and 15.
If you specified a parameter, the method returns 'true' when the modification succeeds, and returns 'false' when the operation fails.
If you did not specify a parameter, the method returns the attribute value.
#get timeout value my $timeout = $icmp_monitor->timeout();
#modify timeout value $icmp_monitor->timeout(7);
Infoblox Inc. http://www.infoblox.com/
Infoblox::Session, Infoblox::Session->add(), Infoblox::Session->get(), Infoblox::Session->modify(), Infoblox::Session->remove(), Infoblox::Session->search(), Infoblox::Grid::Extattr, Infoblox::Grid::ExtensibleAttributeDef/Extensible Attribute Values.
Copyright (c) 2017 Infoblox Inc.