Skip to content
Snippets Groups Projects
Commit a6050d37 authored by David Trattnig's avatar David Trattnig
Browse files

Channels for station fallbacks. #38

parent a1a6f687
No related branches found
No related tags found
No related merge requests found
...@@ -32,12 +32,10 @@ class TransitionType(Enum): ...@@ -32,12 +32,10 @@ class TransitionType(Enum):
class Channel(Enum): class Channel(Enum):
""" """
Channel name mappings to the Liqidsoap channel IDs. Channel name mappings to the Liqidsoap channel/source IDs.
""" """
QUEUE_A = "in_filesystem_0" QUEUE_A = "in_filesystem_0"
QUEUE_B = "in_filesystem_1" QUEUE_B = "in_filesystem_1"
FALLBACK_QUEUE_A = "in_fallback_scheduled_0"
FALLBACK_QUEUE_B = "in_fallback_scheduled_1"
HTTP_A = "in_http_0" HTTP_A = "in_http_0"
HTTP_B = "in_http_1" HTTP_B = "in_http_1"
HTTPS_A = "in_https_0" HTTPS_A = "in_https_0"
...@@ -47,6 +45,10 @@ class Channel(Enum): ...@@ -47,6 +45,10 @@ class Channel(Enum):
LIVE_2 = "linein_2" LIVE_2 = "linein_2"
LIVE_3 = "linein_3" LIVE_3 = "linein_3"
LIVE_4 = "linein_4" LIVE_4 = "linein_4"
FALLBACK_QUEUE_A = "in_fallback_scheduled_0"
FALLBACK_QUEUE_B = "in_fallback_scheduled_1"
FALLBACK_STATION_FOLDER = "station_folder"
FALLBACK_STATION_PLAYLIST = "station_playlist"
def __str__(self): def __str__(self):
return str(self.value) return str(self.value)
...@@ -61,11 +63,6 @@ class ChannelType(Enum): ...@@ -61,11 +63,6 @@ class ChannelType(Enum):
"numeric": 0, "numeric": 0,
"channels": [Channel.QUEUE_A, Channel.QUEUE_B] "channels": [Channel.QUEUE_A, Channel.QUEUE_B]
} }
FALLBACK_QUEUE = {
"id": "fallback_queue",
"numeric": 0,
"channels": [Channel.FALLBACK_QUEUE_A, Channel.FALLBACK_QUEUE_B]
}
HTTP = { HTTP = {
"id": "http", "id": "http",
"numeric": 1, "numeric": 1,
...@@ -87,6 +84,16 @@ class ChannelType(Enum): ...@@ -87,6 +84,16 @@ class ChannelType(Enum):
Channel.LIVE_4 Channel.LIVE_4
] ]
} }
FALLBACK_QUEUE = {
"id": "fallback_queue",
"numeric": 4,
"channels": [Channel.FALLBACK_QUEUE_A, Channel.FALLBACK_QUEUE_B]
}
FALLBACK_POOL = {
"id": "fallback_pool",
"numeric": 5,
"channels": [Channel.FALLBACK_STATION_FOLDER, Channel.FALLBACK_STATION_PLAYLIST]
}
@property @property
def channels(self): def channels(self):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment