Wowza Community

Push Publish HLS module development

I am developing a module which will push HLS streams from Wowza to our CDN. I am using the module found on GitHub. It’s very useful!

I was looking through my logfiles and I noticed the following Info message:

2016-08-19 09:20:17 EDT comment server INFO 200 - PushPublishHTTPCupertinoFileHandler.disconnect(live/definst/myStream->myOutputStream) Statistics[success/attempts]: chunkPOST:43/43 chunkDELETE:40/40 chunklistPOST:43/43 playlistPOST:1/1 - - - 482.91 - - - - - - - - - - - - - - myStream - - - - - - - - - -

Where is this method which calls the the logInfo at a “disconnect” action? I am interested in cleaning up my CDN storage after a stream has ended without leaving behind old playlists and chunks.

You can overwrite the method

    @Override
    public void disconnect(boolean hard) {
        super.disconnect(hard);
        /* do something whatever you want */       
    }

But the push streaming will disconnect before data delivery to clients, we should not remove data too early.

Hi,

As chingyi pointed out, the base class PushPublishHTTPCupertino should have the disconnect() method which you can override. You can review the available methods in the Javadocs.

Michelle