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

Feature/bitcon core support #6

Open
wants to merge 33 commits into
base: main
Choose a base branch
from

Conversation

RiccardoBiffi
Copy link

Submission for the assignment 6 - Plan B Network Tech School.

General changes

  • added unsubscribe methods on Electrum provider
  • added Electrum provider tests
  • added Bitcoin Core provider
  • added Bitcoin Core provider tests
  • added a package dependency (ZeroMQ)
  • some updates on test-helpers

Choices

  • A new files has been added to .gitignore: package-lock.json, as of what we said on Telegram
  • The module now exports two distinct providers: ElectrumProvider and BitcoinCoreProvider.
  • Bitcoin Core provider subscriptions are managed with ZeroMQ
  • Only one ZeroMQ socket is used. All messages go through it with a different topic to distinct them.
  • The socket port is 28334. The standard one should be 28332, but the suggested bitcoin.conf file uses three different ports starting from 28334. I chose the first one.
  • The ZeroMQ socket emits different events depending on the topic. The Bitcoin Core provider listens to the events and their handler contains the logic. This way I can assure only one socket is opened and it is listened only by one process.
  • I changed the name of _getBalance() to getBalance() in both Electrum and Bitcoin Core providers, with the intention to signal it as a public method.
  • New test-config schema: the schema has been updated to reflect the presence of the new Bitcoin Core provider. It is now a dictionary with an entry for each provider and the needed properties.

@CLAassistant
Copy link

CLAassistant commented Dec 20, 2024

CLA assistant check
All committers have signed the CLA.

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.

2 participants