What is Nostr?
Johan TorĂĄs Halseth [ARCHIVE] /
npub1ppn…s2fw
2023-06-09 12:47:54

Johan TorĂĄs Halseth [ARCHIVE] on Nostr: đź“… Original date posted:2017-12-07 đź“ť Original message: Hi, Edward! Welcome to ...

đź“… Original date posted:2017-12-07
đź“ť Original message:
Hi, Edward! Welcome to the mailing list :)
The fees can indeed be set for each direction of the channel, check out https://github.com/lightningnetwork/lightning-rfc/blob/master/07-routing-gossip.md#the-channel_update-message [https://github.com/lightningnetwork/lightning-rfc/blob/master/07-routing-gossip.md#the-channel_update-message]
Basically each node in the channel can announce the fee til will take to route a payment in the direction leading “away” from it. We also have something called “channel reserves” ensuring that each node always has some balance at stake in case an old state is broadcast.
Cheers! Johan

On Wed, Dec 6, 2017 at 12:04, Edziu Marynarz <edziumarynarz at gmail.com> wrote:
I tried to find this information in the BOLT documents but I couldn't find it. Is it possible to set up the channel so that the fee depends on the direction, i.e. a different fee on the receive direction and different on the send one? Why such functionality?
Imagine that you start with a bidirectional channel to Alice and a channel to Bob with 1000 satoshi each. For some reasons, the network routes most of the transactions from Alice to you and then to Bob and you end up with 1900 satoshi in the Alice channel and only 100 satoshi in the Bob one. The route will stop working and if there is little traffic in the other direction you will have to close the channels to rebalance them or wait a very long time for the rebalancing.
If the fee could depend on the direction, one could start to ramp up fees on the receiving end of the channel that is getting large and lower the one that is empty to prevent the imbalance.
There is also a risk factor involved. The lightning network channels get riskier on the receive side the more the channel value deviates from the original state since the counterparty may try to broadcast the old state so you may want to regulate this imbalance with fees. It would be best if the LN applications could do it automatically.
Regards,
Edward
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxfoundation.org/pipermail/lightning-dev/attachments/20171207/df6d2847/attachment.html>;
Author Public Key
npub1ppn2nhlfdzkw9gw0ytljpef5dpyzsxzw8ffcyykamt32hw6pge0smhs2fw