Skip to content

Commit

Permalink
lnrpc: add dns_hostname_address field
Browse files Browse the repository at this point in the history
  • Loading branch information
mohamedawnallah committed Feb 3, 2025
1 parent 6bf895a commit fcdd9bc
Show file tree
Hide file tree
Showing 8 changed files with 1,844 additions and 1,790 deletions.
9 changes: 9 additions & 0 deletions cmd/commands/peersrpc_active.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,10 @@ var updateNodeAnnouncementCommand = cli.Command{
Name: "color",
Usage: "the new color for this node, e.g. #c42a81",
},
cli.StringFlag{
Name: "dns_hostname_address",
Usage: "the new dns hostname address for this node",
},
cli.Int64SliceFlag{
Name: "feature_bit_add",
Usage: "a feature bit index that needs to be enabled. " +
Expand Down Expand Up @@ -124,6 +128,11 @@ func updateNodeAnnouncement(ctx *cli.Context) error {
req.Color = ctx.String("color")
}

if ctx.IsSet("dns_hostname_address") {
change = true
req.DnsHostnameAddress = ctx.String("dns_hostname_address")
}

if ctx.IsSet("feature_bit_add") {
change = true
for _, feature := range ctx.Int64Slice("feature_bit_add") {
Expand Down
4 changes: 4 additions & 0 deletions lnrpc/devrpc/dev.swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,10 @@
"format": "byte"
},
"description": "Custom node announcement tlv records."
},
"dns_hostname_address": {
"$ref": "#/definitions/lnrpcNodeAddress",
"description": "The DNS hostname address of the node, if available."
}
},
"description": "An individual vertex/node within the channel graph. A node is\nconnected to other nodes by one or more channel edges emanating from it. As the\ngraph is directed, a node will also have an incoming edge attached to it for\neach outgoing edge."
Expand Down
3,543 changes: 1,779 additions & 1,764 deletions lnrpc/lightning.pb.go

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions lnrpc/lightning.proto
Original file line number Diff line number Diff line change
Expand Up @@ -3437,6 +3437,9 @@ message LightningNode {

// Custom node announcement tlv records.
map<uint64, bytes> custom_records = 7;

// The DNS hostname address of the node, if available.
NodeAddress dns_hostname_address = 8;
}

message NodeAddress {
Expand Down
4 changes: 4 additions & 0 deletions lnrpc/lightning.swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -5799,6 +5799,10 @@
"format": "byte"
},
"description": "Custom node announcement tlv records."
},
"dns_hostname_address": {
"$ref": "#/definitions/lnrpcNodeAddress",
"description": "The DNS hostname address of the node, if available."
}
},
"description": "An individual vertex/node within the channel graph. A node is\nconnected to other nodes by one or more channel edges emanating from it. As the\ngraph is directed, a node will also have an incoming edge attached to it for\neach outgoing edge."
Expand Down
64 changes: 38 additions & 26 deletions lnrpc/peersrpc/peers.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions lnrpc/peersrpc/peers.proto
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,9 @@ message NodeAnnouncementUpdateRequest {

// Set of changes for the node's known addresses.
repeated UpdateAddressAction address_updates = 4;

// The DNS hostname address of the node.
string dns_hostname_address = 5;
}

message NodeAnnouncementUpdateResponse {
Expand Down
4 changes: 4 additions & 0 deletions lnrpc/peersrpc/peers.swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,10 @@
"$ref": "#/definitions/peersrpcUpdateAddressAction"
},
"description": "Set of changes for the node's known addresses."
},
"dns_hostname_address": {
"type": "string",
"description": "The DNS hostname address of the node."
}
}
},
Expand Down

0 comments on commit fcdd9bc

Please sign in to comment.