From the course: Data Management with Apache NiFi
Unlock this course with a free trial
Join today to access over 25,500 courses taught by industry experts.
Configure the ReplaceText processor - Apache NiFi Tutorial
From the course: Data Management with Apache NiFi
Configure the ReplaceText processor
I need to make changes to this data flow. I'll just stop this data flow running first. Before we write out the data to our database table, we need to replace the na values with empty strings. And we'll do this with a separate processor. So I've gotten rid of the connection between getFile and putDatabase record. Let's add a new processor. And this processor is called replaceText. ReplaceText will allow you to replace the text within the content of your flow file with some other text of your choosing. Let's add this processor and make it part of our data flow. I'm going to connect the output of GetFile to ReplaceText. So on success, GetFile will send the flow file to ReplaceText, where we'll replace the NA values that exist in our numeric column. Double click on ReplaceText to bring up the dialog to configure this processor. First, scheduling. Now, you can have this run each time a flow file is available, but I'm only going to run replace text every 20 seconds. So we'll pause a bit…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
(Locked)
Set up a PostgreSQL table3m 41s
-
(Locked)
Add get file and put database processors3m 12s
-
(Locked)
Configure the CSV reader controller service3m 57s
-
(Locked)
Configure the DBCP connection pool controller service4m 37s
-
(Locked)
Run and encounter dataflow errors2m 48s
-
(Locked)
Configure the ReplaceText processor3m 5s
-
(Locked)
Run the dataflow to insert data into PostgreSQL2m 28s
-
(Locked)
Configure the run schedule3m 39s
-
(Locked)
Configure task concurrency3m 21s
-
(Locked)
-
-
-
-
-