3-part Dyn TD labels are no more

This commit is contained in:
Ross McFarland
2019-01-09 10:54:21 -08:00
parent 862ed60276
commit da9e268659
2 changed files with 4 additions and 8 deletions
+3 -7
View File
@@ -399,14 +399,10 @@ class DynProvider(BaseProvider):
tds = defaultdict(dict)
for td in get_all_dsf_services():
try:
_, fqdn, _type = td.label.split(':', 2)
fqdn, _type = td.label.split(':', 1)
except ValueError:
try:
fqdn, _type = td.label.split(':', 1)
except ValueError:
self.log.warn("Unsupported TrafficDirector '%s'",
td.label)
continue
self.log.warn("Unsupported TrafficDirector '%s'", td.label)
continue
tds[fqdn][_type] = td
self._traffic_directors = dict(tds)
+1 -1
View File
@@ -1626,7 +1626,7 @@ class DummyRuleset(object):
class DummyTrafficDirector(object):
def __init__(self, rulesets=[], response_pools=[], ttl=42):
self.label = 'dynamic:dummy'
self.label = 'dummy:abcdef1234567890'
self.rulesets = rulesets
self.all_response_pools = response_pools
self.ttl = ttl