You are viewing a plain text version of this content. The canonical link for it is here.
Posted to httpclient-users@hc.apache.org by Marcin Bazydlo <ma...@cs.put.poznan.pl> on 2012/01/26 08:29:12 UTC
nio ssl client with and without
Hi!
I have a proxy based on http components. We are currently upgrading it
to support ssl. We did fine on incoming part, but we are struggling with
the outgoing connections. We implemented both connections to SSL site
and to non-ssl site, but we would like to be able to handle both in one
reactor. Is it possible? What is the best way to do it? Currently, we
are thinking on implementing IOEventDispatcher which would (depending on
the connection port) pass requests to either Default or SSL implementation.
I would be glad to hear any comments and suggestions.
Best regards,
Marcin Bazydlo
---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org
Re: nio ssl client with and without
Posted by Oleg Kalnichevski <ol...@apache.org>.
On Thu, 2012-01-26 at 08:29 +0100, Marcin Bazydlo wrote:
> Hi!
> I have a proxy based on http components. We are currently upgrading it
> to support ssl. We did fine on incoming part, but we are struggling with
> the outgoing connections. We implemented both connections to SSL site
> and to non-ssl site, but we would like to be able to handle both in one
> reactor. Is it possible? What is the best way to do it? Currently, we
> are thinking on implementing IOEventDispatcher which would (depending on
> the connection port) pass requests to either Default or SSL implementation.
>
> I would be glad to hear any comments and suggestions.
>
> Best regards,
> Marcin Bazydlo
>
Marcin,
Indeed, what you need is a custom IOEventDispatcher that is aware of SSL
connections and that can handle differently than plain connections.
I assume you are using HttpCore 4.1.x. If you do not want to upgrade to
4.2-beta1, you could borrow such implementation from SVN:
http://svn.apache.org/repos/asf/httpcomponents/httpcore/trunk/httpcore-nio/src/main/java/org/apache/http/impl/nio/reactor/AbstractIODispatch.java
Hope this helps
Oleg
---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org