config rework to handle distributed setup, fixed redis bugs
This commit is contained in:
@@ -25,10 +25,14 @@ func NewLocalRouter(currentNode LocalNode) *LocalRouter {
|
||||
}
|
||||
}
|
||||
|
||||
func (r *LocalRouter) GetNodeIdForRoom(roomName string) (string, error) {
|
||||
func (r *LocalRouter) GetNodeForRoom(roomName string) (string, error) {
|
||||
return r.currentNode.Id, nil
|
||||
}
|
||||
|
||||
func (r *LocalRouter) SetNodeForRoom(roomName string, nodeId string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (r *LocalRouter) RegisterNode() error {
|
||||
return nil
|
||||
}
|
||||
@@ -44,6 +48,12 @@ func (r *LocalRouter) GetNode(nodeId string) (*livekit.Node, error) {
|
||||
return nil, ErrNotFound
|
||||
}
|
||||
|
||||
func (r *LocalRouter) ListNodes() ([]*livekit.Node, error) {
|
||||
return []*livekit.Node{
|
||||
r.currentNode,
|
||||
}, nil
|
||||
}
|
||||
|
||||
func (r *LocalRouter) StartParticipant(roomName, participantId, participantName string) error {
|
||||
// treat it as a new participant connecting
|
||||
if r.onNewParticipant == nil {
|
||||
|
||||
Reference in New Issue
Block a user