-
Notifications
You must be signed in to change notification settings - Fork 132
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
Expose p2p connection of gateways and server (#150) #151
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #151 +/- ##
===========================================
+ Coverage 76.15% 76.27% +0.12%
===========================================
Files 69 69
Lines 5423 5451 +28
===========================================
+ Hits 4130 4158 +28
Misses 1293 1293 ☔ View full report in Codecov by Sentry. |
2bdbdfb
to
9ab8421
Compare
Hello @pagmatt, Here is a new version, I tried to make it as clean as I could get it on my own. I rebased it onto develop, but you can still easily check the latest changes because they are all in commit 9ab8421. I followed your suggestion to try and have a sort of In summary, the changes proposed in this PR are meant to accomplish the following:
Other minor changes coming with the last commit are:
Let me know your thoughts. |
Apologies for the late reply. Changes are ok with me, great work! I just left a minor comment |
* Patch code for ns-3.41 compatibility * Update CI to replicate the one of ns-3.41
Hello @pagmatt, I don't see your comment here |
My bad, the comment was still pending. You should be able to see it now |
+ remove NodeContainer install of NetworkServerHelper + add P2PGwRegistration_t helper structure to facilitate independent instantiation of P2P and server app
9ab8421
to
e0d0a61
Compare
This pull request is meant to fix the problem brought up in issue #150
NetworkServerHelper::Install
used to implicitly create a point-to-point connection between gateways and the network server. Specifically, this function would install aPointToPointNetDevice
on gateways, then required by theForwarderHelper
application installer on gateways. Thus, ifForwarderHelper::Install
was called beforeNetworkServerHelper::Install
in a custom simulation, it would generate a zero pointer runtime error with a non-descriptive message. This can be especially difficult to debug for a new user (happened to me as well in the past).Given that NetDevice installation is usually meant to happen in the main ns-3 simulation file, I propose to move it there. The idea is to make it explicit such that new users avoid committing the error described above. I also added clearer error messages via assertions requiring a
PointToPointNetDevice
to be present when callingForwarderHelper::Install
. Currently, the module only supports a p2p connection, later on we could extend this to support any type of connection between gateways and the network server.