Jump to: navigation, search

Difference between revisions of "Provider-network-partial-specs"

m (Examples)
Line 9: Line 9:
 
* creating networks for bare metal instances: neutron admin creates provider-networks with provider:network_type=vlan and delegates to neutron-server the choice of provider:physical_network and provider:segmentation_id  using tenant-network pools,
 
* creating networks for bare metal instances: neutron admin creates provider-networks with provider:network_type=vlan and delegates to neutron-server the choice of provider:physical_network and provider:segmentation_id  using tenant-network pools,
 
* creating service oriented networks which imposes some provider attributes: neutron creates provider-networks with previous attributes and delegates to neutron-server the choice of remaining provider attributes using tenant-network pools.
 
* creating service oriented networks which imposes some provider attributes: neutron creates provider-networks with previous attributes and delegates to neutron-server the choice of remaining provider attributes using tenant-network pools.
 +
 +
= API impacts =
 +
This functionality will change provider attributes constraints on provider network create:
 +
* provider:network_type is required,
 +
* when provider:network_type=vlan, provider:physical_network and provider:segmentation_id become optional, provider:segmentation_id can be provided only if provider:physical_network is provided (otherwise raise a http bad request),
 +
* when provider:network_type=gre or vxlan, provider:segmentation_id becomes optional,
 +
* when provider:network_type=flat, provider:physical_network becomes optional (not sure for the moment),
 +
* when provider:network_type=local, no impact.
 +
 +
If some provider attributes are not provided, neutron will try to find in tenant network pools a network respecting provided provider attributes, if not network is found a http bad request (http code to discuss) is returned.
  
 
= Examples =
 
= Examples =
Line 45: Line 55:
 
  # create a flat provider network (chosen in physnet1, physnet2)
 
  # create a flat provider network (chosen in physnet1, physnet2)
  
= API impacts =
+
= Implementation =
This functionality will change provider attributes constraints on provider network create:
+
TO DISCUSS
* provider:network_type is required,
+
* which network types will support partial provider network specs ?
* when provider:network_type=vlan, provider::physical_network and provider:segmentation_id become optional, provider:segmentation_id can be provided only if provider::physical_network is provided (otherwise raise a http bad request),
+
** vlan, gre, vxlan and flat
* when provider:network_type=gre or vxlan, provider:segmentation_id becomes optional,
+
** only vlan and flat because i currently don't see operational usecases for gre/vxlan
* when provider:network_type=flat, provider::physical_network becomes optional (not sure for the moment),
 
* when provider:network_type=local, no impact.
 
  
If some provider attributes are not provided, neutron will try to find in tenant network pools a network respecting provided provider attributes, if not network is found a http bad request (http code to discuss) is returned.
+
* how ?
 +
** Define alternative TypeDriver implementations for network_types supporting partial provider network specs.
 +
More flexible, allow to enable partial provider network specs on some network types.
 +
Administrators choose which implementation they want to use using stevedore
 +
Or a stevedore key is associated to each implementation and administrators choose which they enable through type_drivers option.
  
= Implementation =
+
** Update current TypeDriver implementations  to support partial provider network specs.
Options (to discuss):
+
Easier to implement, but do not allow to disable this functionality.
* Define alternative TypeDriver implementations for vlan/gre/vxlan/flat supporting to provide partial provider network specs.
 
* Update current TypeDriver implementations  supporting to provide partial provider network specs.
 

Revision as of 22:20, 21 January 2014

Overview

Currently, all provider attributes for networks are chosen by:

  • neutron-server for tenant networks,
  • neutron admin for provider networks.

The aim of this functionality is to allow to the neutron admin to provide some provider network attributes and delegate when possible the choice of remaining provider attributes to neutron.

Use Cases

This functionality could be used when :

  • creating networks for bare metal instances: neutron admin creates provider-networks with provider:network_type=vlan and delegates to neutron-server the choice of provider:physical_network and provider:segmentation_id using tenant-network pools,
  • creating service oriented networks which imposes some provider attributes: neutron creates provider-networks with previous attributes and delegates to neutron-server the choice of remaining provider attributes using tenant-network pools.

API impacts

This functionality will change provider attributes constraints on provider network create:

  • provider:network_type is required,
  • when provider:network_type=vlan, provider:physical_network and provider:segmentation_id become optional, provider:segmentation_id can be provided only if provider:physical_network is provided (otherwise raise a http bad request),
  • when provider:network_type=gre or vxlan, provider:segmentation_id becomes optional,
  • when provider:network_type=flat, provider:physical_network becomes optional (not sure for the moment),
  • when provider:network_type=local, no impact.

If some provider attributes are not provided, neutron will try to find in tenant network pools a network respecting provided provider attributes, if not network is found a http bad request (http code to discuss) is returned.

Examples

ML2 config context:

[ml2]
tenant_network_types = gre
type_drivers = vlan,gre,flat
 
[ml2_type_flat]
flat_networks = physnet1,physnet2
 
[ml2_type_vlan]
network_vlan_ranges = physnet3:300:319,physnet4:400:419,physnet5
 
[ml2_type_gre]
tunnel_id_ranges =1000:1999

Current features

neutron net-create tenant-net 
# create a tenant network

neutron net-create --provider:network_type=vlan --provider:physical_network=physnet4 --provider:segmentation_id=123 provider-net
# create a vlan provider network on physnet physnet5 for vlan 123

New features

neutron net-create --provider:network_type=vlan vlan-net
# create a vlan provider network (chosen in physnet3:300:319,physnet4:400:419)
 
neutron net-create --provider:network_type=vlan --provider:physical_network=physnet3 physnet-vlan-net
# create a vlan provider network on physnet physnet3 (segmentation_id chosen in 300:319)

neutron net-create --provider:network_type=vlan --provider:physical_network=physnet5 no-net
# raise an error because no network matchs requirements 
 
neutron net-create --provider:network_type=flat flat-net
# create a flat provider network (chosen in physnet1, physnet2)

Implementation

TO DISCUSS

  • which network types will support partial provider network specs ?
    • vlan, gre, vxlan and flat
    • only vlan and flat because i currently don't see operational usecases for gre/vxlan
  • how ?
    • Define alternative TypeDriver implementations for network_types supporting partial provider network specs.

More flexible, allow to enable partial provider network specs on some network types. Administrators choose which implementation they want to use using stevedore Or a stevedore key is associated to each implementation and administrators choose which they enable through type_drivers option.

    • Update current TypeDriver implementations to support partial provider network specs.

Easier to implement, but do not allow to disable this functionality.