Support Questions
Find answers, ask questions, and share your expertise

NiFi - Output Port : Not able to enable the transmission of the output port

Contributor

Hi Below are the steps i followed to feed nifi flow file to an output port.

1.Drop an "ExecuteProcess" Processor to canvas [or you can use TailFile Processor] to read lines added to "nifi-app.log". Auto Terminate relationship Failure.
2.Drop an OutputPort to the canvas and Name it 'spark', Once added, connect "ExecuteProcess" to the port for Success relationship.

Im not able to enable the transmission of the output port .Have i missed anything?

Please see the attached :

.nifisparkreciever.png.39545-nifisparkreciever.png

Using Nifi Open Source version 1.3.0

1 ACCEPTED SOLUTION

Accepted Solutions

Re: NiFi - Output Port : Not able to enable the transmission of the output port

Super Guru

@manisha jain,

Output port only transfers the data from a process group to Outside processors(or) processor groups.

Can you add an Processor Group and use these two processors inside Processor Group then you can enable transmission from Output port.

Flow:-

40593-op-flow.png

Inside the processor group keep all your processors.

40594-pg-op.png

View solution in original post

8 REPLIES 8

Re: NiFi - Output Port : Not able to enable the transmission of the output port

Super Guru

@manisha jain,

Output port only transfers the data from a process group to Outside processors(or) processor groups.

Can you add an Processor Group and use these two processors inside Processor Group then you can enable transmission from Output port.

Flow:-

40593-op-flow.png

Inside the processor group keep all your processors.

40594-pg-op.png

View solution in original post

Re: NiFi - Output Port : Not able to enable the transmission of the output port

Contributor

Hi @Shu

I did , Please see the attachment.

but still i do not see the transmission enabled for output port ,how do i verify its working ?outsideprocessor.pngwithin-processor.png

Re: NiFi - Output Port : Not able to enable the transmission of the output port

Super Guru

@manisha jain,

In process group there are ExecuteProcess and Output port once you will push the data out from output port.

We need to get this data that got pushed out from output port by using

1.Processor

2.Another Processor Group

3.Remote Processor Group

Output port not having capability to transmit data outside of process group, we need to use Output port only inside of Process Group to push data out of PG.

40598-pg-op.png

Here i have used output port inside Process Group1 and connected Output port to

1. UpdateAttribute Processor

you can use any other processors that will allows incoming connections in place of Update Attribute Processor.

2. Another Processor Group

In this group you need to have input port that gets data from Output port in PG1.

Processors in PG2 :-

40599-pg2.png

We need to use Input port inside PG2 to get the data from Output port.

3. RemoteProcessorGroup

This is the only ways that you can get the data that got pushed from output port, if the output (or) input ports are not inside the PG then it will not transmit or receive any data.

Re: NiFi - Output Port : Not able to enable the transmission of the output port

Explorer

Hi Shu,

Sorry to re-open this if it's already closed. Wanted to get your help to know where am I going wrong. I followed your steps however I am getting below error while I connect Process Group1 with RPG. I have an output port in PG1.

93646-1.png

Re: NiFi - Output Port : Not able to enable the transmission of the output port

Master Guru

@Bharat Yadav

ONLY Input and output ports created at root canvas level are considered remote. You will notice port box rendering looks a little different when added at root level (small wifi looking kind of symbol). These "remote" versions of the input/output ports will give you the option to authorize which clients the port can "receive data via site-to-site" on.

Re: NiFi - Output Port : Not able to enable the transmission of the output port

Explorer

@Matt Clarke @Shu

Thanks for you quick response Matt. Yes you are correct. It's working now. However I did not understood, unless I create a outport in PG1 I am unable to create a connection at root level to another PG2 via outport. Any idea why is that so?

Re: NiFi - Output Port : Not able to enable the transmission of the output port

Expert Contributor

If your goal is to send data into Spark, you'll need to use one of the mechanisms that Spark accepts to do so. You could write to Kafka, persistent disk such as HDFS, use a port, etc. There are many ways to get data to Spark.

What you are using, the output port, is for processor groups. With the use of an output port inside of a processor group, you can link the processor group to something downstream and it will feed data from the output port down to the next processor.

Re: NiFi - Output Port : Not able to enable the transmission of the output port

Contributor

Hi @anarasimham

Thanks for your response.

Goal is to get data into spark using output port mechanism ,as shown in the link below:

https://community.hortonworks.com/articles/12708/nifi-feeding-data-to-spark-streaming.html

If there is any other way to achieve ,please do share .. Any pointers would be helpful.