Skip to content
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

Improve bisq setup #4592

Merged
merged 3 commits into from Oct 7, 2020
Merged

Improve bisq setup #4592

merged 3 commits into from Oct 7, 2020

Conversation

chimp1984
Copy link
Contributor

@chimp1984 chimp1984 commented Oct 3, 2020

Provides a new AppStartupState class for listening for combined startup states.
Extract domain startup code to a new class to avoid that BisqSetup gets overloaded.

We often need to wait until network and wallet is ready or other combination of startup states.
To avoid those repeated checks for the state or setting of listeners on different domains we provide here a
collection of useful states.

I did not use listeners as we want to query the state as well, so we needed fields keeping the state. Using a BooleanProperty provides both a field for keeping the state as well as a convenient way to add a listener.
E.g.:

appStartupState.walletAndNetworkReadyProperty().addListener((observable, oldValue, newValue) -> {
            if (newValue) {
                ....
            }
        });

@chimp1984
Copy link
Contributor Author

chimp1984 commented Oct 3, 2020

Codacy does not read comments :-). There is a reason to not make that field local. Please ignore stupid codacy bot.

@ghubstan
Copy link
Member

ghubstan commented Oct 3, 2020

Note to @ghubstan : delete bisq.core.api.StatusCheck after this is merged, use AppStartupState instead.

@chimp1984
Copy link
Contributor Author

Rebased on master.

@sqrrm
Copy link
Member

sqrrm commented Oct 6, 2020

I'm ready to merge this but will wait for #4568 to get merged first.

@ripcurlx
Copy link
Member

ripcurlx commented Oct 7, 2020

I removed the Codacy pattern based on the comment next to the variable. @chimp1984 Please force push to re-trigger Codacy checks. Thanks!

Copy link
Member

@sqrrm sqrrm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK

After decision to merge segwit changes directly into release branch, this can now be merged.

@sqrrm sqrrm merged commit 723a1f5 into bisq-network:master Oct 7, 2020
@chimp1984 chimp1984 deleted the improve-bisq-setup branch October 7, 2020 14:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants