core-lightning/plugins
Lagrang3 b0054aad46 renepay: accomodate fees in the payment flow
Min. Cost Flow does not take into account fees when computing a flow
    with liquidity constraints.
    This is a work-around solution that reduces the amount on every route to
    respect the liquidity bound. The deficity in the delivered amount is
    solved by running MCF once again.

    Changes:

    1. the function `flow_complete` allocates amounts to send over the set of routes
       computed by the MCF algorithm, but it does not allocate more than liquidity
       bound of the route. For this reason `minflow` returns a set of routes that
       satisfy the liquidity bounds but it is not guaranteed that the total payment
       reaches the destination therefore there could a deficit in the delivery:
       `deficit = amount_to_deliver - delivering`.

    2. in the function `add_payflows` after `minflow` returns a set of routes we
       call `flows_fit_amount` that tries to a allocate the `deficit` in the routes
       that the MCF have computed.

    3. if the resulting flows pass all payment constraints then we update
        `amount_to_deliver = amount_to_deliver - delivering`, and the loop
        repeats as long as `amount_to_deliver` is not zero.

    In other words, the excess amount, beyond the liquidity bound,
    in the routes is removed and then we try to allocate it
    into known routes, otherwise we do a whole MCF again just for the
    remaining amount.

    Fixes issue #6599
2024-01-29 10:48:24 +10:30
..
bkpr bkpr: now that we're not doing empty acct logging, we dont need this bool 2024-01-29 10:05:03 +10:30
clnrest clnrest: Import sys in except clause explicitly 2023-11-21 08:24:09 +01:00
examples cln-plugin: Add test for cln-plugin send_custom_notification 2023-10-30 18:24:23 +01:00
grpc-plugin grpc: Add metadata to Cargo.toml 2023-12-15 10:01:57 +10:30
renepay renepay: accomodate fees in the payment flow 2024-01-29 10:48:24 +10:30
spender dual-fund: don't re-notify plugin on arrival of sigs (2nd time) 2023-11-02 19:32:05 +10:30
src rs: Temporarily remove a test that is failing due to log changes 2024-01-17 20:55:03 +01:00
test plugins/pay: use gossmods_from_listpeerchannels instead of private gossip_store records. 2023-12-14 09:16:56 +10:30
.gitignore meta: ignore renepay binary 2023-08-21 10:35:41 +09:30
autoclean.c libplugin: support version strings for deprecations. 2024-01-26 10:30:22 +10:30
bcli.c plugins/bcli: use per-command deprecation flags. 2024-01-26 10:30:22 +10:30
Cargo.toml cln-plugin: Switch from env_logger to tracing-subscriber 2024-01-16 18:36:12 +01:00
chanbackup.c chanbackup: even if they enable experimental-peer-storage, check peers 2023-03-08 18:46:21 -06:00
commando.c commando: use deprecation API for missing ids. 2024-01-26 10:30:22 +10:30
fetchinvoice.c lightningd: remove msatoshi alias for amount_msat. 2024-01-26 10:30:22 +10:30
funder.c funder: remove lease-fee-base-msat 2024-01-26 10:30:22 +10:30
funder_policy.c libplugin: make set callback for options take plugin ptr, check correct type. 2023-06-20 20:08:25 +09:30
funder_policy.h libplugin: make set callback for options take plugin ptr, check correct type. 2023-06-20 20:08:25 +09:30
keysend.c lightningd: remove msatoshi alias for amount_msat. 2024-01-26 10:30:22 +10:30
libplugin-pay.c plugins/pay: use gossmods_from_listpeerchannels instead of private gossip_store records. 2023-12-14 09:16:56 +10:30
libplugin-pay.h plugins/pay: use gossmods_from_listpeerchannels instead of private gossip_store records. 2023-12-14 09:16:56 +10:30
libplugin.c libplugin: remove global deprecated_apis flag. 2024-01-26 10:30:22 +10:30
libplugin.h libplugin: remove global deprecated_apis flag. 2024-01-26 10:30:22 +10:30
Makefile schemas: deprecated is now a range. 2024-01-26 10:30:22 +10:30
offers.c plugins/offers: Extend the capability of decode to decrypt the contents of emergency.recover file. 2023-10-27 16:05:28 +10:30
offers.h common: update to latest onion message spec. 2022-10-26 11:29:06 +10:30
offers_inv_hook.c lightningd: re-add 'offerout' functionality, as 'invoicerequest'. 2022-11-09 15:08:03 +01:00
offers_inv_hook.h lightningd: re-add 'offerout' functionality, as 'invoicerequest'. 2022-11-09 15:08:03 +01:00
offers_invreq_hook.c offers: fix pay where we are using deprecated apis. 2023-02-03 16:59:51 +01:00
offers_invreq_hook.h offers: create a real blinded path, if necessary. 2022-11-09 15:08:03 +01:00
offers_offer.c offers: enable label for invoicerequest 2023-03-09 06:56:06 -06:00
offers_offer.h lightningd: re-add 'offerout' functionality, as 'invoicerequest'. 2022-11-09 15:08:03 +01:00
pay.c lightningd: remove msatoshi alias for amount_msat. 2024-01-26 10:30:22 +10:30
README.md doc: fix wording in plugins/README.md 2020-01-06 12:57:59 +01:00
sql.c plugins/sql: use per-command deprecations. 2024-01-26 10:30:22 +10:30
topology.c plugins/bcli: use per-command deprecation flags. 2024-01-26 10:30:22 +10:30
txprepare.c plugins: remove #if DEVELOPER. 2023-09-21 20:08:24 +09:30

Plugin Directory

Any file in this directory which is executable and whose name only consists of alphanumeric characters, space, '.', '-' or '_' will be automatically loaded when lightningd starts (unless suppressed with commandline options).