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

Deprecated Get connections from ConnectionManager #8003

Closed
pc3b3r opened this issue Aug 2, 2021 · 2 comments · Fixed by #8004
Closed

Deprecated Get connections from ConnectionManager #8003

pc3b3r opened this issue Aug 2, 2021 · 2 comments · Fixed by #8004

Comments

@pc3b3r
Copy link
Contributor

pc3b3r commented Aug 2, 2021

Issue Description

Related to #7839. It's deprecating get connections without a specific reason.

We are creating multiple connections at runtime and after a while we must iterate over all connections, without having a reference to all of them so it's really needed.

As a plus Object.values(<Map>) returns always an empty array

return Array.from(Object.values(this.connectionMap));

Expected Behavior

ConnectionManager.connections should return the list of active connections

Actual Behavior

Returns an empty array

Steps to Reproduce

await createConnections(connections)
console.log(getConnectionManager().connections)

Are you willing to resolve this issue by submitting a Pull Request?

  • ✅ Yes, I have the time, and I know how to start.
  • ✖️ Yes, I have the time, but I don't know how to start. I would need guidance.
  • ✖️ No, I don’t have the time, but I can support (using donations) development.
  • ✖️ No, I don’t have the time and I’m okay to wait for the community / maintainers to resolve this issue.
@imnotjames
Copy link
Contributor

imnotjames commented Aug 3, 2021

The entirety of the connection manager is deprecated. As such, having a location where there's a central repository of connections in a list is deprecated.

I'll merge this in and make it clearer in a more in depth deprecation message.

@pleerock
Copy link
Member

pleerock commented Aug 3, 2021

@imnotjames created #8010 for that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants