Forum Discussion
Sunit_Tailor_11
Nimbostratus
Aug 03, 2006What tofind other way to reduce execution time for enabling and disabling pool members
Hi,
I have Java application which takes "Pool Member"(A) and "desire Session Status"(B) as arguments.
The Primary functionality of this program is to set desired session status for given p...
Aug 04, 2006
Both methods will return the full array list for each of the members in the requested pools. Here's some code that will enumerate the response from get_session_enabled_state()
public void getPoolMembers(String pool_name) throws Exception
{
String [] pool_list = new String[1];
pool_list[0] = pool_name;
System.out.println("Querying pool " + m_pool);
iControl.LocalLBPoolMemberMemberSessionState [][] stateAofA =
m_poolMember.get_session_enabled_state(pool_list);
Loop over first dimension (pools)
for(int i=0; i {
iControl.LocalLBPoolMemberMemberSessionState [] state_list = stateAofA[ i ];
Next, loop over the pool members for pool i
for(int j=0; j {
iControl.CommonIPPortDefinition member = state_list[j].getMember();
iControl.CommonEnabledState session_state = state_list[j].getSession_state();
System.out.println("[" + i + "][" + j + "] - " +
member.getAddress() + ":" + member.getPort() +
" => " + session_state );
}
}
}
Let me know if this doesn't output all the members in the specified pool. If not, then it's likely a problem with the server code (but as far as I know this code always worked).
-Joe
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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
