Skip to content

[NET-1638] implement findProxyNodes in sdk#3257

Merged
hpihkala merged 11 commits intomainfrom
net-1638-implement-findproxynodes-in-sdk
Dec 5, 2025
Merged

[NET-1638] implement findProxyNodes in sdk#3257
hpihkala merged 11 commits intomainfrom
net-1638-implement-findproxynodes-in-sdk

Conversation

@hpihkala
Copy link
Copy Markdown
Contributor

@hpihkala hpihkala commented Dec 4, 2025

Summary

See below bugbot summary.

Checklist before requesting a review

  • Is this a breaking change? If it is, be clear in summary.
  • Read through code myself one more time.
  • Make sure any and all TODO comments left behind are meant to be left in.
  • Has reasonable passing test coverage?
  • Updated changelog if applicable.
  • Updated documentation if applicable.

Note

Introduce StreamrClient#findProxyNodes using a new ProxyNodeFinder, update OperatorRegistry#findOperatorsOnStream to return operator IDs with peer descriptors, add tests, and remove internal findOperators.

  • SDK (@streamr/sdk)
    • New:
      • ProxyNodeFinder: discovers proxy nodes from operators with parallelized search.
      • StreamrClient#findProxyNodes(streamDefinition, numberOfProxies, maxQueryResults, maxHeartbeatAgeHours) delegates to ProxyNodeFinder.
    • OperatorRegistry API:
      • findOperatorsOnStream() now returns { operatorId, peerDescriptor } instead of peer descriptors only.
    • Removed:
      • Internal StreamrClient#findOperators.
    • Tests:
      • Add ProxyNodeFinder unit tests and update FakeOperatorRegistry to new return type.
    • Docs:
      • Update CHANGELOG.md reflecting additions and removal.

Written by Cursor Bugbot for commit 94ab819. This will update automatically on new commits. Configure here.

@linear
Copy link
Copy Markdown

linear Bot commented Dec 4, 2025

@github-actions github-actions Bot added the sdk label Dec 4, 2025
@github-actions github-actions Bot added the docs label Dec 4, 2025
Comment thread packages/sdk/deleteme.ts Outdated
@hpihkala hpihkala requested a review from juslesan December 4, 2025 15:07
Copy link
Copy Markdown
Contributor

@juslesan juslesan left a comment

Choose a reason for hiding this comment

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

Looks OK, a couple of minor comments.

As a heads up we might not support "bidirectional" proxies, meaning that proxies are only able to publish or subscribe to messages on the network level. For the StreamrTV use case we might need to add support for bidirectionality as the viewers need to be able to listen to messages and to send out heartbeats

Comment thread CHANGELOG.md Outdated
Comment thread packages/sdk/src/StreamrClient.ts
@hpihkala
Copy link
Copy Markdown
Contributor Author

hpihkala commented Dec 4, 2025

As a heads up we might not support "bidirectional" proxies

Ah, damn, that complicates things! We will definitely need bidirectionality. I created a ticket and assigned it to you :)

@hpihkala hpihkala marked this pull request as ready for review December 5, 2025 15:14
@hpihkala hpihkala requested a review from juslesan December 5, 2025 15:14
@hpihkala hpihkala merged commit e445fd1 into main Dec 5, 2025
43 of 44 checks passed
@hpihkala hpihkala deleted the net-1638-implement-findproxynodes-in-sdk branch December 5, 2025 15:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants