-
Notifications
You must be signed in to change notification settings - Fork 268
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
htlc post restart 4 #1586
htlc post restart 4 #1586
Conversation
- `cleanupRelayDb` accepts `htlcsIn: Seq[IncomingHtlc]` instead of `channels: Seq[HasCommitments]`. - `remoteOutgoingToLocalIncoming` method is extracted from `getIncomingHtlcs` (will be reused in HC plugin).
- `cleanupRelayDb` accepts `htlcsIn: Seq[IncomingHtlc]` instead of `channels: Seq[HasCommitments]` (to account for plugins). - `remoteOutgoingToLocalIncoming` method is extracted from `getIncomingHtlcs` (will be reused in HC plugin).
eclair-core/src/main/scala/fr/acinq/eclair/payment/relay/PostRestartHtlcCleaner.scala
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We're getting close, this time is the right one ;)
Have you been able to test that this correctly gives you the hooks you need for HC?
eclair-core/src/main/scala/fr/acinq/eclair/channel/Channel.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/Auditor.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/relay/PostRestartHtlcCleaner.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/relay/PostRestartHtlcCleaner.scala
Outdated
Show resolved
Hide resolved
@@ -540,7 +540,7 @@ class ApiServiceSpec extends AnyFunSuite with ScalatestRouteTest with IdiomaticM | |||
system.eventStream.publish(chcr) | |||
wsClient.expectMessage(expectedSerializedChcr) | |||
|
|||
val chsc = ChannelStateChanged(system.deadLetters, system.deadLetters, bobNodeId, OFFLINE, NORMAL, null) | |||
val chsc = ChannelStateChanged(system.deadLetters, null, system.deadLetters, bobNodeId, OFFLINE, NORMAL, null) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's nice is that now we'll be able to easily add the channelId
here! It's not your job to do it in this PR though, I'll do it in a follow-up one.
Yes, |
eclair-core/src/main/scala/fr/acinq/eclair/channel/Channel.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/channel/ChannelTypes.scala
Outdated
Show resolved
Hide resolved
eclair-node-gui/src/main/scala/fr/acinq/eclair/gui/GUIUpdater.scala
Outdated
Show resolved
Hide resolved
eclair-node-gui/src/main/scala/fr/acinq/eclair/gui/GUIUpdater.scala
Outdated
Show resolved
Hide resolved
Codecov Report
@@ Coverage Diff @@
## master #1586 +/- ##
==========================================
+ Coverage 87.25% 87.33% +0.08%
==========================================
Files 145 146 +1
Lines 11056 11056
Branches 479 471 -8
==========================================
+ Hits 9647 9656 +9
+ Misses 1409 1400 -9
|
eclair-core/src/test/scala/fr/acinq/eclair/payment/PostRestartHtlcCleanerSpec.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/test/scala/fr/acinq/eclair/payment/PostRestartHtlcCleanerSpec.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/test/scala/fr/acinq/eclair/payment/PostRestartHtlcCleanerSpec.scala
Show resolved
Hide resolved
eclair-core/src/test/scala/fr/acinq/eclair/payment/PostRestartHtlcCleanerSpec.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/test/scala/fr/acinq/eclair/payment/PostRestartHtlcCleanerSpec.scala
Show resolved
Hide resolved
eclair-core/src/test/scala/fr/acinq/eclair/payment/PostRestartHtlcCleanerSpec.scala
Outdated
Show resolved
Hide resolved
Codecov ReportAttention: Patch coverage is
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #1586 +/- ##
==========================================
+ Coverage 87.25% 87.33% +0.08%
==========================================
Files 145 146 +1
Lines 11056 11056
Branches 479 471 -8
==========================================
+ Hits 9647 9656 +9
+ Misses 1409 1400 -9
|
This is continuation of #1580 (rather than wrestling with git I've decided to send a new PR). It follows suggestions outlined in 9d63b94.