directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Niklas Therning (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DIRMINA-42) SessionManagers should manage list of sessions being managed.
Date Sun, 18 Dec 2005 10:20:35 GMT
    [ http://issues.apache.org/jira/browse/DIRMINA-42?page=comments#action_12360711 ] 

Niklas Therning commented on DIRMINA-42:
----------------------------------------

I've been taking a look at Federico's patch and it looks very promising. As he pointed out
it only solves this issue for SocketAcceptors. But it shouldn't be to hard to add this support
to VmPipeAcceptors. For DatagramAcceptors I don't think this issue applies?

Then come the IoConnectors. They are IoSessionManagers as well. I think it will be trivial
to extend Federico's approach to include SocketConnector.

One thing I still can't figure out though is what the key should be in the IoSessionMap. In
the SocketAcceptor case it should probably be the remote address. But that won't work in the
SocketConnector case (it's very likely that sessions will be connected to the same remote
address). Then it would have to be the local address instead. 

For the VMPIPE transport neither will work without some refactoring.

As pointed out by Federico previously the key is, in most cases, probably protocol specific.
Because of that the user will have to maintain some kind of app specific key to socket address
string mapping anyway. In Ryan's case he's using a database to maintain this kind of mapping.
I don't think it would be too hard on the user if he would have to maintain the mapping to
IoSession himself.

What I'm trying to say is that I think it would suffice with a Collection instead of a Map.
That would be enough to solve DIRMINA-93. I propose that the method

Collection getManagedSessions(SocketAddress)

is added to IoSessionManager (or at least IoAcceptor to solve DIRMINA-93). The returned collection
should be unmodifiable of course. WDYT?


> SessionManagers should manage list of sessions being managed.
> -------------------------------------------------------------
>
>          Key: DIRMINA-42
>          URL: http://issues.apache.org/jira/browse/DIRMINA-42
>      Project: Directory MINA
>         Type: New Feature
>     Versions: 0.7
>     Reporter: Trustin Lee
>     Assignee: Niklas Therning
>      Fix For: 0.9.1
>  Attachments: DIRMINA-42.zip
>
> Users are maintaining the list of managed sessions in acceptors and connectors.  It will
be much better if MINA can handle this.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message