Skip to content
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

network entity refactoring #77

Merged
merged 2 commits into from
Jul 12, 2018
Merged

network entity refactoring #77

merged 2 commits into from
Jul 12, 2018

Conversation

John-Lin
Copy link
Contributor

@John-Lin John-Lin commented Jul 9, 2018

All Test cases have to modify against current changes

@John-Lin John-Lin added the WIP label Jul 9, 2018
@John-Lin John-Lin force-pushed the johnlin/network-entity branch from 6fd94d4 to 7120a63 Compare July 12, 2018 01:16
@codecov-io
Copy link

codecov-io commented Jul 12, 2018

Codecov Report

Merging #77 into develop will increase coverage by 1.36%.
The diff coverage is 80.64%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop      #77      +/-   ##
===========================================
+ Coverage    69.68%   71.05%   +1.36%     
===========================================
  Files           32       32              
  Lines         1260     1247      -13     
===========================================
+ Hits           878      886       +8     
+ Misses         324      307      -17     
+ Partials        58       54       -4
Impacted Files Coverage Δ
src/server/handler_network.go 83.92% <100%> (+0.14%) ⬆️
src/networkprovider/network.go 100% <100%> (ø) ⬆️
src/networkprovider/fake.go 100% <100%> (ø) ⬆️
src/networkcontroller/network_controller.go 50.63% <60%> (+7.51%) ⬆️
src/networkprovider/ovs_netdev.go 69.23% <76.19%> (-5.77%) ⬇️
src/networkprovider/ovs_system.go 76.92% <76.92%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1eec4d1...3f0b324. Read the comment docs.

Copy link

@zyfdegh zyfdegh left a comment

Choose a reason for hiding this comment

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

Nice clean code, thank you. But there are some camel-case spelling.

PhysicalPorts: []entity.PhysicalPort{eth1},
Type: entity.OVSKernelspaceNetworkType,
Name: tName,
VLANTags: []int32{0, 2048, 4095},
Copy link

Choose a reason for hiding this comment

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

Need double check: you're using 4095, not 4096?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes! 4096 is a invalid number

@@ -7,27 +7,37 @@ import (
"github.com/linkernetworks/vortex/src/serviceprovider"
)

type FakeNetworkProvider struct {
entity.FakeNetwork
type fakenetworkprovider struct {
Copy link

Choose a reason for hiding this comment

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

fakeNetworkProvider

@@ -10,107 +10,98 @@ import (
"gopkg.in/mgo.v2/bson"
)

type OVSUserspaceNetworkProvider struct {
entity.OVSUserspaceNetwork
type userspacenetworkprovider struct {
Copy link

Choose a reason for hiding this comment

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

userspaceNetworkProvider

})
}
}
// func (suite *NetworkTestSuite) TestListNetwork() {
Copy link

Choose a reason for hiding this comment

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

Remove the comments, or use t.Skip()

@John-Lin John-Lin force-pushed the johnlin/network-entity branch 2 times, most recently from 2329b39 to 5544650 Compare July 12, 2018 07:34
@John-Lin John-Lin removed the WIP label Jul 12, 2018
@John-Lin John-Lin force-pushed the johnlin/network-entity branch from 5544650 to 1f5b746 Compare July 12, 2018 08:05
@John-Lin John-Lin force-pushed the johnlin/network-entity branch from 9d4670b to 3f0b324 Compare July 12, 2018 09:35
Copy link
Contributor

@hwchiu hwchiu left a comment

Choose a reason for hiding this comment

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

LGTM

@hwchiu hwchiu merged commit ed661fd into develop Jul 12, 2018
@hwchiu hwchiu deleted the johnlin/network-entity branch July 12, 2018 09:57
John-Lin pushed a commit that referenced this pull request Jul 25, 2018
network entity refactoring

Former-commit-id: 952a28b6da2a7f5d164ba4e2120155091091209f [formerly ed661fd]
Former-commit-id: 1f44b3288dca7441cee1f4d9cdb9a15894219a66
John-Lin pushed a commit that referenced this pull request Jul 25, 2018
network entity refactoring

Former-commit-id: 952a28b6da2a7f5d164ba4e2120155091091209f [formerly 952a28b6da2a7f5d164ba4e2120155091091209f [formerly ed661fd]]
Former-commit-id: 1f44b3288dca7441cee1f4d9cdb9a15894219a66
Former-commit-id: 4ba6a59
John-Lin pushed a commit that referenced this pull request Jul 25, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants