clboss
clboss copied to clipboard
clboss-withdraw?
If I want to pull some funds out of my node, I currently turn off clboss, close a channel at random, and withdraw. It'd be nice if clboss figured out how to get enough onchain funds to make the payment for me, instead.
I would second this feature, as I have to do the same procedure :)
Suggest clboss-withdraw be a wrapper around the submarine swap with user supplied address and amount.
Cons
- using a third party so is unreliable, and subject to their amount restrictions
Pros
- Withdraw creates remote channel capacity
- Good for privacy, doesn't expose your lightning node or balance on chain
You can use clboss-ignore-onchain
then close channels and withdraw, without disabling clboss, that is the intent of that command after all, to ignore onchain funds temporarily. This still requires multiple commands as well as waiting.
@AutonomousOrganization has good idea I think. Though it would require some restructuring of the code.
- the onchain-funds-announcer should use a different new message for announcing onchain funds.
- move the ignore-onchain mechanism to a new module that accepts the "raw" onchain funds announce and emits the "pickled" onchain funds announce (i.e. the current message).
- Make the new module a swapper.
- When a
clboss-withdraw
command is received, put it in the db as a set of payments to make. Then trigger a swap of the value. - If the raw onchain funds announcement is received, check if we have pending payments that can now be fulfilled, and withdraw if so (possibly with some heuristics to hold off for future swaps if there are still other pending payments as well, to automatically merge multiple withdraws). Otherwise check for ignore-onchain timeout and if not ignore-onchain, announce the "pickled" onchain funds announcement (which will trigger the channel creator).