Forum Discussion
Dec 07, 2010
Smart way to convert a PoolMemberDefinitionSequenceSequence to a IPPortDefinitionSequenceSequence
Hi,
I want to dump out (and eventually read in and set) the enabled state of each of my GTM pools pool members. Its easy to get a list of the pools and pool members, but the PoolMember.get_en...
L4L7_53191
Dec 07, 2010Nimbostratus
This is an example of how to do that with a GTM pool member:
enabled_state = pm.typefactory.create('GlobalLB.PoolMember.MemberEnabledState')
enabled_state.member.address = '2.2.2.2'
enabled_state.member.port = 80
enabled_state.state.value = 'STATE_DISABLED'
enabled_state_seq = pm.typefactory.create('GlobalLB.PoolMember.MemberEnabledStateSequence')
enabled_state_seq.items = [enabled_state]
pm.set_enabled_state(pool_names = ['pc_test_pool'],states = [enabled_state_seq])
-Matt
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