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

Refactor http client #4942

Merged
merged 21 commits into from
Dec 14, 2020
Merged

Conversation

chimp1984
Copy link
Contributor

Refactors and fixes HttpClient

Add support for POST (Needed for follow up PR)
Do not allow multiple requests before one request is completed
Use different httpClients for getFee and getPrice

Use HttpMethod as param
Add getHttpUriRequest method
while hasPendingRequest is true
- Throw exception if we get a request before previous request is
terminated (happens with priceFee at startup, on regtest as
startup is fast, but can happen also on mainnet)
- Improve shutDown
- Improve finally clause
We used the same HttpClient for fee and price requests, which cause
problems when one request got completed and closed the connection
at finalize.
Copy link
Contributor

@ripcurlx ripcurlx left a comment

Choose a reason for hiding this comment

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

ACK

Code looks fine and I'm still receiving correct prices from pricenodes when running on Mainnet.

@ripcurlx ripcurlx merged commit 2bad7fc into bisq-network:master Dec 14, 2020
@ripcurlx ripcurlx added this to the v1.5.2 milestone Dec 14, 2020
@sqrrm
Copy link
Member

sqrrm commented Dec 14, 2020

utACK

I thumbs up for the well scoped commits.

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.

3 participants