Skip to content

vpc/server: Fix network statistics for vpc#3944

Merged
yadvr merged 1 commit into
apache:4.15from
ustcweizhou:4.14-fix-vpc-statistics
Apr 1, 2021
Merged

vpc/server: Fix network statistics for vpc#3944
yadvr merged 1 commit into
apache:4.15from
ustcweizhou:4.14-fix-vpc-statistics

Conversation

@ustcweizhou
Copy link
Copy Markdown
Contributor

Description

This contains 3 main changes
(1) add NETWORK_STATS_ethX for all nics with public ips in VPC VRs (current: NETWORK_STATS_eth1)
(2) DO NOT create records in user_statistics for each VPC tier (only one record per public nic per VPC VR)
(3) send NetworkUsageCommand before unplugging a NIC with public IPs from VPC VR

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)

Screenshots (if appropriate):

How Has This Been Tested?

@yadvr
Copy link
Copy Markdown
Member

yadvr commented Mar 6, 2020

Is this in progress or ready for review @ustcweizhou ?

@weizhouapache
Copy link
Copy Markdown
Member

Is this in progress or ready for review @ustcweizhou ?

@rhtyd it is ready for review

travis failed, I will check it.

@DaanHoogland
Copy link
Copy Markdown
Contributor

Is this in progress or ready for review @ustcweizhou ?

@rhtyd it is ready for review

travis failed, I will check it.

don't bother @weizhouapache those seem to be the usual log too long errors. Travis stops at 4GB or so.

@weizhouapache
Copy link
Copy Markdown
Member

Is this in progress or ready for review @ustcweizhou ?

@rhtyd it is ready for review
travis failed, I will check it.

don't bother @weizhouapache those seem to be the usual log too long errors. Travis stops at 4GB or so.

thanks @DaanHoogland for your info.

@yadvr
Copy link
Copy Markdown
Member

yadvr commented Jun 12, 2020

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✔centos7 ✔debian. JID-1356

@yadvr yadvr changed the base branch from master to 4.14 June 13, 2020 00:43
@yadvr
Copy link
Copy Markdown
Member

yadvr commented Jun 13, 2020

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✖centos7 ✖debian. JID-1368

@yadvr yadvr closed this Jul 2, 2020
@yadvr yadvr reopened this Jul 2, 2020
@yadvr
Copy link
Copy Markdown
Member

yadvr commented Jul 2, 2020

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✔centos7 ✔debian. JID-1508

@yadvr
Copy link
Copy Markdown
Member

yadvr commented Jul 2, 2020

@blueorangutan test

@blueorangutan
Copy link
Copy Markdown

@rhtyd a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@yadvr
Copy link
Copy Markdown
Member

yadvr commented Jul 4, 2020

@blueorangutan test

@blueorangutan
Copy link
Copy Markdown

@rhtyd a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@blueorangutan
Copy link
Copy Markdown

Trillian test result (tid-1976)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 49953 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr3944-t1976-kvm-centos7.zip
Intermittent failure detected: /marvin/tests/smoke/test_kubernetes_clusters.py
Intermittent failure detected: /marvin/tests/smoke/test_kubernetes_supported_versions.py
Intermittent failure detected: /marvin/tests/smoke/test_router_dhcphosts.py
Smoke tests completed. 82 look OK, 1 have error(s)
Only failed tests results shown below:

Test Result Time (s) Test File
test_01_add_delete_kubernetes_supported_version Error 1807.31 test_kubernetes_supported_versions.py

Copy link
Copy Markdown
Member

@yadvr yadvr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, did not test it

@yadvr yadvr requested review from DaanHoogland and nvazquez July 7, 2020 07:16
Copy link
Copy Markdown
Contributor

@DaanHoogland DaanHoogland left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

code looks good and i like the simplification, but ...
@PaulAngus @andrijapanicsb do we know people that use per tier billing somehow? this will impede those.

@DaanHoogland DaanHoogland requested a review from yadvr October 20, 2020 09:48
@DaanHoogland DaanHoogland marked this pull request as draft November 17, 2020 18:50
@DaanHoogland
Copy link
Copy Markdown
Contributor

