Separate egress/ingress storage (#855)
This commit is contained in:
@@ -42,6 +42,7 @@ func InitializeServer(conf *config.Config, currentNode routing.LocalNode) (*Live
|
||||
telemetry.NewAnalyticsService,
|
||||
telemetry.NewTelemetryService,
|
||||
egress.NewRedisRPCClient,
|
||||
getEgressStore,
|
||||
NewEgressService,
|
||||
NewRoomAllocator,
|
||||
NewRoomService,
|
||||
@@ -165,6 +166,17 @@ func createStore(rc *redis.Client) ObjectStore {
|
||||
return NewLocalStore()
|
||||
}
|
||||
|
||||
func getEgressStore(s ObjectStore) EgressStore {
|
||||
switch store := s.(type) {
|
||||
case *RedisStore:
|
||||
return store
|
||||
case *LocalStore:
|
||||
return store
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
|
||||
func createClientConfiguration() clientconfiguration.ClientConfigurationManager {
|
||||
return clientconfiguration.NewStaticClientConfigurationManager(clientconfiguration.StaticConfigurations)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user