Infoblox::DTC::Monitor::SIP - A DTC SIP Health Monitor object.
The DTC SIP Health Monitor determines the health of a SIP servers such as SIP Proxies and Session Border Controllers, and SIP gateways by issuing SIP options to a server and examining the response provided by the server. The service is considered available if the received response matches the expected response.
my $sip_monitor = Infoblox::DTC::Monitor::SIP->new( name => $string, #Required ciphers => [$cipher1, $cipher2, ...], #Optional / Default is undefined client_cert => $certificate #Optional / Default is undefined comment => $string, #Optional / Default is undefined interval => $uint, #Optional / Default is undefined port => $uint, #Optional / Default is undefined request => $string, #Optional / Default is undefined result => 'ANY' | 'CODE_IS' | 'CODE_IS_NOT', #Optional / Default is undefined result_code => $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 transport => 'TCP' | 'UDP' | 'TLS' | 'SIPS', #Optional / Default is undefined validate_cert => 'true' | 'false', #Optional / Default is 'false' 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 SIP 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 $sip_monitor = Infoblox::DTC::Monitor::SIP->new( name => 'sip_monitor1', );
#submit for addition my $response = $session->add($sip_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 SIP Monitor name in a string format. comment - Optional. A DTC SIP 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::SIP', name => 'sip_monitor1', );
my @retrieved_objs = $session->get( object => 'Infoblox::DTC::Monitor::SIP', 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. $sip_monitor->comment('this is a modified comment'); #Submit modification my $response = $session->modify($sip_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::SIP', name => 'sip_monitor1', ); #Find the desired object from the retrieved list. my $desired_sip_monitor = $retrieved_objs[0]; #Submit for removal my $response = $session->remove($desired_sip_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 SIP Monitor name in a string format. comment - Optional. A DTC SIP Monitor Descriptive 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::SIP', name => 'sip_monitor1', );
my @retrieved_objs = $session->search( object => 'Infoblox::DTC::Monitor::SIP', 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 list of ciphers for a secure TLS or SIPS connection.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid value is an array of ciphers in a string format. Ciphers use an OpenSSL syntax. Empty array is equivalent to 'ALL' in an OpenSSL notation.
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 ciphers value my @ciphers = $sip_monitor->ciphers();
#modify ciphers value $sip_monitor->ciphers(['RC4-MD5', 'KRB5-RC4-MD5']);
Use this method to set or retrieve a client certificate, supplied in a secure TLS or SIPS mode if present.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid value is an Infoblox::DTC::Certificate object.
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 client_cert value my $cert = $sip_monitor->client_cert();
#modify client_cert value $sip_monitor->client_cert($cert);
Use this method to set or retrieve the comment for a DTC SIP Health Monitor object.
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 = $sip_monitor->comment();
#modify comment value $sip_monitor->comment('desired comment');
Use this method to set or retrieve the extensible attributes associated with a DTC SIP 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 = $sip_monitor->extattrs();
#Modify extattrs $sip_monitor->extattrs({ 'Site' => $extattr1, 'Administrator' => $extattr2 });
Use this method to set or retrieve the extensible attributes associated with a DTC SIP 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 = $sip_monitor->extensible_attributes();
#Modify extensible attributes $sip_monitor->extensible_attributes({'Site' => 'Santa Clara', 'Administrator' => ['Peter', 'Tom']});
Use this method to set or retrieve the time interval for the SIP 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 = $sip_monitor->interval();
#modify interval value $sip_monitor->interval(10);
Use this method to set or retrieve a DTC SIP 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 = $sip_monitor->name();
#modify name value $sip_monitor->name('sip_monitor1');
Use this method to set or retrieve the port value for SIP or SIPS requests.
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 65535.
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 port value my $port = $sip_monitor->port();
#modify port value $sip_monitor->port(8080);
Use this method to set or retrieve an SIP request to send.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid value is a string of 1024 characters maximum.
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 request value my $request = $sip_monitor->request();
#modify request value $sip_monitor->request('GET /');
Use this method to set or retrieve the type of expected result.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid values are 'ANY', 'CODE_IS' and 'CODE_IS_NOT'.
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 result value my $result = $sip_monitor->result();
#modify result value $sip_monitor->result('CODE_IS');
Use this method to set or retrieve the expected return code.
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 0 and 999.
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 result_code value my $result_code = $sip_monitor->result_code();
#modify result_code value $sip_monitor->result_code(300);
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 = $sip_monitor->retry_down();
#modify retry_down value $sip_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 = $sip_monitor->retry_up();
#modify retry_up value $sip_monitor->retry_up(3);
Use this method to set or retrieve the value of a timeout for SIP 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 = $sip_monitor->timeout();
#modify timeout value $sip_monitor->timeout(7);
Use this method of set or retrieve the type of transport layer protocol being used for SIP health check.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
The valid values are 'TCP', 'UDP', 'SIPS' and 'TLS'.
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 transport value my $transport = $sip_monitor->transport();
#modify transport value $sip_monitor->transport('UDP');
Use this method to set or retrieve the flag that indicates whether the validation of the remote server's certificate is enabled.
Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.
Specify 'true' to enable remote server's certificate validation and 'false' to disable it. The default is 'true'.
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 validate_cert value my $validate_cert = $http_monitor->validate_cert();
#modify validate_cert value $http_monitor->validate_cert('false');
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, Infoblox::DTC::Certificate.
Copyright (c) 2017 Infoblox Inc.