James Im wrote:
I don't know if a filter is the best solution. You should look at the
tennis example that uses VmPipeConnector/VmPipeAcceptor.
These classes allow intra VM communication through a pseudo port. The
port is not a real port so no socket are created.
Both SocketAcceptor, VmPipeAcceptor and even DatagramAcceptorDelegate
extends BaseIoAcceptor.
So the idea would be to use a VmPipeAcceptor instead of a SocketAcceptor
when starting the ftpserver in 1.4 compatibility mode.
Then as I said before, the blocking ssl server would feed to bytes to
the VmPipeAcceptor (via a VmPipeConnector).
This design would be performant as no extra sockets are created. It
would also be clean: when designing the ftpserver on top of mina you
don't have to take into account extra stuff to be able to support 1.4.
This could work for ftpserver 1.0.
The problem with this solution (as well as mine using a filter) is that
it would make us stuck with MINA 1.0.1 for as long as we would like to
support 1.4. MINA 1.1 is already built with 1.5 bytecode which would not
be runnable on 1.4 (of course). So, I think that the 1.4 compliant
solution should probably not use MINA at all and rather use our current
solution.
/niklas