XEP-0030: Service Discovery #28
Labels
No Label
bug
CI
documentation
duplicate
enhancement
good first issue
help wanted
i18n
invalid
needs-investigation
ops
proposal
proposal-accepted
proposal-declined
question
refactor
security
testing
upstream
wontfix
Kind: Breaking
Kind: Bug
Kind: Documentation
Kind: Enhancement
Kind: Feature
Kind: Maintenance
Kind: Question
Kind: Security
Kind: Testing
Priority: Critical
Priority: High
Priority: Low
Priority: Medium
Reviewed: Confirmed
Reviewed: Duplicate
Reviewed: Invalid
Status: Blocked
Status: Completed
Status: Help wanted
Status: In progress
Status: Needs feedback
Status: Stale
No Milestone
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: mellium/xmpp#28
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
XEP-0030: Service Discovery should be implemented in a new
disco
package and be integrated with themux
package so that a multiplexer can respond to disco requests using the handlers that have already been registered.Design doc: https://mellium.im/design/28_disco
I had an idea today that may supersede this design doc. Thinking about the way we recently implemented
muc
I thought we might start following the design principal "handle behavior, not state". If the user is handling state it lets them be maximally flexible and scale to their own needs without having to rewrite entire modules. Eg in a muc we don't actually keep track of all the MUCs we've joined and all the users in those MUCs, we leave that to the application or a higher-level library to implement.We can do the same here. Instead of a registry that we add all our disco features too, what if we just provide an interface for figuring out what features are supported by a handler? Then we don't have to store a registry and process it.
In our specific case
mux
is the higher level library, but since the handlers don't have access to all the other handlers we would implement disco as a middleware instead, ie. in the disco package we'd have something like: