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

Use New Admin Port Flag #1281

Merged
merged 1 commit into from
Oct 29, 2020
Merged

Conversation

johanavril
Copy link
Contributor

@johanavril johanavril commented Oct 28, 2020

Closes #1276

@codecov
Copy link

codecov bot commented Oct 28, 2020

Codecov Report

Merging #1281 into master will increase coverage by 0.01%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1281      +/-   ##
==========================================
+ Coverage   87.31%   87.32%   +0.01%     
==========================================
  Files          90       90              
  Lines        4942     4947       +5     
==========================================
+ Hits         4315     4320       +5     
  Misses        464      464              
  Partials      163      163              
Impacted Files Coverage Δ
pkg/deployment/agent.go 96.21% <100.00%> (ø)
pkg/deployment/all_in_one.go 100.00% <100.00%> (ø)
pkg/deployment/collector.go 96.50% <100.00%> (ø)
pkg/deployment/ingester.go 95.90% <100.00%> (ø)
pkg/deployment/query.go 100.00% <100.00%> (ø)
pkg/inject/sidecar.go 94.14% <100.00%> (ø)
pkg/util/util.go 94.77% <100.00%> (+0.20%) ⬆️

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 fda5695...74514ea. Read the comment docs.

pkg/deployment/agent.go Outdated Show resolved Hide resolved
Copy link
Contributor

@jpkrohling jpkrohling left a comment

Choose a reason for hiding this comment

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

LGTM. If you don't want to use the table tests for the unit tests, let me know and I'll approve this.

@@ -353,6 +353,35 @@ func TestGetPortSpecified(t *testing.T) {
assert.Equal(t, int32(6831), GetPort("--processor.jaeger-compact.server-host-port=", args, 1234))
}

func TestGetAdminPortDefault(t *testing.T) {
Copy link
Contributor

Choose a reason for hiding this comment

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

This looks good, but you could have used a table test here, with the args, the default port and the expected outcome as the test's struct:

https://github.com/golang/go/wiki/TableDrivenTests

Copy link
Contributor Author

Choose a reason for hiding this comment

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

That looks better, will change to table test now

will check the new flag for retrieving admin port and if not
available will use the old one instead

Signed-off-by: johanavril <[email protected]>
@jpkrohling
Copy link
Contributor

Thanks for your contribution!

@mergify mergify bot merged commit edb28dc into jaegertracing:master Oct 29, 2020
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.

Usage of deprecated 'admin-http-port' flag in the code
2 participants