Post-pool merge cleanup

(1) Removed references to designate-agent.
(2) Removed mdns references that are no longer needed.
(3) Ensure that create_domain creates soa first.
(4) Removed py26 from the default tox tests

Change-Id: Ic014fecac7f97fa88a45e3ac2a3e2d35299fc966
This commit is contained in:
Vinod Mangalpally 2014-12-16 12:40:28 -06:00
parent 38d0b28d0a
commit 889475db99
10 changed files with 11 additions and 43 deletions

View File

@ -2,7 +2,7 @@
# Install and start **Designate** service # Install and start **Designate** service
# To enable Designate services, add the following to localrc # To enable Designate services, add the following to localrc
# enable_service designate,designate-api,designate-central,designate-mdns,designate-agent,designate-sink,designate-pool-manager # enable_service designate,designate-api,designate-central,designate-mdns,designate-sink,designate-pool-manager
# stack.sh # stack.sh
# --------- # ---------
@ -234,7 +234,6 @@ function start_designate {
fi fi
run_process designate-api "$DESIGNATE_BIN_DIR/designate-api --config-file $DESIGNATE_CONF" run_process designate-api "$DESIGNATE_BIN_DIR/designate-api --config-file $DESIGNATE_CONF"
run_process designate-mdns "$DESIGNATE_BIN_DIR/designate-mdns --config-file $DESIGNATE_CONF" run_process designate-mdns "$DESIGNATE_BIN_DIR/designate-mdns --config-file $DESIGNATE_CONF"
run_process designate-agent "$DESIGNATE_BIN_DIR/designate-agent --config-file $DESIGNATE_CONF"
run_process designate-sink "$DESIGNATE_BIN_DIR/designate-sink --config-file $DESIGNATE_CONF" run_process designate-sink "$DESIGNATE_BIN_DIR/designate-sink --config-file $DESIGNATE_CONF"
run_process designate-pool-manager "$DESIGNATE_BIN_DIR/designate-pool-manager --config-file $DESIGNATE_CONF" run_process designate-pool-manager "$DESIGNATE_BIN_DIR/designate-pool-manager --config-file $DESIGNATE_CONF"
@ -254,7 +253,6 @@ function stop_designate {
stop_process designate-api stop_process designate-api
stop_process designate-central stop_process designate-central
stop_process designate-mdns stop_process designate-mdns
stop_process designate-agent
stop_process designate-sink stop_process designate-sink
stop_process designate-pool-manager stop_process designate-pool-manager

View File

@ -76,7 +76,6 @@ EOF
# configure_designate_backend - make configuration changes, including those to other services # configure_designate_backend - make configuration changes, including those to other services
function configure_designate_backend { function configure_designate_backend {
iniset $DESIGNATE_CONF service:pool_manager backends bind9 iniset $DESIGNATE_CONF service:pool_manager backends bind9
iniset $DESIGNATE_CONF service:mdns slave_nameserver_ips_and_ports "$DESIGNATE_SERVICE_HOST:$DESIGNATE_SERVICE_PORT_DNS"
iniset $DESIGNATE_CONF backend:bind9 masters $DESIGNATE_SERVICE_HOST:$DESIGNATE_SERVICE_PORT_MDNS iniset $DESIGNATE_CONF backend:bind9 masters $DESIGNATE_SERVICE_HOST:$DESIGNATE_SERVICE_PORT_MDNS
iniset $DESIGNATE_CONF backend:bind9 server_ids $DESIGNATE_SERVER_ID iniset $DESIGNATE_CONF backend:bind9 server_ids $DESIGNATE_SERVER_ID

View File

@ -45,9 +45,6 @@ function install_designate_backend {
# configure_designate_backend - make configuration changes, including those to other services # configure_designate_backend - make configuration changes, including those to other services
function configure_designate_backend { function configure_designate_backend {
# mDNS Service Settings
iniset $DESIGNATE_CONF service:mdns slave_nameserver_ips_and_ports "$DESIGNATE_DYNECT_SLAVES"
# DynECT Backend Settings # DynECT Backend Settings
iniset $DESIGNATE_CONF backend:dynect masters "$DESIGNATE_DYNECT_MASTERS" iniset $DESIGNATE_CONF backend:dynect masters "$DESIGNATE_DYNECT_MASTERS"
iniset $DESIGNATE_CONF backend:dynect customer_name "$DESIGNATE_DYNECT_CUSTOMER" iniset $DESIGNATE_CONF backend:dynect customer_name "$DESIGNATE_DYNECT_CUSTOMER"

View File

@ -47,7 +47,6 @@ function install_designate_backend {
# configure_designate_backend - make configuration changes, including those to other services # configure_designate_backend - make configuration changes, including those to other services
function configure_designate_backend { function configure_designate_backend {
iniset $DESIGNATE_CONF service:pool_manager backends powerdns iniset $DESIGNATE_CONF service:pool_manager backends powerdns
iniset $DESIGNATE_CONF service:mdns slave_nameserver_ips_and_ports "$DESIGNATE_SERVICE_HOST:$DESIGNATE_SERVICE_PORT_DNS"
iniset $DESIGNATE_CONF backend:powerdns server_ids $DESIGNATE_SERVER_ID iniset $DESIGNATE_CONF backend:powerdns server_ids $DESIGNATE_SERVER_ID
iniset $DESIGNATE_CONF backend:powerdns connection `database_connection_url designate_pdns` iniset $DESIGNATE_CONF backend:powerdns connection `database_connection_url designate_pdns`

View File

@ -22,7 +22,6 @@ ENABLED_SERVICES+=,designate,designate-api,designate-central,designate-mdns,desi
# Optional Designate services # Optional Designate services
#ENABLED_SERVICES+=,designate-sink #ENABLED_SERVICES+=,designate-sink
#ENABLED_SERVICES+=,designate-agent
# Optional TLS Proxy # Optional TLS Proxy
#ENABLED_SERVICES+=,tls-proxy #ENABLED_SERVICES+=,tls-proxy

View File

@ -888,12 +888,6 @@ class Service(service.RPCService):
domain.serial = utils.increment_serial() domain.serial = utils.increment_serial()
domain = self.storage.create_domain(context, domain) domain = self.storage.create_domain(context, domain)
if domain.obj_attr_is_set('recordsets'):
for rrset in domain.recordsets:
self._create_recordset_in_storage(
context, domain, rrset, increment_serial=False)
servers = self.storage.find_servers(context) servers = self.storage.find_servers(context)
# Create the SOA and NS recordsets for the new domain. The SOA # Create the SOA and NS recordsets for the new domain. The SOA
@ -901,6 +895,11 @@ class Service(service.RPCService):
self._create_soa(context, domain) self._create_soa(context, domain)
self._create_ns(context, domain, servers) self._create_ns(context, domain, servers)
if domain.obj_attr_is_set('recordsets'):
for rrset in domain.recordsets:
self._create_recordset_in_storage(
context, domain, rrset, increment_serial=False)
return domain return domain
def get_domain(self, context, domain_id): def get_domain(self, context, domain_id):

View File

@ -24,21 +24,6 @@ OPTS = [
help='Number of mdns worker processes to spawn'), help='Number of mdns worker processes to spawn'),
cfg.StrOpt('host', default='0.0.0.0', cfg.StrOpt('host', default='0.0.0.0',
help='mDNS Bind Host'), help='mDNS Bind Host'),
cfg.ListOpt('slave-nameserver-ips-and-ports', default=[],
help='Ips and ports of slave nameservers that are notified of '
'zone changes. The format of each item in the list is'
'"ipaddress:port"'),
cfg.IntOpt('notify-timeout', default=60,
help='The number of seconds to wait before the notify query '
'times out.'),
cfg.IntOpt('notify-retry-interval', default=2,
help='The number of seconds to wait before retrying the notify'
'query.'),
cfg.IntOpt('notify-retries', default=1,
help='The number of retries of a notify to a slave '
'nameserver. A notify-retries of 1 implies that on an '
'error after sending a NOTIFY, there would not be any '
'retries. A 0 implies that NOTIFYs are not sent at all'),
cfg.IntOpt('port', default=5354, cfg.IntOpt('port', default=5354,
help='mDNS Port Number'), help='mDNS Port Number'),
cfg.IntOpt('tcp-backlog', default=100, cfg.IntOpt('tcp-backlog', default=100,

View File

@ -61,18 +61,9 @@ class NotifyEndpoint(object):
The return value is just used for testing and not by pool manager. The return value is just used for testing and not by pool manager.
""" """
time.sleep(delay) time.sleep(delay)
# TODO(vinod): Remove the following code for return self._make_and_send_dns_message(
# setting destination from config once pool manager calls mdns domain, destination, timeout, retry_interval, max_retries,
if (destination is None): notify=True)
for slave in CONF['service:mdns'].slave_nameserver_ips_and_ports:
self._make_and_send_dns_message(
domain, slave, CONF['service:mdns'].notify_timeout,
CONF['service:mdns'].notify_retry_interval,
CONF['service:mdns'].notify_retries, notify=True)
else:
return self._make_and_send_dns_message(
domain, destination, timeout, retry_interval, max_retries,
notify=True)
def poll_for_serial_number(self, context, domain, destination, timeout, def poll_for_serial_number(self, context, domain, destination, timeout,
retry_interval, max_retries, delay): retry_interval, max_retries, delay):

View File

@ -179,6 +179,7 @@ class Service(service.RPCService):
for server_backend in self.server_backends: for server_backend in self.server_backends:
server = server_backend['server'] server = server_backend['server']
# PowerDNS needs a notify for the AXFR to happen reliably.
self.mdns_api.notify_zone_changed( self.mdns_api.notify_zone_changed(
context, domain, self._get_destination(server), self.timeout, context, domain, self._get_destination(server), self.timeout,
self.retry_interval, self.max_retries, 0) self.retry_interval, self.max_retries, 0)

View File

@ -1,6 +1,6 @@
[tox] [tox]
minversion = 1.6 minversion = 1.6
envlist = py26,py27,flake8 envlist = py27,flake8
skipsdist = True skipsdist = True
[tox:jenkins] [tox:jenkins]