-
Notifications
You must be signed in to change notification settings - Fork 94
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
active/passive modes for parent coins #1763
Conversation
Signed-off-by: ozkanonur <work@onurozkan.dev>
6b6c4ed
to
ffdec19
Compare
Signed-off-by: ozkanonur <work@onurozkan.dev>
ffdec19
to
d84eb7f
Compare
Signed-off-by: ozkanonur <work@onurozkan.dev>
2daaeb8
to
f827e98
Compare
Signed-off-by: ozkanonur <work@onurozkan.dev>
Signed-off-by: ozkanonur <work@onurozkan.dev>
Signed-off-by: ozkanonur <work@onurozkan.dev>
Signed-off-by: ozkanonur <work@onurozkan.dev>
Signed-off-by: ozkanonur <work@onurozkan.dev>
aefca72
to
b8ed77c
Compare
Signed-off-by: ozkanonur <work@onurozkan.dev>
b8ed77c
to
57be79e
Compare
I ran a few tests using the web GUI, and everything is working smoothly so far without any changes on our side. Thanks, @ozkanonur ! |
Signed-off-by: ozkanonur <work@onurozkan.dev>
560fa43
to
a4ffaa0
Compare
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.
Thanks a lot for the fix!
This is a first review iteration since I will resume reviewing the rest of the changes after getting your opinion @ozkanonur on my third comment.
Signed-off-by: ozkanonur <work@onurozkan.dev>
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.
LGTM! only one non-blocker :)
Signed-off-by: ozkanonur <work@onurozkan.dev>
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.
Great work!
Signed-off-by: ozkanonur <work@onurozkan.dev>
Signed-off-by: ozkanonur <work@onurozkan.dev>
@caglaryucekaya did you approve this PR, or are you doing another review? |
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.
LGTM 🔥
This PR brings active/passive modes for parent coins which aims to keep children token states in memory when
disable_coin
is executed for parent coin.Progress:
is_available
atomic flag,is_available
andupdate_is_available
to coins context.is_available
andupdate_is_available
on certain conditions around coin activations anddisable_coin
.is_available
totrue
on re-activation.implementaddforce_disable_all
RPC to drop everything on target coin.force_disable
flag todisable_coin
RPCmm2_test_helpers::for_tests::disable_coin_err
passivized
flag ondisable_coin
RPC responseBreaking Changes:
dependent_tokens
is removed from the RPC response. Because we no longer care about if there are active tokens or not.--
Docs for GUI:
cc @yurii-khi @KomodoPlatform/qa
new param
force_disable: bool(false as default)
fordisable_coin
RPC request payloadtrue
, if platform has tokens enabled,disable_coin
will passive the platform coin with keeping all the tokens active and usable. Whenforce_disable
istrue
, no matter if platform passive, or active, it will be disabled with all it's tokens.new field
passivized
ondisable_coin
RPC responseforce_disable
passivized coins to disable all tokens and drop swaps which is faster in terms of UX)When passive coin is re-activated, it only changes it's passive status(and activates the tokens if enabled with tokens) without updating the other fields like rpc urls, tx history, etc. If these fields needs to be changed, the coin must be disabled with
force_disable
flag which cleans up the memory from that platform.--
Resolves #1641