Ask Your Question
0

File upload using HTTP POST method

asked 2020-07-27 12:22:04 -0500

Hi,

Is there a way we can upload file using HTTP POST to a REST endpoint and process response in streamsets? I tried looking for options using HTTP Client and could not find a proper way to POST multipart form data. Any way to use HTTP Client datacollector for the purpose mentioned above?

Thanks in advance :)

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2020-07-28 13:55:16 -0500

iamontheinet gravatar image

updated 2020-07-28 13:56:29 -0500

Hi!

You can send data of content type application/x-www-form-urlencoded, for example, name=${record:value('/name')}&id=${record:value('/id')}, but there's no way to "attach and upload" a file using HTTP Client stages.

Maybe you should look into creating one pipeline to copy/transfer the file using Whole File format via one of the supported stages and then create another pipeline to process the file.

Hope this helps.

Cheers, Dash

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2020-07-27 12:22:04 -0500

Seen: 13 times

Last updated: Jul 28