sdnfv / openNetVM

A high performance container-based NFV platform from GW and UCR.
http://sdnfv.github.io/onvm/
Other
263 stars 136 forks source link

[Bug Fix] NF Advanced Ring Thread Process NF Shutdown Messages #111

Closed dennisafa closed 5 years ago

dennisafa commented 5 years ago

When running the advanced rings mode in speed tester and scaling, closing the manager would not kill the NF running. (referencing #105 )

Summary:

This adds a message handler in the advanced rings loop that listens for the MSG_STOP macro sent by the manager.

Usage:

This PR includes
Resolves issues
Breaking API changes
Internal API changes
Usability improvements
Bug fixes 💥
New functionality
New NF/onvm_mgr args
Changes to starting NFs
Dependency updates
Web stats updates

Merging notes:

TODO before merging :

Test Plan:

Run the manager, then run speed tester (or scaling) with advanced ring mode: ./go.sh 1 -d 1 -a Close the manager, assure that the NF is stopping.

Review:

@koolzz @kevindweb I was thinking for sanity checks maybe try running several of the same NF and speed tester + scaling then closing manager.

(optional) Subscribers: << @-mention people who probably care about these changes >>

onvm commented 5 years ago

In response to PR creation

CI Message

Your results will arrive shortly

onvm commented 5 years ago

In response to PR creation

CI Message

Run successful see results: [Results from nimbnode30] Median TX pps for Speed Tester: 35184761

Linter Failed

examples/arp_response/arp_response.c:284: Lines should be <= 120 characters long [whitespace/line_length] [5] Total errors found: 1 examples/flow_table/openflow.h:50: Using deprecated casting style. Use static_cast(...) instead [readability/casting] [4] examples/flow_table/openflow.h:569: Extra space before ( in function call [whitespace/parens] [4] examples/flow_table/openflow.h:634: Extra space before ( in function call [whitespace/parens] [4] examples/flow_table/openflow.h:771: Extra space before ( in function call [whitespace/parens] [4] examples/flow_table/openflow.h:804: Extra space before ( in function call [whitespace/parens] [4] examples/flow_table/openflow.h:865: Extra space before ( in function call [whitespace/parens] [4] examples/flow_table/openflow.h:926: Extra space before ( in function call [whitespace/parens] [4] Total errors found: 7 examples/nf_router/nf_router.c:173: Lines should be <= 120 characters long [whitespace/line_length] [5] Total errors found: 1 examples/payload_scan/payload_scan.c:95: Lines should be <= 120 characters long [whitespace/line_length] [5] examples/payload_scan/payload_scan.c:114: Almost always, snprintf is better than strcpy [runtime/printf] [4] examples/payload_scan/payload_scan.c:126: Lines should be <= 120 characters long [whitespace/line_length] [5] Total errors found: 3 onvm/onvm_mgr/onvm_pkt.c:68: Are you taking an address of a cast? This is dangerous: could be a temp var. Take the address before doing the cast, rather than after [runtime/casting] [4] Total errors found: 1 onvm/onvm_mgr/onvm_stats.c:306: If an else has a brace on one side, it should have it on both [readability/braces] [5] Total errors found: 1 onvm/onvm_nflib/onvm_pkt_common.c:98: Are you taking an address of a cast? This is dangerous: could be a temp var. Take the address before doing the cast, rather than after [runtime/casting] [4] Total errors found: 1

koolzz commented 5 years ago

@onvm I need a pr with linter conflicts

onvm commented 5 years ago

@onvm I need a pr with linter conflicts

CI Message

Your results will arrive shortly

onvm commented 5 years ago

@onvm I need a pr with linter conflicts

CI Message

Error: ERROR: Script failed on nimbnode30

koolzz commented 5 years ago

@onvm should be good to go

onvm commented 5 years ago

@onvm should be good to go

CI Message

Your results will arrive shortly

koolzz commented 5 years ago

@onvm jk, but now for sure

onvm commented 5 years ago

@onvm jk, but now for sure

CI Message

Your results will arrive shortly

koolzz commented 5 years ago

@onvm is the linter pleased

onvm commented 5 years ago

@onvm is the linter pleased

CI Message

Your results will arrive shortly

dennisafa commented 5 years ago

@onvm how's your weekend been?

onvm commented 5 years ago

@onvm how's your weekend been?

CI Message

Another CI run in progress, please try again in 15 minutes