nifi-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bryan Bende <bbe...@gmail.com>
Subject Re: flowfile through invokehttp put
Date Thu, 16 May 2019 14:47:53 GMT
Normally this would all be handled for you with site-to-site, but not
sure that can be made to work with your custom proxy. Before
site-to-site there was PostHttp and ListenHttp, and PostHttp has an
options for "Send As Flow File". PostHTTP is marked as deprecated
because generally you should use site-to-site or InvokeHttp, but
InvokeHttp doesn't have the send as flow file concept. So you could
try using PostHttp as long as you realize its deprecated, and maybe
someone can add the send as flow file concept to InvokeHttp, or maybe
a PackageContent processor.

The only other option I can think of is to use MergeContent with the
Merge Format set to "FlowFile Stream v3" and configure the max and min
entries to 1 so it doesn't really actually merge anything, but just
writes out the new flow content. On the receiving side use
UnpackContent also configured with format as "FlowFile Stream v3".

On Thu, May 16, 2019 at 10:18 AM Michael Di Domenico
<mdidomenico4@gmail.com> wrote:
>
> i'm pretty new to nifi, so i'm not sure this worded correctly or
> possible.  i have a flow which ends with an invokehttp process that
> does a PUT to web server.
>
> my naive understanding of this process is that when the flowfile hits
> invokehttp, the flow-attributes can be sent as key:value pairs via the
> http headers and the file-content gets PUT to the remote webserver via
> the http content-body
>
> is there a way to send the flow-attr and the flow-content (ie the
> entire flowfile) via the PUT?
>
> i have nifi on two ends of a connection, but in order to send the data
> from one to another i have to send it through a proxy like device.
> the near end of the device receives data from the PUT and far end does
> a POST to a remote nifi.
>
> this process works fine, but on the far end i only receive the file
> and none of the attributes (as expected).  i cannot configure the
> proxy device to pass key:value pairs in the http headers.  i'm
> presuming all the flow information would have to be sent via the PUT
> and then decoded by the nifi server on the far end.  i'm hoping
> there's a simple connector to do this rather then having me munge all
> the data together into something like an xml or json file and send
> that.

Mime
View raw message