How do I get a static list of all supported protocols? #4982
Replies: 1 comment 5 replies
-
I am not sure this is correct.
Note that it is not the
Today, I don't see a way other than implementing your own |
Beta Was this translation helpful? Give feedback.
-
With the changes in 0.52 its now possible to dynamically get a list of supported protocols. However I am interested (for diagnostic reasons) in getting the union of supported protocols of the local node regardless of if there is an active connection using that protocol.
As far as I can tell the only way to get a list of protocols now is to listen for
ConnectionEvent::LocalProtocolsChange
events. However this implies that whatever protocol is listening for those events is shared between all connected peers. Otherwise the handler does not get theConnectionEvent::LocalProtocolsChange
events themselves. Do I miss understand?Is there a way to directly ask a behavior for its static set of protocols? Or maybe a way for the
identify
behavior to expose the union of all locally supported protocols across all connections?Preferably I can get this set before even a single connection is made. Thoughts?
Beta Was this translation helpful? Give feedback.
All reactions