Hi All,
I had another look at this last night and thought that this may have been
due to the way I had the melb_barix input configured with
input.gstreamer.audio.
To try and rule this out, I tried to use input.http() with another stream,
but it did the same thing:
1. Queue (requests) starts off empty, plays the melb_barix input (http
stream) just fine.
2. Queue is populated via Telnet.
3. Queue plays fine.
4. Queue empties and LiquidSoap terminates.
The expected behaviour of course is that once the request queue has
emptied, that LiquidSoap does a fallback to the melb_barix input
(ultimately the RTP stream, but in this case, the HTTP stream would prove
the concept).
It would almost appear that any streamed source (i.e. not files or a
playlist) silently stop working in the background when playing audio files
and even with mksafe (perhaps I've misunderstood what this does?) never
returns.
Any suggestions?
Kind Regards,
Jonathan
---------- Forwarded message ----------
From: Jonathan Thorpe <[email protected]>
Date: 30 June 2015 at 17:07
Subject: Fallback to input.gstreamer.audio not working
To: [email protected]
Hi All,
Very new to Liquidsoap, but absolutely love the potential this software has.
I'm attempting to use it as part of a project to generate regional streams
that play advertisements over the top of a main stream.
The source of the audio is from a Barix Instreamer which I have sending
MPEG RTP audio using gstreamer.
The idea is to use the Telnet or Unix socket interface to push requests to
play ads. When the queue is empty, play the main feed (melb_barix).
This is what I have so far:
----
set("log.file.path", "/var/log/liquidsoap/melb.log")
set("log.file", true)
set("log.stdout", true)
set("log.level",10)
set("server.telnet",true)
set("server.telnet.bind_addr","127.0.0.1")
set("server.telnet.port",1234)
set("server.telnet.reverse_dns",false)
requests = audio_to_stereo(request.queue(id="requests"))
melb_barix = mksafe(audio_to_stereo(input.gstreamer.audio(pipeline='udpsrc
port=5004 caps="application/x-rtp" ! rtpmpadepay')))
melb_source = fallback(track_sensitive=false,[requests, melb_barix])
output.icecast(%mp3(stereo=false, bitrate=96,samplerate=32000),
host = "127.0.0.1", port = 8000,
public=false,
password = "hackme", mount = "radio-melbads",
description = "Radio xxx",
mksafe(mean(melb_source)))
----
When LiquidSoap starts, it plays the melb_barix source just fine. Then,
pushing requests to the queue as follows also works:
echo -en "requests.push /tmp/test.ogg\n" | telnet 127.0.0.1 1234
However, as soon as the request queue is emptied, LiquidSoap quits with:
----
2015/06/30 15:18:08 [decoder.ogg:5] Reached last page of logical stream 1b67
2015/06/30 15:18:08 [decoder.ogg:5] All data from stream 1b67 has been
decoded
2015/06/30 15:18:08 [decoder:4] Decoding "/tmp/test.ogg" ended:
Ogg.End_of_stream.
2015/06/30 15:18:08 [clock.wallclock_main:2] Source radio-melbads failed
while streaming: Ogg.End_of_stream!
2015/06/30 15:18:08 [radio-melbads:4] Activations changed: static=[],
dynamic=[].
2015/06/30 15:18:08 [source:4] Source radio-melbads gets down.
2015/06/30 15:18:08 [radio-melbads:3] Closing connection...
2015/06/30 15:18:08 [mksafe:4] Activations changed: static=[], dynamic=[].
2015/06/30 15:18:08 [source:4] Source mksafe gets down.
2015/06/30 15:18:08 [mean_6054:4] Activations changed:
static=[mksafe:radio-melbads:radio-melbads], dynamic=[].
2015/06/30 15:18:08 [safe_blank:4] Activations changed: static=[],
dynamic=[].
2015/06/30 15:18:08 [source:4] Source safe_blank gets down.
2015/06/30 15:18:08 [mean_6054:4] Activations changed: static=[],
dynamic=[].
2015/06/30 15:18:08 [source:4] Source mean_6054 gets down.
2015/06/30 15:18:08 [fallback_6052:4] Activations changed: static=[],
dynamic=[].
2015/06/30 15:18:08 [source:4] Source fallback_6052 gets down.
2015/06/30 15:18:08 [audio_to_stereo_6045:4] Activations changed:
static=[fallback_6052:mean_6054:mksafe:radio-melbads:radio-melbads],
dynamic=[].
2015/06/30 15:18:08 [mksafe:4] Activations changed: static=[], dynamic=[].
2015/06/30 15:18:08 [source:4] Source mksafe gets down.
2015/06/30 15:18:08 [audio_to_stereo_6048:4] Activations changed:
static=[mksafe:fallback_6052:mean_6054:mksafe:radio-melbads:radio-melbads],
dynamic=[].
2015/06/30 15:18:08 [safe_blank:4] Activations changed: static=[],
dynamic=[].
2015/06/30 15:18:08 [source:4] Source safe_blank gets down.
2015/06/30 15:18:08 [audio_to_stereo_6048:4] Activations changed:
static=[], dynamic=[].
2015/06/30 15:18:08 [source:4] Source audio_to_stereo_6048 gets down.
2015/06/30 15:18:08 [input(dot)gstreamer(dot)audio_video_6047:4]
Activations changed: static=[], dynamic=[].
2015/06/30 15:18:08 [source:4] Source
input(dot)gstreamer(dot)audio_video_6047 gets down.
2015/06/30 15:18:08 [audio_to_stereo_6045:4] Activations changed:
static=[], dynamic=[].
2015/06/30 15:18:08 [source:4] Source audio_to_stereo_6045 gets down.
2015/06/30 15:18:08 [requests:4] Activations changed: static=[], dynamic=[].
2015/06/30 15:18:08 [source:4] Source requests gets down.
2015/06/30 15:18:08 [requests:4] Waiting for feeding task to stop...
2015/06/30 15:18:08 [requests:3] Finished with "/tmp/test.ogg".
2015/06/30 15:18:08 [requests:4] Cleaning up request queue...
2015/06/30 15:18:08 [clock.wallclock_main:3] Streaming loop stopped.
2015/06/30 15:18:08 [main:3] Shutdown started!
2015/06/30 15:18:08 [threads:3] Thread "wallclock_main" terminated (0
remaining).
2015/06/30 15:18:08 [main:3] Waiting for threads to terminate...
2015/06/30 15:18:08 [main:3] Cleaning downloaded files...
2015/06/30 15:18:08 [main:3] Freeing memory...
2015/06/30 15:18:08 >>> LOG END
----
After a few hours of trying various combinations of things, I'm at a loss.
I'm running LiquidSoap 1.1.1-7+b1 using Debian Jessie's packages.
Anyone have any pointers as to what have I done wrong?
Kind Regards,
Jonathan
------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that
you need to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users