You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Charles Moulliard <cm...@gmail.com> on 2011/04/07 13:28:38 UTC

Re: FTP over Proxy

Hi,

For sure that we are interested. Here is the page describing the process to
create a ticket + patch

http://camel.apache.org/contributing.html

Regards,

Charles Moulliard
Apache Committer

--
View this message in context: http://camel.465427.n5.nabble.com/FTP-over-Proxy-tp3314841p4288277.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: FTP over Proxy

Posted by Charles Moulliard <cm...@gmail.com>.
Thx. I will try to have a look next week.

On Thu, Apr 7, 2011 at 11:25 PM, alexey-s [via Camel]
<ml...@n5.nabble.com> wrote:
> Hi.
> I have add https://issues.apache.org/jira/browse/CAMEL-3845
>
>
> Regards,
>
> Aleksey Sushko
>
> ________________________________
> If you reply to this email, your message will be added to the discussion
> below:
> http://camel.465427.n5.nabble.com/FTP-over-Proxy-tp3314841p4289492.html
> To unsubscribe from FTP over Proxy, click here.


--
View this message in context: http://camel.465427.n5.nabble.com/FTP-over-Proxy-tp3314841p4290158.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: FTP over Proxy

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

Good idea about that setProperties in default endpoint.

I logged a couple of tickets
https://issues.apache.org/jira/browse/CAMEL-6907
https://issues.apache.org/jira/browse/CAMEL-6908

On Fri, Oct 25, 2013 at 5:30 AM, alexey-s <al...@mail.ru> wrote:
> Hi
>
> The change is very small
>
> DefaultComponent object has a method
>      protected void setProperties (Object bean, Map <String, Object>
> parameters) throws Exception
> It is necessary to repeat this method in DefaultEndpoint.
>
> Why is that? Used factory EndpointHelper owes its name to the tune
> DefaultEndpoint.
>
> FtpEndpoint is created by setting the parameter component.
>
> replace the line
> 103:   IntrospectionSupport.setProperties (client, ftpClientParameters);
> 111:   IntrospectionSupport.setProperties (ftpClientConfig,
> ftpClientConfigParameters);
> the challenge of the new method
> 103:   setProperties (client, ftpClientParameters);
> 111:   setProperties (ftpClientConfig, ftpClientConfigParameters);
>
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/FTP-over-Proxy-tp3314841p5742147.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: FTP over Proxy

Posted by alexey-s <al...@mail.ru>.
Hi

The change is very small

DefaultComponent object has a method 
     protected void setProperties (Object bean, Map <String, Object>
parameters) throws Exception
It is necessary to repeat this method in DefaultEndpoint.

Why is that? Used factory EndpointHelper owes its name to the tune
DefaultEndpoint.

FtpEndpoint is created by setting the parameter component.

replace the line
103:   IntrospectionSupport.setProperties (client, ftpClientParameters);
111:   IntrospectionSupport.setProperties (ftpClientConfig,
ftpClientConfigParameters);
the challenge of the new method
103:   setProperties (client, ftpClientParameters);
111:   setProperties (ftpClientConfig, ftpClientConfigParameters);




--
View this message in context: http://camel.465427.n5.nabble.com/FTP-over-Proxy-tp3314841p5742147.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: FTP over Proxy

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

Sounds like a good idea to support this out of  the box in camel-ftp.
You are welcome to submit a patch with your enhancement in the
camel-ftp component.


On Mon, Oct 21, 2013 at 2:00 PM, alexey-s <al...@mail.ru> wrote:
> Good afternoon.
>
> Let's go back to the history of the issue. The discussion was offered
> functionality https://issues.apache.org/jira/browse/CAMEL-3845
>
> Check the description FTPS component in http://camel.apache.org/ftp2.html
> SFTP component uses this functionality.
>
> What prevents the FTP component to pass through a proxy?
> FtpEndpoint creates commons-net FTPClient.
>
> GenericFileComponent create endpoint
> endpoint = buildFileEndpoint (uri, remaining, parameters);
>
> After creating the endpoint initialization of parameters
>         setProperties(endpoint, parameters);
>
> The main component, commons-net FTPClient, not configurable.
> We need to manually set SocketFactory.
>
> It would be logical to make the identification of parameters for ftpClient
>    ftpClient.socketFactory=#soketFactory
>    ftpClient.proxy=#proxy
>
> I posted on GitHub implementation of the system passing proxy.
>    https://github.com/alexey-su/camel-ftpext
>
> This component recognizes the parameter ftpClient.proxyUrl
> When you create an endpoint sets the desired soketFactory.
>
> Examples
>
> ftpext://publicftpserver.com/download?ftpClient.proxyUrl=http://user:password@proxy.domain.lan:port/
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/FTP-over-Proxy-tp3314841p5741973.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: FTP over Proxy

Posted by alexey-s <al...@mail.ru>.
Good afternoon.

Let's go back to the history of the issue. The discussion was offered
functionality https://issues.apache.org/jira/browse/CAMEL-3845

Check the description FTPS component in http://camel.apache.org/ftp2.html
SFTP component uses this functionality.

What prevents the FTP component to pass through a proxy?
FtpEndpoint creates commons-net FTPClient.

GenericFileComponent create endpoint
endpoint = buildFileEndpoint (uri, remaining, parameters);

After creating the endpoint initialization of parameters
        setProperties(endpoint, parameters);

The main component, commons-net FTPClient, not configurable.
We need to manually set SocketFactory.

It would be logical to make the identification of parameters for ftpClient
   ftpClient.socketFactory=#soketFactory
   ftpClient.proxy=#proxy

I posted on GitHub implementation of the system passing proxy.
   https://github.com/alexey-su/camel-ftpext

This component recognizes the parameter ftpClient.proxyUrl
When you create an endpoint sets the desired soketFactory.

Examples
 
ftpext://publicftpserver.com/download?ftpClient.proxyUrl=http://user:password@proxy.domain.lan:port/



--
View this message in context: http://camel.465427.n5.nabble.com/FTP-over-Proxy-tp3314841p5741973.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: FTP over Proxy

Posted by davsclaus <ci...@yahoo.dk>.
If you found a bug in Apache commons Net, then I suggest to report to them
and provide the patch.

There has been a Commons Net 2.2 release. And Camel will by default use 2.0.
So we are considering upgrading. 

-----
Claus Ibsen
-----------------
FuseSource
Email: cibsen@fusesource.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.blogspot.com/
Author of Camel in Action: http://www.manning.com/ibsen/
--
View this message in context: http://camel.465427.n5.nabble.com/FTP-over-Proxy-tp3314841p4305494.html
Sent from the Camel - Users mailing list archive at Nabble.com.