Forum Discussion
paul_adomeit_70
Nimbostratus
Jan 08, 2007query_pool_associations does not return anything
Here's a sample of the code I'm using. I stripped all the faultcode checking for now.
The credentials, host, port etc are set elsewhere. The soap response returns an empty array. I've tried a f...
paul_adomeit_70
Nimbostratus
Jan 11, 2007We have a winner.
Thanks Joe!
----------------------------------------------------------------------------
Get pools used by rule
----------------------------------------------------------------------------
sub get_pools_used_by_rule
{
Routine makes soap call and iterates over values to extract pool names
$soap1 = SOAP::Lite
-> uri('urn:iControl:ITCMLocalLB/Rule')
-> readable(1)
-> proxy("https://$sHost:$sPort/iControl/iControlPortal.cgi");
$soap1_response = $soap1->query_pool_associations(SOAP::Data->name(rule_names => [$rule]));
if ( $soap1_response->fault )
{
print $soap1_response->faultcode, "(faultstring) ", $soap_response->faultstring, "\n";
print $soap1_response->faultcode, "(faultdetail) ", $soap_response->faultdetail, "\n";
}
else
{
my @poolAofA = @{$soap1_response->result};
for my $i (0..$poolAofA)
{
print "rule $i: \n";
my $pool_list = $poolAofA[$i];
foreach my $pool_name ( @{$pool_list} )
{
print " $pool_name \n";
}
}
}
}
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects
