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

server: Bump to hashicorp/raft@v1.1.2 #1056

Merged
merged 2 commits into from Jun 7, 2020

Conversation

pengux
Copy link
Contributor

@pengux pengux commented Jun 5, 2020

The package raft has a breaking change in version v1.1.2 and uses the
hclog.Logger interface instead of the stdlib log.Logger. This fixes that
and allow nats-streaming-server to uses raft v1.1.2.

The package raft has a breaking change in version v1.1.2 and uses the
hclog.Logger interface instead of the stdlib log.Logger. This fixes that
and allow nats-streaming-server to uses raft v1.1.2.
@coveralls
Copy link

coveralls commented Jun 5, 2020

Coverage Status

Coverage increased (+0.003%) to 91.77% when pulling a77a42d on form3tech-oss:pn-update-to-latest-raft into efca85d on nats-io:master.

Copy link
Member

@kozlovic kozlovic left a comment

Choose a reason for hiding this comment

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

Thank you so much for this contribution! Let's see if go mod tidy clears up the reference to raft@v1.1.1.

go.sum Outdated
@@ -33,6 +33,8 @@ github.com/hashicorp/golang-lru v0.5.0 h1:CL2msUPvZTLb5O648aiLNJw3hnBxN2+1Jq8rCO
github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
github.com/hashicorp/raft v1.1.1 h1:HJr7UE1x/JrJSc9Oy6aDBHtNHUUBHjcQjTgvUVihoZs=
github.com/hashicorp/raft v1.1.1/go.mod h1:vPAJM8Asw6u8LxC3eJCUZmRP/E4QmUGE1R7g7k8sG/8=
Copy link
Member

Choose a reason for hiding this comment

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

I think a go mod tidy would have got rid of the ref to v1.1.1, no?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ran and pushed after a go mod tidy

return newNATSTransportWithLogger(id, conn, timeout, log.New(logOutput, "", log.LstdFlags))
logger := hclog.New(&hclog.LoggerOptions{
Name: natsLogAppName,
Level: hclog.Debug,
Copy link
Member

Choose a reason for hiding this comment

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

I would have set, set it to Trace, we do suppress according to streaming's debug/trace level, but I then realize that clustering.go's (rl *raftLogger) Write() is not looking for trace, so that is ok for now. I will see if I add trace level later.

Copy link
Member

@kozlovic kozlovic left a comment

Choose a reason for hiding this comment

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

LGTM. Thank you for the contribution!

@kozlovic kozlovic merged commit e15a1b0 into nats-io:master Jun 7, 2020
@pengux pengux deleted the pn-update-to-latest-raft branch June 7, 2020 18:35
kozlovic added a commit that referenced this pull request Jun 22, 2020
This was added to git incorrectly with PR #1056

[ci skip]

Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
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.

None yet

3 participants