I am a newbie to RED5 server.
I have developed a chat application in FMS and I am migrating that to
RED5. Moreover, I have learned well about the ant server, red5 server
and red5 connections.
But, i am struggling with the big problem of maintaining the user
lists. Here is my Application.class code.

///////////////////////

package testchat;

import org.red5.server.adapter.ApplicationAdapter;
import org.red5.server.api.IConnection;
import org.red5.server.api.IScope;
import org.red5.server.api.so.ISharedObject;
import org.red5.server.api.Red5;
import java.util.HashMap;

public class Application extends ApplicationAdapter {


String Uname;
public Object sendMsg() {
ISharedObject so;
IScope a = Red5.getConnectionLocal().getScope();
so = getSharedObject(a, "so_users", false);
return so;
}

String userNames[];
int UserCount;
public boolean appStart(IScope room) {
createSharedObject(room, "userlists", false);
return true;
}

@Override
public boolean appConnect(IConnection conn, Object[] params) {
ISharedObject so;
IScope a = Red5.getConnectionLocal().getScope();
so = getSharedObject(a, "so_users", false);
so.beginUpdate();
HashMap<String, Object> hm = new HashMap<String, Object>();
hm.put("username", params[0]);
so.setAttribute(conn.getClient().getId(), hm);
so.endUpdate();
return true;
}

}



Here , i dont know whether i am right at this moment or not. Just , i
want to maintain the active connections information with the client
names. Here, I have tried with SharedObject and when try to get this
object in Flash the server cannot be connected and even doesnt do
anything when i try to complile the flash files. If possible, can you
anyone give me the server side code for this needs....


Thanks in advance..
Regards,

Arun.A


-- 
a_arunonline
------------------------------------------------------------------------
a_arunonline's Profile: 12
View this thread: http://www.nixspot.com/red5/showthread.php?t=1101


_______________________________________________
Red5 mailing list
[email protected]
http://osflash.org/mailman/listinfo/red5_osflash.org

Reply via email to