Host your Streamr Broker Node via the Flux Marketplace!

Flux Official
7 min readFeb 22, 2023

Flux — The Web3 Cloud

Flux’s core values and ethos center around the rise of Web 3.0 — By and For the People. It aims to evoke the power of corporations and restore it to the common people. The Flux Cloud is decentralized, based on thousands of single servers from all over the world connected in one operating system. Individuals are the backbone of technology. They provide the cloud with computational resources via home-based bare metal machines or rented servers and are incentivized by 50% of the total block reward.

To this date, the decentralized cloud of Flux is supported by over 15,000 nodes around the globe. Its available computational resources are over 110,000 Cores, over 300 TB of RAM, and 7 PT (Petabytes) SSD. It is a Web 3.0 cloud powerhouse that can be used to deploy applications in a decentralized and censor-resistant manner. There are plenty of advantages to using Flux instead of traditional Web2 infrastructure providers:

  • All applications are redundant and have automatic failovers in case of any outages.
  • The Flux Cloud is agnostic to code language as it uses Docker Hub containers as an on-ramp.
  • The Flux Cloud automatically keeps applications up to date with the respective container.
  • The Flux Cloud offers competitive pricing.

Streamr — Connecting Web3 with real-time data

Streamr is building the real-time data protocol of the decentralized web. This includes a scalable, low-latency, and secure P2P Network for data delivery and exchange. As part of the vision, Streamr is working on a decentralized chat application, data marketplace, and other dApps. Real-time data veterans started the project with algorithmic trading and financial market backgrounds. Streamr is being built by contributors worldwide and was crowdfunded via ICO with $30M in October 2017.

Enough introduction! Let us go ahead with the guide on deploying your Streamr Broker Node via the Flux Marketplace in very few steps!

Before deploying a Streamr Broker Node, you need data tokens stored on a Polygon Address. This address will act as your Beneficiary Address with your staked DATA tokens. Nothing sensitive will be stored in the Docker Hub Container or the FluxNodes running your nodes.

Broker nodes subscribe to selected incentivized streams and help propagate the messages in those streams, essentially contributing bandwidth to the stream in exchange for earning DATA tokens. The mining process and associated token economics are described at a high level on the DATA token page on the project website and in the Tokenomics section of their official docs.

Earned rewards will be automatically sent to the Beneficiary address, are proportional to the amount you stake, and compounded (up to the 20,000 DATA cap). The estimated payout date is the first business day of each month.

Once you have a Beneficiary Address with staked DATA tokens ready, we can proceed with the Flux Cloud deployment process.

  1. We first need to head over to https://home.runonflux.io/
  2. Once here, we need to log in using our ZelID. Available for us via Zelcore https://zelcore.io/ (Remember always to use the official links)

2.1 If you do not have an account created in Zelcore, you first need to download and install the app

2.2 Next (mandatory for your wallet’s safety), enable d2FA on the App section inside Zelcore.

2.3 Now you can authenticate by clicking on the fingerprint button or manually by signing the message manually on your Zelcore Wallet with the ZelID App

3. Now that you have been authenticated, head to https://home.runonflux.io/apps/marketplace and look for the Streamr Application — You will find it under the ‘Crypto’ category. You will see something remarkably like this:

4. Add your Beneficiary Address to your Streamr Broker Node via an Environment (ENV). The ENV for this purpose is called STREAMR__BROKER__PLUGINS__BRUBECK_MINER__BENEFICIARY_ADDRESS. Simply enter your address in the field provided and click “Start Launching Marketplace App.”

5. Next, you will see a screen like this:

6. You can click “Next” or copy the Registration Message to sign the message manually using your ZelID App, then click “Next.”

7. Here, you can click the fingerprint button to sign the request for the application. If you have done this manually, paste the signed message from the earlier step onto your ZelID.

8. You will now see the monthly cost for your application. Click on “Register Flux App.”

9. You will be given payment information in FLUX. Payment is made through the FLUX blockchain using FLUX coins.

