blob: 9e64b15c82f483956ead51808345adcc1aedf940 [file] [log] [blame]
Kiall Mac Innes25fb29e2016-04-07 08:07:04 +01001# Copyright 2016 Hewlett Packard Enterprise Development Company, L.P.
2#
3# Licensed under the Apache License, Version 2.0 (the "License"); you may
4# not use this file except in compliance with the License. You may obtain
5# a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12# License for the specific language governing permissions and limitations
13# under the License.
14from tempest import clients
15from tempest import config
16
17from designate_tempest_plugin.services.dns.v2.json.zones_client import \
18 ZonesClient
sonu.kumaraec952a2016-04-20 10:08:46 +090019from designate_tempest_plugin.services.dns.v2.json.zone_imports_client import \
20 ZoneImportsClient
Paul Glass8abae332016-04-21 15:34:09 +000021from designate_tempest_plugin.services.dns.v2.json.blacklists_client import \
22 BlacklistsClient
Paul Glass89edc112016-04-21 17:06:33 +000023from designate_tempest_plugin.services.dns.admin.json.quotas_client import \
24 QuotasClient
sonu.kumarc8f7a702016-04-29 21:07:16 +090025from designate_tempest_plugin.services.dns.v2.json.zone_exports_client import \
26 ZoneExportsClient
sonu.kumarde24d962016-05-05 00:28:00 +090027from designate_tempest_plugin.services.dns.v2.json.recordset_client import \
28 RecordsetClient
sonu.kumar4beb93c2016-05-05 01:12:43 +090029from designate_tempest_plugin.services.dns.v2.json.pool_client import \
30 PoolClient
sonu.kumar2de01be2016-05-05 10:07:28 +090031from designate_tempest_plugin.services.dns.v2.json.tld_client import \
32 TldClient
Kiall Mac Innes25fb29e2016-04-07 08:07:04 +010033
34CONF = config.CONF
35
36
37class Manager(clients.Manager):
38 def __init__(self, credentials=None, service=None):
39 super(Manager, self).__init__(credentials, service)
40
41 params = {
42 'service': CONF.dns.catalog_type,
43 'region': CONF.identity.region,
44 'endpoint_type': CONF.dns.endpoint_type,
45 'build_interval': CONF.dns.build_interval,
46 'build_timeout': CONF.dns.build_timeout
47 }
48 params.update(self.default_params)
49
50 self.zones_client = ZonesClient(self.auth_provider, **params)
sonu.kumaraec952a2016-04-20 10:08:46 +090051 self.zone_imports_client = ZoneImportsClient(self.auth_provider,
52 **params)
Paul Glass8abae332016-04-21 15:34:09 +000053 self.blacklists_client = BlacklistsClient(self.auth_provider, **params)
Paul Glass89edc112016-04-21 17:06:33 +000054 self.quotas_client = QuotasClient(self.auth_provider, **params)
sonu.kumarc8f7a702016-04-29 21:07:16 +090055 self.zone_exports_client = ZoneExportsClient(self.auth_provider,
56 **params)
sonu.kumarde24d962016-05-05 00:28:00 +090057 self.recordset_client = RecordsetClient(self.auth_provider,
58 **params)
sonu.kumar4beb93c2016-05-05 01:12:43 +090059 self.pool_client = PoolClient(self.auth_provider,
60 **params)
sonu.kumar2de01be2016-05-05 10:07:28 +090061 self.tld_client = TldClient(self.auth_provider,
62 **params)