Kube baymodel create should allow no network_driver specified

Bug #1501077 reported by Dane LeBlanc
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Magnum
Fix Released
Undecided
Daneyon Hansen

Bug Description

When a kubernetes baymodel is created, the current API validation
only allows an explicit setting of "flannel" for the network_driver
attribute. This validation needs to be changed to allow a user to
create a kubernetes baymodel without explicitly specifying a
network_driver. When no network_driver is explicitly selected,
Magnum should choose the default network driver for the selected
COE type, i.e.:
- Kubernetes: default network driver = flannel
- Swarm: default network driver = legacy docker networking (for now,
               may change to flannel or libnetwork in the future)
- Mesos: default network driver = legacy docker networking

A secondary issue is that for creation of swarm and mesos baymodel
types, no API validation is currently being done for network_driver
(e.g. user is allowed to specify "flannel", but this network driver
is not supported yet for swarm and mesos).

Dane LeBlanc (leblancd)
Changed in magnum:
assignee: nobody → Dane LeBlanc (leblancd)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to magnum (master)

Fix proposed to branch: master
Review: https://review.openstack.org/230147

Changed in magnum:
status: New → In Progress
Revision history for this message
Egor Guz (eghobo) wrote : Re: Baymodel create should allow no network_driver specified

@leblancd: I think Tom is already committed the patch

Dane LeBlanc (leblancd)
summary: - Baymodel create should allow no network_driver specified
+ Kube baymodel create should allow no network_driver specified
description: updated
Revision history for this message
Dane LeBlanc (leblancd) wrote :

@Egor: Thanks, I changed the bug title and description to account for
the other commit: https://review.openstack.org/#/c/228838/.
The new bug(s) being described here are:
- For kubernetes baymodel create, user should be able to
  leave out selection of network-driver altogether
  (magnum should in this case default to flannel).
- For swarm and mesos baymodel create, there is
  currently no network-driver validation being performed
  at all (e.g. "flannel" network-driver is allowed, even
  though flannel isn't currently supported for swarm/mesos
  bays).

Changed in magnum:
assignee: Dane LeBlanc (leblancd) → Daneyon Hansen (danehans)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to magnum (master)

Reviewed: https://review.openstack.org/230147
Committed: https://git.openstack.org/cgit/openstack/magnum/commit/?id=fd2e76054153f77f21d987860adc20e4a0944865
Submitter: Jenkins
Branch: master

commit fd2e76054153f77f21d987860adc20e4a0944865
Author: Dane LeBlanc <email address hidden>
Date: Thu Oct 1 16:44:45 2015 -0400

    Baymodel create should allow no network_driver specified

    When a kubernetes baymodel is created, the current API validation
    only allows an explicit setting of "flannel" for the network-driver
    attribute. This validation needs to be changed to allow a user to
    create a kubernetes baymodel without explicitly specifying a
    network driver. (The same goes for docker swarm and mesos baymodels,
    that is, baymodel create should allow the user not to specify
    a network-driver, but this is the current behavior).

    When no network-driver is selected for baymodel create for a
    given COE, Magnum should choose the default network driver for that
    COE. Note that this change set only handles the validation for
    the case where no network-driver is selected; mapping this to
    the COE-dependent default network driver will be done in other
    commits (e.g. https://review.openstack.org/#/c/224367/ for swarm).

    Note that no new unit test cases were added for this patch since
    test_create_baymodel_with_network_driver and
    test_create_baymodel_with_no_network_driver test cases in
    test_baymodel.py should cover this change.

    Change-Id: I0735f79354bc9fdb141e7a559517268e8ab648ec
    Closes-Bug: 1501077

Changed in magnum:
status: In Progress → Fix Committed
Adrian Otto (aotto)
Changed in magnum:
milestone: none → mitaka-1
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.