10. Select “Pay with Zelcore” to make the payment for the application.

11. You’re done! We now need to wait for your Broker Node to be spawned on an available node, which usually takes 10–30 minutes.

Usage of the Broker Node

When you’re logged in with your ZelID at https://home.runonflux.io, go to the “Global Apps” menu tab on the left-hand side. From there, go to the “My Apps” tab to manage and visit your Broker Node deployments. Click on the arrow pointing down to see your application specifications and the IPs running it.

As you can see, your Broker Node is redundant, which means it is always running on at least three instances simultaneously. They all send their rewards to the same Beneficiary Address you provided for their contribution. You can check the logs of the individual IPs to ensure that the Node is working properly.

  1. Visit one IP by clicking on “Visit FluxNode.”
  2. Log in with your ZelID
  3. Navigate to “Apps,” “Local Apps,” “My Local Apps”
  4. Click “Manage,” “Manage App,” “Log File”

You should see something similar like this:

a[32mINFO[39m [2023–02–19T14:10:26.320] (WebRtcEndpoint ): [36mConnected to 11 peers[39m
[32mINFO[39m [2023–02–19T14:13:10.493] (BrubeckMinerPlugin ): [36mReward code received: d099b8a0–1f7c-4fcb-9592–94656df0f1ab[39m
[31mERROR[39m [2023–02–19T14:14:47.899] (BrubeckMinerPlugin ): [36mUnable to claim reward: code=d099b8a0–1f7c-4fcb-9592–94656df0f1ab[39m
err: {
“type”: “Error”,
i “message”: “request to
http://brubeck1.streamr.network:3011/claim failed, response: 409 Conflict”,
“stack”:
f Error: request to
http://brubeck1.streamr.network:3011/claim failed, response: 409 Conflict
m at fetchOrThrow (/home/streamr/network/packages/broker/dist/src/helpers/fetchOrThrow.js:18:15)
\ at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async BrubeckMinerPlugin.claimRewardCode (/home/streamr/network/packages/broker/dist/src/plugins/brubeckMiner/BrubeckMinerPlugin.js:104:25)
at async BrubeckMinerPlugin.onRewardCodeReceived (/home/streamr/network/packages/broker/dist/src/plugins/brubeckMiner/BrubeckMinerPlugin.js:52:9)
}

Do not mind the error message that you’ll see. This error happens when a node attempts to claim a reward more than once for an address. This happens because multiple miners have been configured with your Beneficiary Address! You can easily check your currently earned rewards with the officially provided Dashboards and APIs.

Use the community-built BrubeckScan dashboard for checking earnings and other mining and staking statistics.

To see the rewards a Broker node has accumulated, use the following API endpoint:

https://brubeck1.streamr.network:3013/datarewards/:nodeAddress

Put your Beneficiary Address for nodeAddress!

Example response:
{
"DATA": 2.1341
}

Accumulated rewards for a node address

Endpoint: https://brubeck1.streamr.network:3013/datarewards/:nodeAddress

Remember, your Broker Node is only initially subscribed for 22,000 Flux blocks, which is ~ 44,000 minutes (about one month). You must renew the payment after the first month so your broker is not kicked off the network. We give you a choice to renew it for a longer term after the first deployment for up to one year.

  1. Visit https://home.runonflux.io/ and log in with your ZelID
  2. Navigate to “Apps,” “Global Apps,” “My Apps”
  3. Click “Manage,” “Manage App,” or “Update Specifications”
  4. Leave all the variables like they are, except the PERIOD field — Adjust it to your preference. Next, click on “Compute Update Message.”
  5. Sign the Message with the ZelID App and click “Update Flux App” after
  6. Click “Pay with Zelcore” to make the Flux Payment.
  7. Voilà your Node has been renewed for your chosen duration

Have Fun supporting Streamr with decentralized infrastructure!

Learn more about Flux at www.runonflux.io
Learn more about Streamr at https://streamr.network/

--

--