[Red5] getting flv file name

Art Clarke aclarke at vlideshow.com
Thu Feb 7 09:44:05 PST 2008


This should work:

//To get the name of a stream that is broadcasting in your Java
ApplicationAdapter implement the following function:

	public void streamBroadcastStart(IBroadcastStream stream) {
		String publishedName = stream.getPublishedName();
		// do your stuff here...
	}

//To get the names of streams that clients connect to for playback:

// First create a StreamPlaybackSecurity handler
public class MyStreamPlaybackSecurity implements IStreamPlaybackSecurity
{
	boolean isPlaybackAllowed(IScope scope, String name, int start, int
length, boolean flushPlaylist)
	{
		// Use the name as you need it.
		
		// return true so that the playback is allowed.
		return true;
	}
}

// Then in your application adapter, register the handler
public boolean appStart(IScope aScope) {		
	this.registerStreamPlaybackSecurity(new MyStreamPlaybackSecurity());
}

// Note that implementing an IStreamPublishSecurity handler should give you
the names of streams that
// are broadcast as well, but I find the startStreamBroadcast way to be
easier.

- Art

-----Original Message-----
From: red5-bounces at osflash.org [mailto:red5-bounces at osflash.org] On Behalf
Of nemux
Sent: Thursday, February 07, 2008 12:29 PM
To: red5 at osflash.org
Subject: [Red5] getting flv file name

Hello all,

how can i get FLV file name requested by client application ? 

for example :

client connect to : rtmp://rtmphost/blah.flv 

i'd like to get blah.flv with server side application. How can i do
it ? 

P.S.
maybe there is an IConnection object method that can help me... but i
don't know it. 

If this message is off topic please tell me where i can post it. Thank
you.

Bye,
Marco.
 



_______________________________________________
Red5 mailing list
Red5 at osflash.org
http://osflash.org/mailman/listinfo/red5_osflash.org




More information about the Red5 mailing list