@weizhouapache converted to draft so it is clear 4.15 is not waiting for it. please change back if you disagree

@yadvr
Copy link
Copy Markdown
Member

yadvr commented Dec 8, 2020

@ustcweizhou @weizhouapache can you comment/explore the cases where this could add regression for usage/billing?

@ustcweizhou ustcweizhou force-pushed the 4.14-fix-vpc-statistics branch from 09cec4b to b3403e2 Compare December 8, 2020 13:18
@weizhouapache weizhouapache marked this pull request as ready for review December 8, 2020 13:22
@weizhouapache
Copy link
Copy Markdown
Member

@DaanHoogland @rhtyd
this fixes bugs in network statistics for vpc.
cloudstack should collect network statistics from the public interfaces, not from eth1 which is default public nic for vpc but there might be more public nics, not from vpc tiers.
in a word, there is not per tier billing. there are only statistics for all public interfaces in VR for isolated network and vpc, and for all nics on shared network.

@DaanHoogland
Copy link
Copy Markdown
Contributor

@weizhouapache the changes seem logical to me and given your description above seem to do what you intended, but we have no testdescription and no integration tests to guarantee against regressions. I'm a bit reluctant to include this just before release. can we with just the current set of smoke tests? cc @rhtyd @sureshanaparti are there any others we could ask for testing this functionality?

@weizhouapache
Copy link
Copy Markdown
Member

@weizhouapache the changes seem logical to me and given your description above seem to do what you intended, but we have no testdescription and no integration tests to guarantee against regressions. I'm a bit reluctant to include this just before release. can we with just the current set of smoke tests? cc @rhtyd @sureshanaparti are there any others we could ask for testing this functionality?

@DaanHoogland let's move this to 4.15.1.0 (and 4.14.1.0)

@DaanHoogland DaanHoogland modified the milestones: 4.14.1.0, 4.14.2.0 Dec 10, 2020
@yadvr yadvr modified the milestones: 4.14.2.0, 4.15.1.0 Jan 27, 2021
@yadvr yadvr changed the base branch from 4.14 to 4.15 January 27, 2021 14:00
@shwstppr
Copy link
Copy Markdown
Contributor

@weizhouapache conflicts here

This contains 3 main changes
(1) add NETWORK_STATS_ethX for all nics with public ips in VPC VRs (current: NETWORK_STATS_eth1)
(2) DO NOT create records in user_statistics for each VPC tier (only one record per public nic per VPC VR)
(3) send NetworkUsageCommand before unplugging a NIC with public IPs from VPC VR
@ustcweizhou ustcweizhou force-pushed the 4.14-fix-vpc-statistics branch from b3403e2 to 6e83c77 Compare February 22, 2021 13:14
@shwstppr
Copy link
Copy Markdown
Contributor

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@shwstppr a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✔centos7 ✔centos8 ✔debian. JID-2798

@apache apache deleted a comment from blueorangutan Feb 23, 2021
@apache apache deleted a comment from blueorangutan Feb 23, 2021
@DaanHoogland
Copy link
Copy Markdown
Contributor

@blueorangutan test

@blueorangutan
Copy link
Copy Markdown

@DaanHoogland a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@blueorangutan
Copy link
Copy Markdown

Trillian test result (tid-3601)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 31877 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr3944-t3601-kvm-centos7.zip
Intermittent failure detected: /marvin/tests/smoke/test_internal_lb.py
Smoke tests completed. 86 look OK, 0 have error(s)
Only failed tests results shown below:

Test Result Time (s) Test File

@DaanHoogland
Copy link
Copy Markdown
Contributor

@rhtyd @weizhouapache no discussion has happened, do we dare merge this?

@weizhouapache
Copy link
Copy Markdown
Member

@rhtyd @weizhouapache no discussion has happened, do we dare merge this?

@DaanHoogland @rhtyd
it is ok for me to merge it :-D

we have this patch on our productions. looks good until now.

Copy link
Copy Markdown
Member

@yadvr yadvr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Proxying my lgtm based on Daan's and Wei's comments/review.

@yadvr yadvr merged commit 63c91c1 into apache:4.15 Apr 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants