-
Notifications
You must be signed in to change notification settings - Fork 636
Remove gRPC broadcast API #659
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
Conversation
Signed-off-by: Thane Thomson <connect@thanethomson.com>
Signed-off-by: Thane Thomson <connect@thanethomson.com>
f61b0a0
to
f62d564
Compare
Signed-off-by: Thane Thomson <connect@thanethomson.com>
Signed-off-by: Thane Thomson <connect@thanethomson.com>
Update the config section of the docs with a more recently generated `config.toml` file (generated using the current code on `main`). Signed-off-by: Thane Thomson <connect@thanethomson.com>
f5183ea
to
02795ca
Compare
This reverts commit ce2bfa1. Signed-off-by: Thane Thomson <connect@thanethomson.com>
Signed-off-by: Thane Thomson <connect@thanethomson.com>
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.
Legit.
This is a superficial review, somehow, based on the file diffs. I haven't checked whether everything from the current gRPC was removed, for instance, nor run tests and similar stuff.
docs/core/configuration.md
Outdated
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.
Here I assume you are updating the "version" of the config file from docs/toml.go
, right?
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.
Yes, I generated a configuration file using cometbft init
using the code on main
and updated the docs for the configuration file.
Signed-off-by: Thane Thomson <connect@thanethomson.com>
Signed-off-by: Thane Thomson <connect@thanethomson.com>
// we expose a simplified api over grpc for convenience to app devs | ||
grpcListenAddr := n.config.RPC.GRPCListenAddress | ||
if grpcListenAddr != "" { | ||
config := rpcserver.DefaultConfig() | ||
config.MaxBodyBytes = n.config.RPC.MaxBodyBytes | ||
config.MaxHeaderBytes = n.config.RPC.MaxHeaderBytes | ||
// NOTE: GRPCMaxOpenConnections is used, not MaxOpenConnections | ||
config.MaxOpenConnections = n.config.RPC.GRPCMaxOpenConnections | ||
// If necessary adjust global WriteTimeout to ensure it's greater than | ||
// TimeoutBroadcastTxCommit. | ||
// See https://github.com/tendermint/tendermint/issues/3435 | ||
if config.WriteTimeout <= n.config.RPC.TimeoutBroadcastTxCommit { | ||
config.WriteTimeout = n.config.RPC.TimeoutBroadcastTxCommit + 1*time.Second | ||
} | ||
listener, err := rpcserver.Listen(grpcListenAddr, config.MaxOpenConnections) | ||
if err != nil { | ||
return nil, err | ||
} | ||
go func() { | ||
//nolint:staticcheck // SA1019: core_grpc.StartGRPCClient is deprecated: A new gRPC API will be introduced after v0.38. | ||
if err := grpccore.StartGRPCServer(env, listener); err != nil { | ||
n.Logger.Error("Error starting gRPC server", "err", err) | ||
} | ||
}() | ||
listeners = append(listeners, listener) | ||
|
||
} |
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.
This prevents the node from creating any gRPC server attached to the node. #81 will reintroduce something like this.
In some places, the Go names of parameters are used instead of their TOML versions. This replaces the Go names with TOML versions, and fixes a few grammatical and formatting issues in the configuration template and docs. Signed-off-by: Thane Thomson <connect@thanethomson.com>
Signed-off-by: Thane Thomson <connect@thanethomson.com>
* Remove gRPC functionality and usage Signed-off-by: Thane Thomson <connect@thanethomson.com> * Remove all gRPC-related configuration functionality Signed-off-by: Thane Thomson <connect@thanethomson.com> * Add changelog entry Signed-off-by: Thane Thomson <connect@thanethomson.com> * ci: Force use of very latest Go version for govulncheck Signed-off-by: Thane Thomson <connect@thanethomson.com> * docs: Update config section Update the config section of the docs with a more recently generated `config.toml` file (generated using the current code on `main`). Signed-off-by: Thane Thomson <connect@thanethomson.com> * Revert "ci: Force use of very latest Go version for govulncheck" This reverts commit ce2bfa1. Signed-off-by: Thane Thomson <connect@thanethomson.com> * config: Fix grammar in doc comment Signed-off-by: Thane Thomson <connect@thanethomson.com> * config: Remove # for clarity Signed-off-by: Thane Thomson <connect@thanethomson.com> * config: Fix comments to clarify In some places, the Go names of parameters are used instead of their TOML versions. This replaces the Go names with TOML versions, and fixes a few grammatical and formatting issues in the configuration template and docs. Signed-off-by: Thane Thomson <connect@thanethomson.com> * docs: Remove extraneous # Signed-off-by: Thane Thomson <connect@thanethomson.com> --------- Signed-off-by: Thane Thomson <connect@thanethomson.com>
Closes #650.
Commits 11c1f34 and 8e2d5ee can be reviewed independently. The vast majority of code changes here are purely removals of the generated Go code.
PR checklist
.changelog
(we use unclog to manage our changelog)docs/
orspec/
) and code comments