Browse Source

options: remove unused 'commit-fee-min/max' options.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
travis-experimental
Rusty Russell 4 years ago
committed by Christian Decker
parent
commit
4ba9ad66bc
  1. 10
      doc/lightningd-config.5
  2. 7
      doc/lightningd-config.5.md
  3. 6
      lightningd/lightningd.h
  4. 21
      lightningd/options.c

10
doc/lightningd-config.5

@ -343,14 +343,6 @@ The percentage of \fIestimatesmartfee 2/CONSERVATIVE\fR to use for the commitmen
transactions: default is 100\.
\fBcommit-fee-min\fR=\fIPERCENT\fR
\fBcommit-fee-max\fR=\fIPERCENT\fR
Limits on what onchain fee range we’ll allow when a node opens a channel
with us, as a percentage of \fIestimatesmartfee 2\fR\. If they’re outside
this range, we abort their opening attempt\. Note that \fBcommit-fee-max\fR
can (should!) be greater than 100\.
\fBmax-concurrent-htlcs\fR=\fIINTEGER\fR
Number of HTLCs one channel can handle concurrently in each direction\.
Should be between 1 and 483 (default 30)\.
@ -589,4 +581,4 @@ Main web site: \fIhttps://github.com/ElementsProject/lightning\fR
Note: the modules in the ccan/ directory have their own licenses, but
the rest of the code is covered by the BSD-style MIT license\.
\" SHA256STAMP:8e80667950a40a059a3a320a095c2313bc99b00de06bb892c47f22cf458d6493
\" SHA256STAMP:9d72136e5abae6cb8f36899ebaeed6644ea566e95ec1a6f8b13cc911ed64a294

7
doc/lightningd-config.5.md

@ -280,13 +280,6 @@ opens a channel before the channel is usable.
The percentage of *estimatesmartfee 2/CONSERVATIVE* to use for the commitment
transactions: default is 100.
**commit-fee-min**=*PERCENT*
**commit-fee-max**=*PERCENT*
Limits on what onchain fee range we’ll allow when a node opens a channel
with us, as a percentage of *estimatesmartfee 2*. If they’re outside
this range, we abort their opening attempt. Note that **commit-fee-max**
can (should!) be greater than 100.
**max-concurrent-htlcs**=*INTEGER*
Number of HTLCs one channel can handle concurrently in each direction.
Should be between 1 and 483 (default 30).

6
lightningd/lightningd.h

@ -26,12 +26,6 @@ struct config {
/* How many confirms until we consider an anchor "settled". */
u32 anchor_confirms;
/* Maximum percent of fee rate we'll accept. */
u32 commitment_fee_max_percent;
/* Minimum percent of fee rate we'll accept. */
u32 commitment_fee_min_percent;
/* Minimum CLTV to subtract from incoming HTLCs to outgoing */
u32 cltv_expiry_delta;

21
lightningd/options.c

@ -610,10 +610,6 @@ static const struct config testnet_config = {
/* We're fairly trusting, under normal circumstances. */
.anchor_confirms = 1,
/* Testnet fees are crazy, allow infinite feerange. */
.commitment_fee_min_percent = 0,
.commitment_fee_max_percent = 0,
/* Testnet blockspace is free. */
.max_concurrent_htlcs = 483,
@ -658,10 +654,6 @@ static const struct config mainnet_config = {
/* We're fairly trusting, under normal circumstances. */
.anchor_confirms = 3,
/* Insist between 2 and 20 times the 2-block fee. */
.commitment_fee_min_percent = 200,
.commitment_fee_max_percent = 2000,
/* While up to 483 htlcs are possible we do 30 by default (as eclair does) to save blockspace */
.max_concurrent_htlcs = 30,
@ -707,13 +699,6 @@ static const struct config mainnet_config = {
static void check_config(struct lightningd *ld)
{
/* We do this by ensuring it's less than the minimum we would accept. */
if (ld->config.commitment_fee_max_percent != 0
&& ld->config.commitment_fee_max_percent
< ld->config.commitment_fee_min_percent)
fatal("Commitment fee invalid min-max %u-%u",
ld->config.commitment_fee_min_percent,
ld->config.commitment_fee_max_percent);
/* BOLT #2:
*
* The receiving node MUST fail the channel if:
@ -861,12 +846,6 @@ static void register_opts(struct lightningd *ld)
opt_register_arg("--funding-confirms", opt_set_u32, opt_show_u32,
&ld->config.anchor_confirms,
"Confirmations required for funding transaction");
opt_register_arg("--commit-fee-min=<percent>", opt_set_u32, opt_show_u32,
&ld->config.commitment_fee_min_percent,
"Minimum percentage of fee to accept for commitment");
opt_register_arg("--commit-fee-max=<percent>", opt_set_u32, opt_show_u32,
&ld->config.commitment_fee_max_percent,
"Maximum percentage of fee to accept for commitment (0 for unlimited)");
opt_register_arg("--cltv-delta", opt_set_u32, opt_show_u32,
&ld->config.cltv_expiry_delta,
"Number of blocks for cltv_expiry_delta");

Loading…
Cancel
Save