f5-appsvcs-extension
f5-appsvcs-extension copied to clipboard
GSLB WideIP - "poolsCname" object is not allowed along with "pools"
Environment
- Application Services Version: 3.53
- BIG-IP Version: 16.1.3.3
Summary
Trying to create a Wide-IP with two pools, A and CNAME. Schema does not allowed to do it in this way:
"pools": [
{
"use": "a_pool"
}
],
"poolsCname": [
{
"use": "cname_pool"
}
],
or adding both pools to list pools - generating error - for referencing to non existing object, as cname_pool is not A pool.
"pools": [
{
"use": "a_pool"
}.
{
"use": "cname_pool"
}
],
Steps To Reproduce
Steps to reproduce the behavior:
- Submit the following declaration:
{
"$schema": "https://raw.githubusercontent.com/F5Networks/f5-appsvcs-extension/master/schema/latest/as3-schema.json",
"class": "AS3",
"action": "deploy",
"declaration": {
"class": "ADC",
"schemaVersion": "3.45.0",
"controls": {
"class": "Controls",
"trace": true,
"logLevel": "debug",
"traceResponse": true
},
"cname_and_a_pools_tenant": {
"class": "Tenant",
"cname_and_a_pools_app": {
"class": "Application",
"a_wip.local_domain": {
"class": "GSLB_Domain",
"domainName": "a_wip.local",
"aliases": [],
"resourceRecordType": "A",
"poolLbMode": "global-availability",
"pools": [
{
"use": "a_pool"
}
],
"poolsCname": [
{
"use": "cname_pool"
}
],
"iRules": [],
"persistCidrIpv4": 24,
"persistenceEnabled": false,
"clientSubnetPreferred": true,
"ttlPersistence": 3600
},
"a_pool": {
"class": "GSLB_Pool",
"members": [
{
"ratio": 10,
"server": {
"bigip": "/Common/dc1-ltm0102-cluster"
},
"virtualServer": "/Common/aaaa",
"enabled": true,
"dependsOn": "none"
}
],
"resourceRecordType": "A",
"enabled": true,
"lbModePreferred": "round-robin",
"lbModeAlternate": "round-robin",
"lbModeFallback": "return-to-dns",
"ttl": 5,
"verifyMemberEnabled": true,
"maxAnswersReturned": 1
},
"cname_pool": {
"class": "GSLB_Pool",
"resourceRecordType": "CNAME",
"enabled": true,
"members": [
{
"domainName": "google.com",
"isDomainNameStatic": true,
"enabled": true
}
]
}
}
}
}
}
- Observe the following error response:
{
"id": "489bd188-b09c-4022-abca-a1e3e7ef93de",
"results": [
{
"code": 422,
"errors": [
"/cname_and_a_pools_tenant/cname_and_a_pools_app/a_wip.local_domain: then is NOT valid"
],
"message": "declaration is invalid",
"host": "localhost",
"tenant": [
"cname_and_a_pools_tenant"
],
"declarationId": "autogen_48f90180-490e-46ed-8781-3922db62ccd9"
}
],
"declaration": {},
"selfLink": "https://localhost/mgmt/shared/appsvcs/task/489bd188-b09c-4022-abca-a1e3e7ef93de"
}
Adding both pools in to pools list:
"results": [
{
"code": 422,
"message": "declaration failed",
"response": "01070233:3: Wideip Pool refers to nonexistent Pool /cname_and_a_pools_tenant/cname_and_a_pools_app/cname_pool",
"host": "localhost",
"tenant": "cname_and_a_pools_tenant",
"runTime": 2862,
"declarationId": "autogen_60e2755d-99ec-4b47-b4d6-6d5bf5381417"
}
],
Expected Behavior
Both pools added to WIP, this works via GUI or TMSH:
root@(dc1-gtm02)(cfg-sync In Sync)(Standby)(/Common)(tmos)# create gtm wideip a a1_wip.local pools-cname add { cname_pool { order 1 } } pools add { a_pool { order 0 } }
root@(dc1-gtm02)(cfg-sync In Sync)(Standby)(/Common)(tmos)# list gtm wideip a a1_wip.local
gtm wideip a a1_wip.local {
pools {
a_pool {
order 0
}
}
pools-cname {
cname_pool {
order 1
}
}
}
Actual Behavior
Unable to mix of two types of Pools in one Declaration.