Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

using NIFI HttpListen Processor to get data from a webhook

avatar
Expert Contributor

1. I am trying to get data from

https://support.appsflyer.com/hc/en-us/articles/207034356-Push-APIs-Real-Time-Installation-and-Conve...

The page say:

NOTE: Push API only supports the use of port 80 and 443.

I believe I can use NIFI to stream data from a webhook. My question is how to run the HttpListen Processor on port 80 or 443. I tried putting these ports in there and that seems to not work.

Secondly, I tried posting to my small workflow in Nifi that has just two components httplistener and putHDFS.

It just shows the bytes stuck in the queue and not being written to hdfs.

Besides how do I run this on port 80 or 443 as these are the only two ports supported. Are there any other processors I could possibly use?

Any help me is appreciated

1 ACCEPTED SOLUTION

avatar
Master Mentor

@Simran Kaur

All ports 1024 and below are considered reserved as privileged ports and can be only used/bound to by process run by the root user.

NiFi can use these ports if it is running as the root user.

The alternative is to setup your ListenHTTP processor to run on a non privileged port and then set up port forwarding in your iptables to redirect incoming requests to a privileged port to that non privileged port you are using in NiFi:

iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports 8081

Thanks,

View solution in original post

1 REPLY 1

avatar
Master Mentor

@Simran Kaur

All ports 1024 and below are considered reserved as privileged ports and can be only used/bound to by process run by the root user.

NiFi can use these ports if it is running as the root user.

The alternative is to setup your ListenHTTP processor to run on a non privileged port and then set up port forwarding in your iptables to redirect incoming requests to a privileged port to that non privileged port you are using in NiFi:

iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports 8081

Thanks,