Red5: appDisconnect problem

There are a lot of tutorials in the web about red5 media server. When I was trying to build my first application for red5 server I was using following tutorial Getting started with red5 server. When I compile app in eclipse, restart red5 server and was trying to connect to this application via my flash client, I detect from the red5.log that appConnect method worked correctly but when I closed flash client which was connected to red5 server, nothing happened. Seems that appDisconnect was not triggered.

I found solution in Red5 mailing list
http://www.mail-archive.com/red5@osflash.org/msg10694.html

Disconnect method should override super class method. I change appDisconnect method

from

  1. public void appDisconnect( IConnection conn , Object[] params )
  2. {
  3. log.info( "Red5First.appDisconnect " + conn.getClient().getId() );
  4. }

to

  1. /** Override super class method */
  2. public void appDisconnect( IConnection conn )
  3. {
  4. log.info( "Red5First.appDisconnect " + conn.getClient().getId() );
  5. super.appDisconnect(conn);
  6. }

Same problems can appear working with roomStart, appStart and appStop methods

I hope this information will help someone.

Leave a Comment

Please note: Comment moderation is enabled and may delay your comment. There is no need to resubmit your comment.