On Tue, Aug 14, 2012 at 10:11 AM, Andrew Lawrenson
<[email protected]> wrote:
> Hi all,
>
>
> I've been trying to write a service using Camel 2.10.0 which uses the mina2
> component to expose a service, and which uses SSL, using an endpoint of:
>
> mina2:tcp://localhost:6500?sync=true&filters=#hl7SslFilterFactory,#hl7CodecFilter&allowDefaultCodec=false
>
> however, what I found was that the SSL handshake was failing quite often for
> no apparent reason.  Investigating further, it appeared that messages sent
> during the handshake were being processed out of order - specifically, when
> the client (which uses a standard java SSLSocket) sent a "TLSv1 Change
> Cipher Spec" followed by a "TLSv1 Handshake", the "TLSv1 Handshake" was
> being processed before the "TLSv1 Change Cipher Spec", breaking the process.
>
> This appears to have been caused because when the the Mina2Consumer
> configures MINA for tcp (in Mina2Consumer.setupSocketProtocol), it is using
> a UnorderedThreadPoolExecutor - which allows messages to be processed in any
> order.  Switching this to use a OrderedThreadPoolExecutor instead has fixed
> the issue.
>
> May I request that the use of UnorderedThreadPoolExecutor vs
> OrderedThreadPoolExecutor be configurable via endpoint parameters? (or
> OrderedThreadPoolExecutor is used when SSL if configured).  I'm assuming the
> reason for the use of UnorderedThreadPoolExecutor is simply for performance.
>

Yeah that seems like a good finding. Do you mind creating a JIRA ticket?
And as we love contributions, then patches is welcome.
http://camel.apache.org/contributing.html

And btw I wonder if this would be a problem in the old Mina 1.x
component as well camel-mina?

And as well in camel-netty? Although its a different network library,
its similar to Apache Mina.



> many thanks in advance,
>
>   Andrew Lawrenson
>
>
>
> --
> View this message in context: 
> http://camel.465427.n5.nabble.com/Mina2Consumer-SSL-tp5717295.html
> Sent from the Camel Development mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
FuseSource
Email: [email protected]
Web: http://fusesource.com
Twitter: davsclaus, fusenews
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Reply via email to