lnrpc: expose PINNED_SYNC for listpeers
This commit is contained in:
4 files changed
+790
-777
No files matched your search
+780
-775
File diff suppressed because it is too large.
Load diff
@@ -1487,6 +1487,11 @@ message Peer {
|
||||
Denotes that we are not receiving new graph updates from the peer.
|
||||
*/
|
||||
PASSIVE_SYNC = 2;
|
||||
|
||||
/*
|
||||
Denotes that this peer is pinned into an active sync.
|
||||
*/
|
||||
PINNED_SYNC = 3;
|
||||
}
|
||||
|
||||
// The type of sync we are currently performing with this peer.
|
||||
|
||||
@@ -2269,10 +2269,11 @@
|
||||
"enum": [
|
||||
"UNKNOWN_SYNC",
|
||||
"ACTIVE_SYNC",
|
||||
"PASSIVE_SYNC"
|
||||
"PASSIVE_SYNC",
|
||||
"PINNED_SYNC"
|
||||
],
|
||||
"default": "UNKNOWN_SYNC",
|
||||
"description": " - UNKNOWN_SYNC: Denotes that we cannot determine the peer's current sync type.\n - ACTIVE_SYNC: Denotes that we are actively receiving new graph updates from the peer.\n - PASSIVE_SYNC: Denotes that we are not receiving new graph updates from the peer."
|
||||
"description": " - UNKNOWN_SYNC: Denotes that we cannot determine the peer's current sync type.\n - ACTIVE_SYNC: Denotes that we are actively receiving new graph updates from the peer.\n - PASSIVE_SYNC: Denotes that we are not receiving new graph updates from the peer.\n - PINNED_SYNC: Denotes that this peer is pinned into an active sync."
|
||||
},
|
||||
"PendingChannelsResponseClosedChannel": {
|
||||
"type": "object",
|
||||
|
||||
@@ -2744,6 +2744,8 @@ func (r *rpcServer) ListPeers(ctx context.Context,
|
||||
lnrpcSyncType = lnrpc.Peer_ACTIVE_SYNC
|
||||
case discovery.PassiveSync:
|
||||
lnrpcSyncType = lnrpc.Peer_PASSIVE_SYNC
|
||||
case discovery.PinnedSync:
|
||||
lnrpcSyncType = lnrpc.Peer_PINNED_SYNC
|
||||
default:
|
||||
return nil, fmt.Errorf("unhandled sync type %v",
|
||||
syncType)
|
||||
|
||||
Reference in new issue
Block a user