Beispiel #1
0
    def __init__(self, api_server_ip, api_server_port, conf_sections, sandesh,
                 **kwargs):
        self._logger = sandesh.logger()
        self.api_server_obj = kwargs.get('api_server_obj')
        self._npi = npi.NeutronPluginInterface(
            api_server_ip,
            api_server_port,
            conf_sections,
            sandesh,
            api_server_obj=self.api_server_obj)

        # Bottle callbacks for network operations
        self.route('/neutron/network', 'POST',
                   self._npi.plugin_http_post_network)

        # Bottle callbacks for subnet operations
        self.route('/neutron/subnet', 'POST',
                   self._npi.plugin_http_post_subnet)

        # Bottle callbacks for port operations
        self.route('/neutron/port', 'POST', self._npi.plugin_http_post_port)

        # Bottle callbacks for floating IP operations
        self.route('/neutron/floatingip', 'POST',
                   self._npi.plugin_http_post_floatingip)

        # Bottle callbacks for security group operations
        self.route('/neutron/security_group', 'POST',
                   self._npi.plugin_http_post_securitygroup)

        # Bottle callbacks for security group rule operations
        self.route('/neutron/security_group_rule', 'POST',
                   self._npi.plugin_http_post_securitygrouprule)

        # Bottle callbacks for router operations
        self.route('/neutron/router', 'POST',
                   self._npi.plugin_http_post_router)

        # Bottle callbacks for ipam operations
        self.route('/neutron/ipam', 'POST', self._npi.plugin_http_post_ipam)

        # Bottle callbacks for Policy operations
        self.route('/neutron/policy', 'POST',
                   self._npi.plugin_http_post_policy)

        # Bottle callbacks for route-table operations
        self.route('/neutron/route_table', 'POST',
                   self._npi.plugin_http_post_route_table)

        # Bottle callbacks for svc-instance operations
        self.route('/neutron/nat_instance', 'POST',
                   self._npi.plugin_http_post_svc_instance)

        # Bottle callbacks for virtual-router operations
        self.route('/neutron/virtual_router', 'POST',
                   self._npi.plugin_http_post_virtual_router)
Beispiel #2
0
    def __init__(self, api_server_ip, api_server_port, conf_sections, sandesh):
        self._npi = npi.NeutronPluginInterface(api_server_ip, api_server_port,
                                               conf_sections, sandesh)

        # Bottle callbacks for network operations
        bottle.route('/neutron/network',
                     'POST', self._npi.plugin_http_post_network)

        # Bottle callbacks for subnet operations
        bottle.route('/neutron/subnet',
                     'POST', self._npi.plugin_http_post_subnet)

        # Bottle callbacks for port operations
        bottle.route('/neutron/port',
                     'POST', self._npi.plugin_http_post_port)

        # Bottle callbacks for floating IP operations
        bottle.route('/neutron/floatingip',
                     'POST', self._npi.plugin_http_post_floatingip)

        # Bottle callbacks for security group operations
        bottle.route('/neutron/security_group',
                     'POST', self._npi.plugin_http_post_securitygroup)

        # Bottle callbacks for security group rule operations
        bottle.route('/neutron/security_group_rule',
                     'POST', self._npi.plugin_http_post_securitygrouprule)

        # Bottle callbacks for router operations
        bottle.route('/neutron/router',
                     'POST', self._npi.plugin_http_post_router)

        # Bottle callbacks for ipam operations
        bottle.route('/neutron/ipam',
                     'POST', self._npi.plugin_http_post_ipam)

        # Bottle callbacks for Policy operations
        bottle.route('/neutron/policy',
                     'POST', self._npi.plugin_http_post_policy)

        # Bottle callbacks for route-table operations
        bottle.route('/neutron/route_table',
                     'POST', self._npi.plugin_http_post_route_table)

        # Bottle callbacks for svc-instance operations
        bottle.route('/neutron/nat_instance',
                     'POST', self._npi.plugin_http_post_svc_instance)