#302: some strange things while using 2 harbor sources at once
---------------------------+------------------------------------------------
 Reporter:  romeodeepmind  |       Owner:  admin      
     Type:  Bugs           |      Status:  new        
 Priority:  1              |   Milestone:  NEAR FUTURE
Component:  Liquidsoap     |     Version:  0.9.1+svn  
 Keywords:                 |         Mac:  1          
    Linux:  1              |      Netbsd:  1          
    Other:  1              |     Freebsd:  1          
---------------------------+------------------------------------------------
 Hi, Savonet Team!

 I have 2 harbor sources that can be used together. one for external
 playlist stream generator, another for live performances.

 this 2 sources joins into one source using swhitch operator. it is very
 useful for me, as i can make transitions between live and playlist, and if
 live doesn't starts at time playlist continues to play.

 now about stranges: after live connect-play-disconnect i can hear a short
 parts of a tracks that were streamed to playlist during live was on air.
 just about 10 - 30 secs per track. the closer it gets to current time the
 longer part is. this sounds very interesting as listeners can hear a
 "review" of all tracks that were played in playlist during live, but this
 is not the thing that i expect to get.

 well commented log and config are attached

 Config:
 {{{
 #!/usr/bin/liquidsoap

 %include "/home/vko/misc/settings.liq"

 set("server.telnet",true)
 set("server.telnet.port",8091)

 set("harbor.bind_addr","0.0.0.0")
 set("harbor.port",8090)
 set("harbor.password", playlistPasswd)

 system("/home/vko/misc/live.sh")

 ################### [Callbacks] ###################

 def liveStart(headers)
     log("[LIVE-START]: live source goes up! Switching from playlist...")
     system("/home/vko/misc/live.sh " ^
             quote(headers["ice-name"]) ^ " " ^
             quote(headers["ice-description"]) ^ " " ^
             quote(headers["ice-genre"]) ^ " " ^
             quote(headers["ice-url"]) ^ " " ^
             quote(headers["ice-bitrate"]) ^ " " ^
             quote(headers["ice-audio-info"]) ^ " " ^
             quote(headers["content-type"]) ^ " " ^
             quote(headers["user-agent"]))

     title = headers["ice-name"] ^ " | " ^
             headers["ice-description"] ^ " | " ^
             headers["ice-genre"]

     log("Live-meta: " ^ title)

     ignore(server.execute("liveMeta.insert title=\"#{title}\""))
 end

 def liveEnd()
     log("[LIVE-END]: live source goes down! Switching to playlist...")
     system("/home/vko/misc/live.sh")
 end

 def playlistStart(headers)
     log("[PLAYLIST-START]: playlist source goes up! Switching from
 noise...")
 end

 def playlistEnd()
     log("[PLAYLIST-END]: playlist source goes down! Switching to
 noise...")
 end

 ################### [Live Sources] ###################

 #Live Sources
 liveInput = input.harbor(       id="live",
                                 "live.ogg",
                                 buffer=2.,
                                 password=livePasswd,
                                 on_connect=liveStart,
                                 on_disconnect=liveEnd)

 liveInput = insert_metadata(id="liveMeta", liveInput)

 ################### [Playlists] ###################
 playlistInput = input.harbor(id="playlist",
                                 "playlist.ogg",
                                 buffer=10.,
                                 password=playlistPasswd,
                                 on_connect=playlistStart,
                                 on_disconnect=playlistEnd)

 ################### [Noise] ###################

 noiseInput = noise(id="noise")
 noiseInput = amplify(id="noiseAmp", 0.05, noiseInput)
 noiseInput = rewrite_metadata([("title","no signal")], noiseInput)

 ################### [Master Input] ###################

 #Master Input
 input=fallback(                 id="mainFallback",
                                 track_sensitive=false,
                                 [liveInput, playlistInput, noiseInput])

 ################### [Mount Points] ###################

          output.icecast.mp3(    id="192mp3",
                                 bitrate=192,
                                 input,
                                 restart=true,
                                 password=omegaRelayPasswd,
                                 mount="rvk192",
                                 name=streamTitle,
                                 genre=streamGenre,
                                 url=streamUrl,
                                 description=streamDescr)
 }}}

 log:
 {{{

 <...Here Live Goes UP...>

 2009/08/02 22:55:29 [harbor:3] New client: 109.164.249.ozerki.net
 2009/08/02 22:55:29 [harbor:4] Header: CONTENT-TYPE, value:
 application/ogg.
 2009/08/02 22:55:29 [harbor:4] Header: ICE-NAME, value: TUMAN Pro show.
 2009/08/02 22:55:29 [harbor:4] Header: ICE-URL, value:
 http://radiovkontakte.ru/table.
 2009/08/02 22:55:29 [harbor:4] Header: ICE-GENRE, value: house.
 2009/08/02 22:55:29 [harbor:4] Header: ICE-BITRATE, value: 192.
 2009/08/02 22:55:29 [harbor:4] Header: ICE-PRIVATE, value: 0.
 2009/08/02 22:55:29 [harbor:4] Header: ICE-PUBLIC, value: 1.
 2009/08/02 22:55:29 [harbor:4] Header: ICE-DESCRIPTION, value: Subbotin.
 2009/08/02 22:55:29 [harbor:4] Header: ICE-AUDIO-INFO, value: ice-
 samplerate=44100;ice-bitrate=192;ice-channels=2.
 2009/08/02 22:55:29 [harbor:4] Client logged in.
 2009/08/02 22:55:29 [harbor:3] SOURCE request on /live.ogg.
 2009/08/02 22:55:29 [harbor:3] Adding source on mountpoint '/live.ogg'
 with type 'application/ogg'.
 2009/08/02 22:55:29 [lang:3] [LIVE-START]: live source goes up! Switching
 from playlist...
 2009/08/02 22:55:29 [lang:3] Live-meta: TUMAN Pro show | Subbotin | house
 2009/08/02 22:55:29 [threads:3] Created thread "harbor source feeding" (3
 total).
 2009/08/02 22:55:29 [live:3] Decoding...
 2009/08/02 22:55:29 [ogg.demuxer:4] Found a ogg logical stream, serial:
 13e7
 2009/08/02 22:55:29 [ogg.demuxer:4] Trying ogg/vorbis format
 2009/08/02 22:55:29 [ogg.demuxer:4] Reached last page of logical stream
 13e7
 2009/08/02 22:55:29 [ogg.demuxer:4] Found a ogg logical stream, serial:
 13e7
 2009/08/02 22:55:29 [ogg.demuxer:4] Trying ogg/vorbis format
 2009/08/02 22:55:30 [live:4] No network activity for 1 second(s).
 2009/08/02 22:55:31 [live:4] No network activity for 2 second(s).
 2009/08/02 22:55:32 [live:4] No network activity for 3 second(s).
 2009/08/02 22:55:33 [live:4] No network activity for 4 second(s).
 2009/08/02 22:55:33 [live:3] New metadata chunk " -- "
 2009/08/02 22:55:35 [mainFallback:3] Switch to liveMeta with transition.
 2009/08/02 22:55:35 [source:4] src_5205 gets down
 2009/08/02 22:55:35 [playlist:4] Activations changed: static=[],
 dynamic=[mainFallback:192mp3:192mp3].
 2009/08/02 22:55:35 [src_5205:4] Activations changed: static=[],
 dynamic=[].
 2009/08/02 22:55:35 [liveMeta:4] Activations changed:
 static=[mainFallback:192mp3:192mp3], dynamic=[mainFallback:192mp3:192mp3].
 2009/08/02 23:03:33 [live:4] No network activity for 1 second(s).
 2009/08/02 23:43:33 [live:4] No network activity for 1 second(s).
 2009/08/02 23:53:33 [live:4] No network activity for 1 second(s).
 2009/08/03 00:43:33 [live:4] No network activity for 1 second(s).

 <...here something happens with both sources, i guess playlist wakeups as
 live have network issues...>

 2009/08/03 01:18:52 [ogg.demuxer:4] Reached last page of logical stream
 4ffb3
 2009/08/03 01:18:56 [ogg.demuxer:4] Found a ogg logical stream, serial:
 4ae47
 2009/08/03 01:18:56 [ogg.demuxer:4] Trying ogg/vorbis format

 <...It finds new track and metadata only on 01:18:56, but this track was
 on 22:55:40 when live have already been up!...>

 2009/08/03 01:18:56 [playlist:3] New metadata chunk "? -- hot"
 2009/08/03 01:24:10 [ogg.demuxer:4] Reached last page of logical stream
 4ae47
 2009/08/03 01:24:13 [ogg.demuxer:4] Found a ogg logical stream, serial:
 71474
 2009/08/03 01:24:13 [ogg.demuxer:4] Trying ogg/vorbis format
 2009/08/03 01:24:13 [playlist:3] New metadata chunk "? -- zaregaisia
 pozitiv"
 2009/08/03 01:36:31 [ogg.demuxer:4] Reached last page of logical stream
 71474
 2009/08/03 01:36:35 [ogg.demuxer:4] Found a ogg logical stream, serial:
 b9cca
 2009/08/03 01:36:35 [ogg.demuxer:4] Trying ogg/vorbis format
 2009/08/03 01:36:35 [playlist:3] New metadata chunk "Empire Of The Sun --
 We Are The People (Sam La More Remix)"

 <...Untill this live continues to play, but playlist still have some
 activity...>

 2009/08/03 01:38:36 [live:2] Feeding stopped: Unix.Unix_error(56, "read",
 "")
 2009/08/03 01:38:36 [lang:3] [LIVE-END]: live source goes down! Switching
 to playlist...
 2009/08/03 01:38:36 [threads:3] Thread "harbor source feeding" exited (2
 remaining).

 <...here live goes down and a "quick review" begins...>

 2009/08/03 01:38:38 [live:4] End of track.
 2009/08/03 01:38:38 [live:4] Buffer emptied, starting buffering.
 2009/08/03 01:38:38 [mainFallback:3] Switch to playlist with forgetful
 transition.
 2009/08/03 01:38:38 [liveMeta:4] Activations changed: static=[],
 dynamic=[mainFallback:192mp3:192mp3].
 2009/08/03 01:38:38 [source:4] src_5211 gets up
 2009/08/03 01:38:38 [playlist:4] Activations changed:
 static=[src_5211:mainFallback:192mp3:192mp3],
 dynamic=[mainFallback:192mp3:192mp3].
 2009/08/03 01:38:38 [src_5211:4] Activations changed:
 static=[mainFallback:192mp3:192mp3], dynamic=[].
 2009/08/03 01:39:47 [ogg.demuxer:4] Reached last page of logical stream
 b9cca
 2009/08/03 01:39:47 [ogg.demuxer:4] Found a ogg logical stream, serial:
 5251c
 2009/08/03 01:39:47 [ogg.demuxer:4] Trying ogg/vorbis format

 <...first track. in fact it was on 22:59:36 ...>

 2009/08/03 01:39:47 [playlist:3] New metadata chunk "Babylon Zoo --
 Spaceman (Polish Rumble Remix)"
 2009/08/03 01:39:53 [ogg.demuxer:4] Reached last page of logical stream
 5251c
 2009/08/03 01:39:53 [ogg.demuxer:4] Found a ogg logical stream, serial:
 b1704
 2009/08/03 01:39:53 [ogg.demuxer:4] Trying ogg/vorbis format

 <... after 6 secs another track, it was on 23:25:36. between this and
 previous there were 5 tracks that is skipped here...>

 2009/08/03 01:39:53 [playlist:3] New metadata chunk "? --
 Radiovkontakte.ru"
 2009/08/03 01:40:07 [ogg.demuxer:4] Reached last page of logical stream
 b1704
 2009/08/03 01:40:07 [ogg.demuxer:4] Found a ogg logical stream, serial:
 8ea8f
 2009/08/03 01:40:07 [ogg.demuxer:4] Trying ogg/vorbis format

 <... after 7 secs another track, it was on 23:53:53. between this and
 previous there were 7 tracks that is skipped here...>

 2009/08/03 01:40:07 [playlist:3] New metadata chunk "? -- hot"
 2009/08/03 01:40:14 [ogg.demuxer:4] Reached last page of logical stream
 8ea8f
 2009/08/03 01:40:14 [ogg.demuxer:4] Found a ogg logical stream, serial:
 54d7e
 2009/08/03 01:40:14 [ogg.demuxer:4] Trying ogg/vorbis format

 <... after 7 secs another track, it was on 00:21:13. between this and
 previous there were 10 tracks that is skipped here...>

 2009/08/03 01:40:14 [playlist:3] New metadata chunk "? -- mi delaem hiti"
 2009/08/03 01:40:21 [ogg.demuxer:4] Reached last page of logical stream
 54d7e
 2009/08/03 01:40:21 [ogg.demuxer:4] Found a ogg logical stream, serial:
 57d90
 2009/08/03 01:40:21 [ogg.demuxer:4] Trying ogg/vorbis format

 <... after 7 secs another track, it was on 00:52:09. between this and
 previous there were 10 tracks that is skipped here...>

 2009/08/03 01:40:21 [playlist:3] New metadata chunk "syncopix and tomahawk
 -- collateral-sour"
 2009/08/03 01:40:35 [ogg.demuxer:4] Reached last page of logical stream
 57d90
 2009/08/03 01:40:35 [ogg.demuxer:4] Found a ogg logical stream, serial:
 75ba5
 2009/08/03 01:40:35 [ogg.demuxer:4] Trying ogg/vorbis format

 <... after 14 secs another track, it was on 01:31:16. between this and
 previous there were 12 tracks that is skipped here...>

 2009/08/03 01:40:35 [playlist:3] New metadata chunk "DJ Antoine --
 Castaway (Original Mix)"
 2009/08/03 01:42:58 [ogg.demuxer:4] Reached last page of logical stream
 75ba5
 2009/08/03 01:42:58 [ogg.demuxer:4] Found a ogg logical stream, serial:
 98bd0
 2009/08/03 01:42:58 [ogg.demuxer:4] Trying ogg/vorbis format

 <... after 2 min 23 secs another track. between this and previous there
 was 1 track that is skipped here

 here stream syncs with current time and everything goes in time now. ...>

 2009/08/03 01:42:58 [playlist:3] New metadata chunk "The Saturdays --
 Issues (Digital Dog Club)"

 }}}

-- 
Ticket URL: <http://savonet.rastageeks.org/ticket/302>
Savonet <http://savonet.rastageeks.org/>
Let's program our stream !
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Savonet-trac mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-trac

Reply via email to