-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
F5 P/O agent code change for Openstack Queens lbaasv2 #1405
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -50,8 +50,8 @@ def read_json(self): | |
self.esdJSONDict.update(fileJSONDict) | ||
|
||
except ValueError as err: | ||
LOG.error('ESD JSON File is invalid: %s', err) | ||
raise f5_ex.esdJSONFileInvalidException() | ||
LOG.error('ESD JSON File is invalid: %s', err) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. same as above. |
||
raise f5_ex.esdJSONFileInvalidException() | ||
|
||
return self.esdJSONDict | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -126,9 +126,9 @@ def old_setup_vcmp_method_test(mock_mgmt_root, mock_driver, mock_host_obj): | |
def test___init__(setup_vcmp_mgr): | ||
vcmp = setup_vcmp_mgr | ||
assert vcmp.vcmp_hosts != [] | ||
assert len(vcmp.vcmp_hosts) is 2 | ||
assert len(vcmp.vcmp_hosts) == 2 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. these are common places which IMO is irrelevant to queens_engineering. put them into a separate commit so that they are submitted into each branch we need?(e.g. 9.6 9.7 etc, if needed). There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I will do it, after I fix the loopback4 things, or you can help me a bit :D |
||
assert vcmp.vcmp_hosts[0]['guests'] != [] | ||
assert len(vcmp.vcmp_hosts[0]['guests']) is 1 | ||
assert len(vcmp.vcmp_hosts[0]['guests']) == 1 | ||
|
||
|
||
def test___init__no_vcmp_hosts(): | ||
|
@@ -237,13 +237,13 @@ def test__check_vcmp_host_assignments_bad_platform(setup_vcmp_method_test): | |
def test__get_vlan_use_count(setup_vcmp_method_test): | ||
vcmp, mock_bigip = setup_vcmp_method_test | ||
use_cnt = vcmp._get_vlan_use_count(vcmp.vcmp_hosts[0], 'test_vlan') | ||
assert use_cnt is 1 | ||
assert use_cnt == 1 | ||
|
||
|
||
def test__get_vlan_use_count_zero(setup_vcmp_method_test): | ||
vcmp, mock_bigip = setup_vcmp_method_test | ||
use_cnt = vcmp._get_vlan_use_count(vcmp.vcmp_hosts[0], 'test_vlan_2') | ||
assert use_cnt is 0 | ||
assert use_cnt == 0 | ||
|
||
|
||
def test__is_vlan_assoc_with_vcmp_guest(setup_vcmp_method_test): | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this way seems to make it quite complicated. should probably Try this way: copy the content of INTERFACE_OPTS into this file , then this line can be always the same between each branch. each branch has the same and we dont have to consider queens differently.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Frankly speaking, I think it would not be that necessary to duplicate code and change the dependency.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in that way, we do not need a separate queens branch. we can still use our existing 9.8 branch for queens, as well as the original M N, O. thus, avoid many inconveniences for maintenance work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
agree