Removed deprecated methods for AgentSchedulers

Removed methods deprecated by
change I3a32a95489831f0d862930384309eefdc881d8f6

Change-Id: I00c8c323135e3510896a9b66877fe887285d9281
Related-Bug: #1569404
This commit is contained in:
Dariusz Smigiel 2016-09-29 19:22:24 +00:00 committed by Darek Smigiel
parent dc8ad65838
commit 05cd620389
2 changed files with 0 additions and 45 deletions

View File

@ -17,7 +17,6 @@ import datetime
import random
import time
import debtcollector
from neutron_lib import constants
from oslo_config import cfg
from oslo_log import log as logging
@ -155,24 +154,6 @@ class AgentSchedulerDbMixin(agents_db.AgentDbMixin):
self.add_worker(check_worker)
@debtcollector.removals.remove(
message="This will be removed in the O cycle. "
"Please use 'add_agent_status_check_worker' instead."
)
def add_agent_status_check(self, function):
loop = loopingcall.FixedIntervalLoopingCall(function)
# TODO(enikanorov): make interval configurable rather than computed
interval = max(cfg.CONF.agent_down_time // 2, 1)
# add random initial delay to allow agents to check in after the
# neutron server first starts. random to offset multiple servers
initial_delay = random.randint(interval, interval * 2)
loop.start(interval=interval, initial_delay=initial_delay)
if hasattr(self, 'periodic_agent_loops'):
self.periodic_agent_loops.append(loop)
else:
self.periodic_agent_loops = [loop]
def agent_dead_limit_seconds(self):
return cfg.CONF.agent_down_time * 2
@ -262,18 +243,6 @@ class DhcpAgentSchedulerDbMixin(dhcpagentscheduler
network_scheduler = None
@debtcollector.removals.remove(
message="This will be removed in the O cycle. "
"Please use 'add_periodic_dhcp_agent_status_check' instead."
)
def start_periodic_dhcp_agent_status_check(self):
if not cfg.CONF.allow_automatic_dhcp_failover:
LOG.info(_LI("Skipping periodic DHCP agent status check because "
"automatic network rescheduling is disabled."))
return
self.add_agent_status_check(self.remove_networks_from_down_agents)
def add_periodic_dhcp_agent_status_check(self):
if not cfg.CONF.allow_automatic_dhcp_failover:
LOG.info(_LI("Skipping periodic DHCP agent status check because "

View File

@ -13,7 +13,6 @@
# License for the specific language governing permissions and limitations
# under the License.
import debtcollector
from neutron_lib import constants
from oslo_config import cfg
from oslo_db import exception as db_exc
@ -71,19 +70,6 @@ class L3AgentSchedulerDbMixin(l3agentscheduler.L3AgentSchedulerPluginBase,
router_scheduler = None
@debtcollector.removals.remove(
message="This will be removed in the O cycle. "
"Please use 'add_periodic_l3_agent_status_check' instead."
)
def start_periodic_l3_agent_status_check(self):
if not cfg.CONF.allow_automatic_l3agent_failover:
LOG.info(_LI("Skipping period L3 agent status check because "
"automatic router rescheduling is disabled."))
return
self.add_agent_status_check(
self.reschedule_routers_from_down_agents)
def add_periodic_l3_agent_status_check(self):
if not cfg.CONF.allow_automatic_l3agent_failover:
LOG.info(_LI("Skipping period L3 agent status check because "