-
Notifications
You must be signed in to change notification settings - Fork 344
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
Correctly expose injected UDP container ports #773
Correctly expose injected UDP container ports #773
Conversation
52054ea
to
ce2334c
Compare
There seems to be a formatting issue with the
|
Signed-off-by: Gary Fritz <fritz@iz.de>
@jpkrohling My bad, first time hands-on w/ Go. Formatting issue solved 👍(after downgrading Go). |
c387aff
to
5393098
Compare
Changed rebased+squashed. |
5393098
to
7754761
Compare
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. There was a test failure, but might be an intermittent/timeout problem.
pkg/service/agent_test.go
Outdated
5775, | ||
6831, | ||
6832: | ||
assert.Equal(t, port.Protocol, corev1.ProtocolUDP, "Expected port %v to be UDP, but wasn't", port) |
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.
The second argument to Equal
is the expected value, followed by the actual value:
assert.Equal(t, corev1.ProtocolUDP, port.Protocol, ...)
Of course, this is not blocking the PR :)
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.
Well, right! But then, for the same reason, the next assert arguments should also be swapped as well 😉
jaeger-operator/pkg/service/agent_test.go
Line 32 in 3020ae4
assert.Equal(t, v, true, "Expected port %v to be specified, but wasn't", k) |
After rebasing and seeing the test cases fail, I ran into the same failures locally.
And they do, indeed, complain ports or port forwarding. So I'm not sure did maybe sth change from 1.14 to 1.15? In that case, it is good that the test cases fail.
E1118 15:55:18.902332 45722 portforward.go:400] an error occurred forwarding 57500 -> 14268: error forwarding port 14268 to pod 65359bd8523f97b65fb2350d0639d7bc5de8e68e7c752614c2c63e61d76755d0, uid : exit status 1: 2019/11/18 14:55:18 socat[24686] E connect(5, AF=2 127.0.0.1:14268, 16): Connection refused
E1118 15:57:18.950977 45722 portforward.go:408] error closing listener: close tcp4 127.0.0.1:57499: use of closed network connection
E1118 15:57:18.951003 45722 portforward.go:408] error closing listener: close tcp6 [::1]:57499: use of closed network connection
E1118 15:57:18.952080 45722 portforward.go:408] error closing listener: close tcp4 127.0.0.1:57500: use of closed network connection
E1118 15:57:18.953160 45722 portforward.go:408] error closing listener: close tcp6 [::1]:57500: use of closed network connection
To my understanding, these errors occur in
jaeger-operator/test/e2e/smoketest.go
Line 69 in 3020ae4
closer.Close() |
Signed-off-by: Gary Fritz <fritz@iz.de>
7754761
to
998beb9
Compare
Well, errors are gone. Maybe it was a timeout issue. Looks good now 😉 |
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.
Thank you for your contribution!
This MR should fix the missing
Protocol
properties for three of the created container ports of injected sidecar containers (#771). A test case should cover this - at least for default port numbers. Also, I updated the test case for standalone agent containers to cover the protocols.