Results 1 to 3 of 3

Thread: Detect failure of mediacaster stream?

  1. #1

    Default Detect failure of mediacaster stream?

    I'm wondering how to detect the failure of a mediacaster stream while it's being played, or even just the failure to connect up initially. I've tried the "addMediaCasterListener" method on the application object, but nothing catches it. I can see in the logs this:

    Successful connection for mediacaster: 2 - - -
    ShoutCastDecoder.checkHeader[]: HTTP response: 404

    The first line is from the class I'm using to detect connections etc for the listener, the second is from some internal class I guess. As you can see, the connection success is firing but the HTTP response is 404.. How do I grab that?

    More importantly though, I need to know when a mediacaster stream fails part way through. Any ideas?

  2. #2
    Join Date
    May 2013



    One option would be to check the streams last packet to see if there is an associated timecode. You could do this twice (~200ms apart) and compare the timecodes. You can check the timecode similar to the following:

    // Example only 
    IApplication app = vhost.getApplication("live"); 
    IApplicationInstance instance = app.getAppInstance("_definst_"); 
    IMediaStream stream = instance.getStreams().getStream("myStream");
    if (stream != null && stream.getLastPacket() != null)
        if (stream.getLastPacket().getAbsTimecode() > 0)
          // looks like stream is valid

  3. #3


    Thanks Matt. I was really hoping for the event like the internal Wowza runtime gets (as log entries go by like crazy for the "switch") and not have to brute force check it and run my own event. I'll see what I can do with this then.

Similar Threads

  1. stream failure
    By i_lutokhin in forum General Forum
    Replies: 3
    Last Post: 03-21-2016, 07:13 AM
  2. Detect if stream is a DVR store stream
    By Meinaart in forum Wowza nDVR
    Replies: 1
    Last Post: 02-11-2014, 04:58 AM
  3. My .stream I using with stream manager gives me "...Failure no URL"
    By timeview in forum Live Streaming and Encoder Discussion
    Replies: 4
    Last Post: 02-02-2014, 02:31 PM
  4. EZDRM possible failure with Firefox and Safari on MAC
    By inerim in forum AddOn: Wowza DRM
    Replies: 1
    Last Post: 10-12-2011, 05:35 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts