Created 02-18-2020 01:35 AM
move a file from:
EX - http://77.17.6.166/tls/file/nn.csv
to: hostname:77.17.6.122
remote directory - /tls/file
and rename as hello.csv
guide me with processor an there respective configuration
Created 02-25-2020 11:20 AM
You can use the invokeHTTP processor to fetch your file. Here is an example:
The above example fetches the Apache nifi-toolkit-1.11.3-bin.tar.gz file.
You can then construct a dataflow using other processors to manipulate as you want or simply just connect to another invokeHTTP processor that instead of "GET" uses "PUT" to put your file "nn.csv" at the new http endpoint.
Hope this helps you,
Matt
Created on 02-18-2020 05:29 AM - edited 02-18-2020 05:32 AM
First we need to asks questions to better understand the http cloud endpoint:
How do you currently accomplish this task outside of NiFi?
Is it possible to connect via a terminal/command prompt to get the file from the http cloud server?
Does the http cloud service have a rest-api for getting data from it?
My first thought would be the invokeHTTP processor to get your file from the http cloud server...
Then use an UpdateAttribute processor to change the "filename" attribute value on the NiFi FlowFile created by the invokeHTTTP processor...
You did not mention what you want to do with this file once you have retrieved it ad renamed it in NiFi. Are you trying to write it back to the same http cloud service? Are you trying to write the file to another service/endpoint? Are you writing it to a local directory?
Then we can start to look at what processors NiFi may have available to accomplish the same methods.
Hope this helps get you started,
Matt
Created 02-18-2020 10:22 PM
Created 02-25-2020 11:20 AM
You can use the invokeHTTP processor to fetch your file. Here is an example:
The above example fetches the Apache nifi-toolkit-1.11.3-bin.tar.gz file.
You can then construct a dataflow using other processors to manipulate as you want or simply just connect to another invokeHTTP processor that instead of "GET" uses "PUT" to put your file "nn.csv" at the new http endpoint.
Hope this helps you,
Matt
Created 02-19-2020 09:37 AM
You may use below commands for this.
wget http://77.17.6.166/tls/file/nn.csv
scp nn.csv username@77.17.6.122:/tls/file/hello.csv
Created 02-19-2020 09:43 PM
this is shell scripting i need to do this in nifi