Skip to content

Instantly share code, notes, and snippets.

# coding=utf-8
import datetime
import sys
import time
import threading
import traceback
import SocketServer
from dnslib import *
I just had my meeting with Henry in person. I have received clear (yet complicated) direction and tasking:
Ressurect https://review.openstack.org/#/c/99965/42 in neutron first and run with it for some time and make https://review.openstack.org/#/c/248190/ use it
Repropose it to oslo.db for citizenship in that project
Create the tests for neutron's migrations
My notes (in an unorganized manner):
Ressurect https://review.openstack.org/#/c/99965/42 in neutron first and run with it for some time
Then propose it to oslo.db
Can take out everything about downgrade
SELECT quark_mac_address_ranges.id AS quark_mac_address_ranges_id, quark_mac_address_ranges.created_at AS quark_mac_address_ranges_created_at, quark_mac_address_ranges.cidr AS quark_mac_address_ranges_cidr, quark_mac_address_ranges.first_address AS quark_mac_address_ranges_first_address, quark_mac_address_ranges.last_address AS quark_mac_address_ranges_last_address, quark_mac_address_ranges.next_auto_assign_mac AS quark_mac_address_ranges_next_auto_assign_mac, quark_mac_address_ranges.do_not_use AS quark_mac_address_ranges_do_not_use, count(quark_mac_addresses.address) AS count
FROM quark_mac_address_ranges LEFT OUTER JOIN quark_mac_addresses ON quark_mac_address_ranges.id = quark_mac_addresses.mac_address_range_id
WHERE quark_mac_address_ranges.next_auto_assign_mac != %s AND quark_mac_address_ranges.do_not_use = %s GROUP BY quark_mac_address_ranges.id ORDER BY count(quark_mac_addresses.address) DESC
LIMIT %s FOR UPDATE
DFW - CHG0059760
ORD - CHG0059819
IAD - CHG0059820
HKG - CHG0059821
LON - CHG0059822
SYD - CHG0059823
Create/Mature working REST endpoint.
Recent reviews only seem to be maturing with several nits from core reviewers.
Mature and flesh out unit/integration testing new extension API.
Unit tests covers broad swath of the API.
Integration tests: I’ve been wrestling trying to create and actually validate tempest tests. Scenarios involve setting up networks, subnets, adding ports, setting up floating IP subnets, etc. Working diligently on this.
Update Neutron client to support this new API.
Looks like work was done for CLI here: https://github.com/manjeetbhatia/python-neutronclient/commit/97f016a4d43fd445ec1d7e8225de4709dd525660
Not sure how we get this into upstream. Do we integrate this into the existing patch …or… create a new bug for “python client update to handle network-ip-availability”?
Add Relevant Lines:
# Linuxbridge Settings
Q_AGENT=linuxbridge
LB_PHYSICAL_INTERFACE=eth0
PUBLIC_PHYSICAL_NETWORK=default
LB_INTERFACE_MAPPINGS=default:eth0
Remove Relevant Lines:
Change: /etc/lxc/default.conf
lxc.network.type = veth
lxc.network.script.up = /etc/lxc/ovs_up
lxc.network.script.down = /etc/lxc/ovs_down
lxc.network.flags = up
lxc.network.hwaddr = 00:16:3e:xx:xx:xx
OVS_UP
#!/bin/bash
nosetests horizon --nocapture --nologcapture --exclude-dir=horizon/conf/ --exclude-dir=horizon/test/customization --cover-package=horizon --cover-inclusive --all-modules --exclude-dir=openstack_dashboard/test/integration_tests --verbosity=1
Creating test database for alias 'default'...
...................................................................................................................................................................SSSSSSS............
----------------------------------------------------------------------
Ran 182 tests in 33.181s
OK (SKIP=7)
<MagicMock name='handle()' id='4454562000'><MagicMock name='handle()' id='4454740368'>Destroying test database for alias 'default'...
Running openstack_dashboard tests
nosetests openstack_dashboard --nocapture --nologcapture --cover-package=openstack_dashboard --cover-inclusive --all-modules --exclude-dir=openstack_dashboard/test/integration_tests --verbosity=1
======================================================================
ERROR: test_delete_network (openstack_dashboard.dashboards.admin.networks.tests.NetworkTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/Users/bria9288/Documents/openstack/horizon/openstack_dashboard/test/helpers.py", line 112, in instance_stub_out
return fn(self, *args, **kwargs)
File "/Users/bria9288/Documents/openstack/horizon/openstack_dashboard/dashboards/admin/networks/tests.py", line 628, in test_delete_network
network.id).\
File "/Users/bria9288/Documents/openstack/horizon/openstack_dashboard/api/neutron.py", line 1034, in network_ip_availability_show
ip_availability = neutronclient(request).show_network_ip_availability(
@stajkowski
stajkowski / gist:abb1669d93dc21cafb17
Created March 11, 2016 04:13
openstack_dashboard.dashboards.admin.networks.tests.py
# Copyright 2012 NEC Corporation
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT