Make ConnectionManager a general-purpose select server and implement a flash Policy server with it.
The presents-specific portions of ConnectionManager like reading Message subclasses and sending datagrams are now in PresentsConnectionManager. PresentsServer should behave identically, except during shutdown. Before, connections would be accepted and datagrams would be read until the OMgr thread exited. Now, both stop as soon as the server begins its shutdown. This seems like an improvement to me, but let me know if it causes issues and I can rework it. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@6270 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -46,7 +46,9 @@ import com.threerings.presents.data.ClientObject;
|
||||
import com.threerings.presents.net.AuthRequest;
|
||||
import com.threerings.presents.net.AuthResponse;
|
||||
import com.threerings.presents.server.net.AuthingConnection;
|
||||
import com.threerings.presents.server.net.Connection;
|
||||
import com.threerings.presents.server.net.PresentsConnection;
|
||||
|
||||
import com.threerings.nio.conman.Connection;
|
||||
|
||||
import static com.threerings.presents.Log.log;
|
||||
|
||||
@@ -407,7 +409,7 @@ public class ClientManager
|
||||
* Called by the connection manager to let us know when a new connection has been established.
|
||||
*/
|
||||
public synchronized void connectionEstablished (
|
||||
Connection conn, Name authname, AuthRequest req, AuthResponse rsp)
|
||||
PresentsConnection conn, Name authname, AuthRequest req, AuthResponse rsp)
|
||||
{
|
||||
String type = authname.getClass().getSimpleName();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user