mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-03-04 09:48:19 +01:00
Merge pull request #7712 from ErikEk/neutrinorpc-deprecate-getblockhash
Neutrinorpc: deprecate getblockhash
This commit is contained in:
commit
a043cca77a
6 changed files with 25 additions and 8 deletions
|
@ -35,6 +35,10 @@ package](https://github.com/lightningnetwork/lnd/pull/7356)
|
|||
API can no longer be used to set/unset protocol features that are defined by
|
||||
LND.
|
||||
|
||||
* [Neutrinorpc getblockhash has
|
||||
been deprecated](https://github.com/lightningnetwork/lnd/pull/7712). Endpoint
|
||||
has been moved to the chainrpc sub-server.
|
||||
|
||||
Custom node announcement feature bits can also be specified in config using
|
||||
the `dev` build tag and `--protocol.custom-nodeann`, `--protocol.custom-init`
|
||||
and `--protocol.custom-invoice` flags to set feature bits for various feature
|
||||
|
@ -79,6 +83,7 @@ unlock or create.
|
|||
* Daniel McNally
|
||||
* Elle Mouton
|
||||
* Erik Arvstedt
|
||||
* ErikEk
|
||||
* hieblmi
|
||||
* Jordi Montes
|
||||
* Matt Morehouse
|
||||
|
|
|
@ -1156,7 +1156,7 @@ var file_neutrinorpc_neutrino_proto_rawDesc = []byte{
|
|||
0x67, 0x68, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x68, 0x65, 0x69, 0x67, 0x68,
|
||||
0x74, 0x22, 0x2a, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x61, 0x73,
|
||||
0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x61, 0x73,
|
||||
0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x68, 0x61, 0x73, 0x68, 0x32, 0x82, 0x05,
|
||||
0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x68, 0x61, 0x73, 0x68, 0x32, 0x87, 0x05,
|
||||
0x0a, 0x0b, 0x4e, 0x65, 0x75, 0x74, 0x72, 0x69, 0x6e, 0x6f, 0x4b, 0x69, 0x74, 0x12, 0x41, 0x0a,
|
||||
0x06, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x1a, 0x2e, 0x6e, 0x65, 0x75, 0x74, 0x72, 0x69,
|
||||
0x6e, 0x6f, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x75,
|
||||
|
@ -1191,16 +1191,17 @@ var file_neutrinorpc_neutrino_proto_rawDesc = []byte{
|
|||
0x65, 0x75, 0x74, 0x72, 0x69, 0x6e, 0x6f, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x46,
|
||||
0x69, 0x6c, 0x74, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x6e,
|
||||
0x65, 0x75, 0x74, 0x72, 0x69, 0x6e, 0x6f, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x46,
|
||||
0x69, 0x6c, 0x74, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x53, 0x0a,
|
||||
0x69, 0x6c, 0x74, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x58, 0x0a,
|
||||
0x0c, 0x47, 0x65, 0x74, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x61, 0x73, 0x68, 0x12, 0x20, 0x2e,
|
||||
0x6e, 0x65, 0x75, 0x74, 0x72, 0x69, 0x6e, 0x6f, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65, 0x74, 0x42,
|
||||
0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a,
|
||||
0x21, 0x2e, 0x6e, 0x65, 0x75, 0x74, 0x72, 0x69, 0x6e, 0x6f, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65,
|
||||
0x74, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x61, 0x73, 0x68, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
|
||||
0x73, 0x65, 0x42, 0x33, 0x5a, 0x31, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d,
|
||||
0x2f, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x6e, 0x69, 0x6e, 0x67, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72,
|
||||
0x6b, 0x2f, 0x6c, 0x6e, 0x64, 0x2f, 0x6c, 0x6e, 0x72, 0x70, 0x63, 0x2f, 0x6e, 0x65, 0x75, 0x74,
|
||||
0x72, 0x69, 0x6e, 0x6f, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
0x73, 0x65, 0x22, 0x03, 0x88, 0x02, 0x01, 0x42, 0x33, 0x5a, 0x31, 0x67, 0x69, 0x74, 0x68, 0x75,
|
||||
0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6c, 0x69, 0x67, 0x68, 0x74, 0x6e, 0x69, 0x6e, 0x67, 0x6e,
|
||||
0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2f, 0x6c, 0x6e, 0x64, 0x2f, 0x6c, 0x6e, 0x72, 0x70, 0x63,
|
||||
0x2f, 0x6e, 0x65, 0x75, 0x74, 0x72, 0x69, 0x6e, 0x6f, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72,
|
||||
0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
|
|
|
@ -47,9 +47,12 @@ service NeutrinoKit {
|
|||
rpc GetCFilter (GetCFilterRequest) returns (GetCFilterResponse);
|
||||
|
||||
/*
|
||||
Deprecated, use chainrpc.GetBlockHash instead.
|
||||
GetBlockHash returns the header hash of a block at a given height.
|
||||
*/
|
||||
rpc GetBlockHash (GetBlockHashRequest) returns (GetBlockHashResponse);
|
||||
rpc GetBlockHash (GetBlockHashRequest) returns (GetBlockHashResponse) {
|
||||
option deprecated = true;
|
||||
}
|
||||
}
|
||||
|
||||
message StatusRequest {
|
||||
|
|
|
@ -83,7 +83,7 @@
|
|||
},
|
||||
"/v2/neutrino/blockhash/{height}": {
|
||||
"get": {
|
||||
"summary": "GetBlockHash returns the header hash of a block at a given height.",
|
||||
"summary": "Deprecated, use chainrpc.GetBlockHash instead.\nGetBlockHash returns the header hash of a block at a given height.",
|
||||
"operationId": "NeutrinoKit_GetBlockHash",
|
||||
"responses": {
|
||||
"200": {
|
||||
|
|
|
@ -19,5 +19,6 @@ http:
|
|||
get: "/v2/neutrino/blockheader/{hash}"
|
||||
- selector: neutrinorpc.NeutrinoKit.GetCFilter
|
||||
get: "/v2/neutrino/cfilter/{hash}"
|
||||
# deprecated
|
||||
- selector: neutrinorpc.NeutrinoKit.GetBlockHash
|
||||
get: "/v2/neutrino/blockhash/{height}"
|
||||
|
|
|
@ -36,6 +36,9 @@ type NeutrinoKitClient interface {
|
|||
GetBlock(ctx context.Context, in *GetBlockRequest, opts ...grpc.CallOption) (*GetBlockResponse, error)
|
||||
// GetCFilter returns a compact filter from a block.
|
||||
GetCFilter(ctx context.Context, in *GetCFilterRequest, opts ...grpc.CallOption) (*GetCFilterResponse, error)
|
||||
// Deprecated: Do not use.
|
||||
//
|
||||
// Deprecated, use chainrpc.GetBlockHash instead.
|
||||
// GetBlockHash returns the header hash of a block at a given height.
|
||||
GetBlockHash(ctx context.Context, in *GetBlockHashRequest, opts ...grpc.CallOption) (*GetBlockHashResponse, error)
|
||||
}
|
||||
|
@ -111,6 +114,7 @@ func (c *neutrinoKitClient) GetCFilter(ctx context.Context, in *GetCFilterReques
|
|||
return out, nil
|
||||
}
|
||||
|
||||
// Deprecated: Do not use.
|
||||
func (c *neutrinoKitClient) GetBlockHash(ctx context.Context, in *GetBlockHashRequest, opts ...grpc.CallOption) (*GetBlockHashResponse, error) {
|
||||
out := new(GetBlockHashResponse)
|
||||
err := c.cc.Invoke(ctx, "/neutrinorpc.NeutrinoKit/GetBlockHash", in, out, opts...)
|
||||
|
@ -142,6 +146,9 @@ type NeutrinoKitServer interface {
|
|||
GetBlock(context.Context, *GetBlockRequest) (*GetBlockResponse, error)
|
||||
// GetCFilter returns a compact filter from a block.
|
||||
GetCFilter(context.Context, *GetCFilterRequest) (*GetCFilterResponse, error)
|
||||
// Deprecated: Do not use.
|
||||
//
|
||||
// Deprecated, use chainrpc.GetBlockHash instead.
|
||||
// GetBlockHash returns the header hash of a block at a given height.
|
||||
GetBlockHash(context.Context, *GetBlockHashRequest) (*GetBlockHashResponse, error)
|
||||
mustEmbedUnimplementedNeutrinoKitServer()
|
||||
|
|
Loading…
Add table
Reference in a new issue