-
Notifications
You must be signed in to change notification settings - Fork 9
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
iptables: refactor helper, add RuleSet #373
Conversation
e3ed96d
to
3e9e1b2
Compare
92a4553
to
33abf21
Compare
3bcf65e
to
ceb2cba
Compare
@@ -1,11 +1,12 @@ | |||
package iptables | |||
package protocol_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.
What is the reason for changing the convention we have been using of not creating a different package for tests? Does this bring any advantage? I prefer to maintain consistency across packages
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.
I think I made this change out of habit as I was testing exported functions only, I agree we should keep consistency. I can change it real quick :)
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.
LGTM. I only not fully in favor of changing the implicit convention of not using test packages. I wold prefer to maintain consistency across the project.
4339e3e
to
43dea2e
Compare
Description
This PR continues the iptables refactoring work initiated by #357, by keeping a simple helper that works with structured rules and putting the auto-removing logic into a new object called
RuleSet
.The TrafficRedirector has been refactored to use the new helper, but not the
RuleSet
.Checklist:
make lint
) and all checks pass.make test
) and all tests pass.make integration-xxx
for affected packages)make e2e-xxx
fordisruptors
, orcluster
related changes)