Infoblox::DTC::Topology::Rule - A DTC Topology Rule object.


NAME

Infoblox::DTC::Topology::Rule - A DTC Topology Rule object.


DESCRIPTION

Topology Rule describes the behavior of a load balancer used for a matching condition contained in the rules for a 'TOPOLOGY' load balancing method.


CONSTRUCTOR

 my $rule = Infoblox::DTC::Topology::Rule->new(
    sources          => [$source1, $source2, ...], #Optional / default is undefined
    destination_type => 'POOL' | 'SERVER',         #Optional / default is undefined
    destination_link => $link_object               #Optional / default is undefined
 );


SESSION METHODS

This section describes all the methods in a Session module that you can apply to a Topology Rule object. Note that to add a rule to the Infoblox appliance, you must add it to the existing Topology object. To remove a rule from the Infoblox appliance, you must remove it from the existing Topology.

Infoblox::Session->get( )

Use this method to retrieve all the matching objects from the Infoblox appliance. See Infoblox::Session->get() for parameters and return values.

Key Reference
 Apply the following attribute to get a specific object:
  topology         - Optional. A DTC Topology the rule belongs to.
  destination_type - Optional. The type of the destination link.
  destination_link - Optional. The destination link value.
  valid            - Optional. The flag that indicates whether a rule is valid or not.
Example
 my @retrieved_objs = $session->get(
     object => 'Infoblox::DTC::Topology::Rule',
     destination_type => 'POOL',
 );

Infoblox::Session->modify( )

Use this method to modify an object in the Infoblox appliance. See Infoblox::Session->modify() for parameters and return values.

Example
 #Use method to modify the comment
 $rule->comment('modified_rule1');
 #Submit modification
 my $response = $session->modify($rule);

Infoblox::Session->search( )

Use this method to search for objects in the Infoblox appliance. See Infoblox::Session->search() for parameters and return values.

Key Reference
 Apply the following attribute to get a specific object:
  topology         - Optional. A DTC Topology the rule belongs to.
  destination_type - Optional. The type of the destination link.
  destination_link - Optional. The destination link value.
  valid            - Optional. The flag that indicates whether a rule is valid or not.
Example
 my @retrieved_objs = $session->search(
     object => 'Infoblox::DTC::Topology::Rule',
     valid  => 'true',
 );


METHODS

This section describes all the methods that you can use to set or retrieve the attribute values of the object.

destination_link( )

Use this method to set or retrieve a DTC Topology Rule destination link.

Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.

Parameter

The valid value is an Infoblox::DTC::Pool or Infoblox::DTC::Server object.

Returns

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.

Example
 #get destination_link value
 my $destination_link = $rule->destination_link();
 #modify destination_link value
 $rule->destination_link($pool_link);

destination_type( )

Use this method to set or retrieve the destination type for a DTC Topology rule.

Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.

Parameter

The valid values are 'POOL' and 'SERVER'.

Returns

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.

Example
 #get destination_type value
 my $destination_type = $rule->destination_type();
 #modify destination_type value
 $rule->destination_type('SERVER');

sources( )

Use this method to set or retrieve conditions for matching sources.

Include the specified parameter to set the attribute value. Omit the parameter to retrieve the attribute value.

Parameter

The valid value is an array of Infoblox::DTC::Topology::Rule::Source objects.

Returns

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.

Example
 #get sources value
 my @sources = $rule->sources();
 #modify sources value
 $rule->sources([$source1, $source2]);

topology( )

Use this method to retrieve the DTC Topoloyg to which a rule belongs. This is a read-only attribute.

Parameter

None

Returns

The valid return value is an partial Infoblox::DTC::Topology object.

Example
 #get sources value
 my $topology = $rule->topology();

valid( )

Use this method to retrieve the status of GeoIP labels. This is a read-only attribute.

Parameter

None

Returns

The method returns 'true' if GeoIP labels exist or 'false' if they do not.

Example
 #get sources value
 my $valid = $rule->valid();


AUTHOR

Infoblox Inc. http://www.infoblox.com/


SEE ALSO

Infoblox::Session, Infoblox::Session->get(), Infoblox::Session->modify(), Infoblox::Session->search(), Infoblox::DTC::Pool, Infoblox::DTC::Server, Infoblox::DTC::Topology::Rule::Source, Infoblox::DTC::Topology.


COPYRIGHT

Copyright (c) 2017 Infoblox Inc.