Module ImportFrom alias ImportFrom alias identifier ImportFrom alias ImportFrom alias identifier ImportFrom alias identifier ImportFrom alias identifier Import alias identifier ImportFrom alias ImportFrom alias ImportFrom alias alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias identifier ImportFrom alias ImportFrom alias Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore ListLoad Call AttributeLoad NameLoad attr Str keyword Str keyword Call NameLoad Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad ClassDef bases AttributeLoad NameLoad attr body Expr Str Assign NameStore Str Assign NameStore Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Num keyword NameLoad keyword NameLoad Assign NameStore Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Num keyword NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults kwarg body Assign NameStore SubscriptLoad NameLoad Index Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr If ListComp NameLoad comprehension NameStore Call AttributeLoad NameLoad attr NameLoad keyword Dict Str ListLoad NameLoad CompareNotEq SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str body Return TryExcept body With Call AttributeLoad AttributeLoad NameLoad attr attr keyword NameLoad body Assign NameStore Call AttributeLoad Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad attr CompareEq AttributeLoad NameLoad attr NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Return Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad decorator_list ClassDef bases AttributeLoad NameLoad attr body Expr Str FunctionDef arguments args NameParam defaults vararg kwarg body Expr Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr Return Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body TryExcept body If CompareIsNot AttributeLoad NameLoad attr NameLoad body Return AttributeLoad NameLoad attr handlers ExceptHandler type NameLoad body Pass Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Return AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam NameParam NameParam defaults body TryExcept body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr CompareEq AttributeLoad NameLoad attr NameLoad attr handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr keyword NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr For NameStore Call NameLoad Call NameLoad NameLoad body TryExcept body With Call AttributeLoad AttributeLoad NameLoad attr attr keyword NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call NameLoad keyword NameLoad keyword NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr Str Dict Str Str NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Return Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Str Dict Str Str NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Call NameLoad Str NameLoad Raise Call AttributeLoad NameLoad attr keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body With Call AttributeLoad AttributeLoad NameLoad attr attr keyword NameLoad body Return Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str If UnaryOpNot NameLoad body Return TryExcept body Return Call AttributeLoad NameLoad attr NameLoad NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Return Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Return Dict Str Str SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Expr Str Assign NameStore Dict Str AttributeLoad NameLoad attr Dict Str ListLoad NameLoad ListLoad NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad keyword NameLoad Assign NameStore Call NameLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore ListComp Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad keyword NameLoad comprehension NameStore Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Str Dict Str Str Str NameLoad NameLoad NameLoad Return NameLoad decorator_list AttributeLoad NameLoad attr FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad body If NameLoad body Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Num Index Str orelse Assign NameStore NameLoad TryExcept body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Return Dict orelse If NameLoad body Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Num Index Str orelse Assign NameStore SubscriptLoad NameLoad Index Str Assign NameStore Dict Str Dict Str Str ListLoad NameLoad ListLoad NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad keyword NameLoad If UnaryOpNot NameLoad body Expr Call AttributeLoad NameLoad attr Call NameLoad Str NameLoad Return Dict Assign NameStore SubscriptLoad NameLoad Index Num Assign SubscriptStore NameLoad Index Str SubscriptLoad NameLoad Index Str Return NameLoad decorator_list AttributeLoad NameLoad attr decorator_list
N/A neutron_lib constants neutron_lib exceptions n_exc oslo_config cfg oslo_db exception db_exc oslo_log helpers log_helpers oslo_log log logging N/A sqlalchemy sa sqlalchemy or_ sqlalchemy.orm exc neutron._i18n _ _LE neutron.callbacks events neutron.callbacks registry neutron.callbacks resources neutron.common utils neutron.db model_base neutron.db models_v2 neutron.extensions dvr ext_dvr neutron.extensions portbindings neutron manager N/A LOG N/A N/A logging getLogger __name__ N/A dvr_mac_address_opts N/A N/A N/A cfg StrOpt dvr_base_mac default fa:16:3f:00:00:00 help N/A _ The base mac address used for unique DVR instances by Neutron. The first 3 octets will remain unchanged. If the 4th octet is not 00, it will also be used. The others will be randomly generated. The 'dvr_base_mac' *must* be different from 'base_mac' to avoid mixing them up with MAC's allocated for tenant ports. A 4 octet example would be dvr_base_mac = fa:16:3f:4f:00:00. The default is 3 octet N/A N/A N/A N/A cfg CONF register_opts dvr_mac_address_opts DistributedVirtualRouterMacAddress N/A N/A model_base BASEV2 N/A N/A Represents a v2 neutron distributed virtual router mac address. N/A __tablename__ dvr_host_macs N/A host N/A N/A sa Column N/A N/A sa String 255 primary_key True nullable False N/A mac_address N/A N/A sa Column N/A N/A sa String 32 nullable False unique True N/A _delete_mac_associated_with_agent N/A N/A resource event trigger context agent N/A kwargs N/A N/A host N/A agent N/A host N/A plugin N/A N/A N/A manager NeutronManager get_plugin N/A N/A a N/A a N/A N/A plugin get_agents context filters N/A host N/A host N/A N/A a N/A id N/A agent N/A id N/A N/A N/A N/A N/A N/A N/A N/A context session begin subtransactions True N/A N/A entry N/A N/A N/A N/A N/A N/A N/A context session query DistributedVirtualRouterMacAddress filter N/A N/A DistributedVirtualRouterMacAddress host host one N/A N/A N/A N/A context session delete entry N/A N/A N/A N/A exc NoResultFound N/A N/A N/A dvr_macs N/A N/A plugin get_dvr_mac_address_list context N/A N/A N/A N/A plugin notifier dvr_mac_address_update context dvr_macs N/A DVRDbMixin N/A N/A ext_dvr DVRMacAddressPluginBase N/A N/A Mixin class to add dvr mac address to db_plugin_base_v2. __new__ N/A N/A cls N/A args kwargs N/A N/A N/A N/A registry subscribe _delete_mac_associated_with_agent N/A resources AGENT N/A events BEFORE_DELETE N/A N/A N/A N/A super DVRDbMixin cls __new__ cls N/A plugin N/A N/A self N/A N/A N/A N/A N/A N/A N/A self _plugin None N/A N/A N/A self _plugin N/A N/A N/A AttributeError N/A N/A N/A N/A self _plugin N/A N/A N/A manager NeutronManager get_plugin N/A N/A self _plugin N/A property _get_dvr_mac_address_by_host N/A N/A self context host N/A N/A N/A N/A N/A query N/A N/A N/A context session query DistributedVirtualRouterMacAddress N/A dvrma N/A N/A N/A N/A query filter N/A N/A DistributedVirtualRouterMacAddress host host one N/A N/A N/A N/A exc NoResultFound N/A N/A N/A N/A ext_dvr DVRMacAddressNotFound host host N/A dvrma N/A _create_dvr_mac_address N/A N/A self context host N/A N/A N/A Create DVR mac address for a given host. N/A base_mac N/A N/A N/A N/A cfg CONF dvr_base_mac split : N/A max_retries N/A N/A cfg CONF mac_generation_retries N/A attempt N/A reversed N/A range max_retries N/A N/A N/A N/A N/A N/A N/A context session begin subtransactions True N/A N/A mac_address N/A N/A utils get_random_mac base_mac N/A dvr_mac_binding N/A DistributedVirtualRouterMacAddress host host mac_address mac_address N/A N/A N/A N/A context session add dvr_mac_binding N/A N/A N/A LOG debug Generated DVR mac for host %(host)s is %(mac_address)s N/A host mac_address host mac_address N/A dvr_macs N/A N/A self get_dvr_mac_address_list context N/A N/A N/A N/A self notifier dvr_mac_address_update context dvr_macs N/A N/A N/A self _make_dvr_mac_address_dict dvr_mac_binding N/A N/A N/A N/A db_exc DBDuplicateEntry N/A N/A N/A N/A LOG debug Generated DVR mac %(mac)s exists. Remaining attempts %(attempts_left)s. N/A mac attempts_left mac_address attempt N/A N/A N/A LOG error N/A _LE MAC generation error after %s attempts max_retries N/A N/A N/A ext_dvr MacAddressGenerationFailure host host N/A get_dvr_mac_address_list N/A N/A self context N/A N/A N/A N/A N/A N/A context session begin subtransactions True N/A N/A N/A N/A N/A N/A N/A context session query DistributedVirtualRouterMacAddress all N/A get_dvr_mac_address_by_host N/A N/A self context host N/A N/A N/A Determine the MAC for the DVR port associated to host. N/A N/A host N/A N/A N/A N/A N/A N/A N/A self _get_dvr_mac_address_by_host context host N/A N/A N/A N/A ext_dvr DVRMacAddressNotFound N/A N/A N/A N/A self _create_dvr_mac_address context host N/A _make_dvr_mac_address_dict N/A N/A self dvr_mac_entry fields N/A None N/A N/A N/A host mac_address N/A dvr_mac_entry N/A host N/A dvr_mac_entry N/A mac_address N/A get_ports_on_host_by_subnet N/A N/A self context host subnet N/A N/A N/A Returns DVR serviced ports on a given subnet in the input host

        This method returns ports that need to be serviced by DVR.
        :param context: rpc request context
        :param host: host id to match and extract ports of interest
        :param subnet: subnet id to match and extract ports of interest
        :returns list -- Ports on the given subnet in the input host
         N/A filters N/A fixed_ips N/A portbindings HOST_ID N/A subnet_id N/A subnet N/A host N/A ports_query N/A N/A N/A self plugin _get_ports_query context filters filters N/A owner_filter N/A or_ N/A N/A N/A N/A models_v2 Port device_owner startswith N/A constants DEVICE_OWNER_COMPUTE_PREFIX N/A N/A N/A N/A models_v2 Port device_owner in_ N/A N/A utils get_other_dvr_serviced_device_owners N/A ports_query N/A N/A ports_query filter owner_filter N/A ports N/A N/A N/A N/A self plugin _make_port_dict port process_extensions False N/A port N/A N/A ports_query all N/A N/A N/A LOG debug Returning list of dvr serviced ports on host %(host)s for subnet %(subnet)s ports %(ports)s N/A host subnet ports host subnet ports N/A ports N/A N/A log_helpers log_method_call get_subnet_for_dvr N/A N/A self context subnet fixed_ips N/A None N/A N/A fixed_ips N/A N/A subnet_data N/A N/A fixed_ips N/A 0 N/A subnet_id N/A N/A subnet_data subnet N/A N/A N/A subnet_info N/A N/A N/A self plugin get_subnet context subnet_data N/A N/A N/A N/A n_exc SubnetNotFound N/A N/A N/A N/A N/A fixed_ips N/A N/A ip_address N/A N/A fixed_ips N/A 0 N/A ip_address N/A N/A ip_address N/A subnet_info N/A gateway_ip N/A filter N/A fixed_ips N/A subnet_id ip_address N/A subnet N/A ip_address N/A internal_gateway_ports N/A N/A N/A self plugin get_ports context filters filter N/A N/A internal_gateway_ports N/A N/A N/A N/A LOG error N/A _LE Could not retrieve gateway port for subnet %s subnet_info N/A N/A N/A internal_port N/A internal_gateway_ports N/A 0 N/A N/A subnet_info N/A gateway_mac N/A internal_port N/A mac_address N/A subnet_info N/A N/A log_helpers log_method_call N/A