Find answers, ask questions, and share your expertise
Recently active
Hi, Guys. I am new to use NiFi flow. I am kind of confused about Query database table processor. So now, I am try to get all data from Postgres database and convert them into json and then convert them into xml.But sometimes, the Query database table processor will have a lot of Flow file and then the queue just mess up. I try to set the art_id to be maximum-value column but it doesn't work well because art_id is string.(not sure)This is a screenshot from a sample table called title and it has about 500 rows. How to query them just one time and split them into 500 flowfile and each of flowfile has only one row from table title without any duplicates. Can someone help me?Thank you so much. Following screenshots are my progress so far.
Hii Everyone, I've been struggling to achieve the desired result with a Jolt transformation for the past few days and could really use some help from the community. input.json: { "email": "abcmail@gmail.com", "dates": [ { "date": "2023-12-01", "type": "full" }, { "date": "2023-11-03", "type": "full" }, { "date": "2023-11-02", "type": "full" }, { "date": "2023-10-01", "type": "half" } ]} output.json [ { "emailId": "abcmail@gmail.com", "date": "2023-12-01", "type": "full" }, { "emailId": "abcmail@gmail.com", "date": "2023-11-03", "type": "full" }, { "emailId": "abcmail@gmail.com", "date": "2023-11-02", "type": "full" }, { "emailId": "abcmail@gmail.com", "date": "2023-10-01", "type": "half" }] spec file for the transformation: [ { "operation": "shift", "spec": { "*": { "email": "[].emailId", "dates": { "*": {
Hello guys,I'm struggling with JsonRecordSetWriter 1.17.0, we have valid nested JSON data, but for some reason whenever this data passes through JsonRecordSetWriter, on nested arrays it adds the following : "orderItemsCustomizes" : [ "MapRecord[{quantity=1, itemCurrency=AED, totalPrice=0, orderItemId=2767, itemCustomizeGroup=MapRecord[{itemModifierGroupAttributes=[Ljava.lang.Object;@4658e00e, customizeGroupName=Burger Selection}], itemCustomize=MapRecord[{itemCustomizeGroupId=2308, itemId=18622, itemName=Chicken Burger, isAvailabel=true, updated_at=2023-01-27 15:59:31, itemCurrency=AED, itemCost=0.00, created_at=2023-01-27 15:59:31, itemModifierAttributes=[Ljava.lang.Object;@ee87ab1, id=7539, itemImage=https://d2cvcbugmdflrn.cloudfront.net/e777bb72-a445-4162-9844-f9bda5e7a3d0.jpg}], itemId=18622, itemCustomizeGroupId=2308, createdAt=2023-01-27 16:48:02, itemCustomizeId=7539, price=0.00, ID=1153, updatedAt=2023-01-27 16:48:02}]", "MapRecord[{quantity=1, itemCurrency=AED
Hi ,In Apache NIFI I am consuming data from one Kafka topic and publishing that data to customers Kafka topic . For this i am using ConsumeKafka and PublishKafka processor respectively.If outgoing dataflow is idle for more than 5 minutes, the Kafka connection with customer should be terminated and reconnected when there is any new messages consumed .how to do this with publish kafka processor ?? how to terminate and start the connection??
I am using ExecuteSQL to pull a colb column from DB. ExecuteSQL provides the result in the avro format. Then I am converting that to Json using AvroToJsonProcessor but it is adding escape characters. I want the value that is being pulled from DB as a Json but I am getting it as a string with escape characters. [ { "SEARCH_RESULT": "{ \"requestId\": \"203680\", \"responseData\": [ { \"searchKey\": \"cardNumber\", \"data\": [ { \"firstName\": \"Martin\", \"lastName\": \"Garry\" }, { \"firstName\": \"Martin\", \"lastName\": \"Garry\"}, { \"firstName\": \"Martin\", \"lastName\": \"Garry\", } ] } ] }" }]I want that value of Search result to be a Json instead of a String so that I can use JOLT to transform it as needed. Can you someone pls suggest how to do it.
Himy backup is failing with following errors :23/11/30 10:08:58 ERROR backup.KuduBackup$: Failed to back up table impala::PPR_CURATED.ACTIVITEorg.apache.kudu.client.NonRecoverableException: Unauthorized actionat org.apache.kudu.client.KuduException.transformException(KuduException.java:110)at org.apache.kudu.client.KuduClient.joinAndHandleException(KuduClient.java:470)at org.apache.kudu.client.KuduClient.openTable(KuduClient.java:288)at org.apache.kudu.backup.KuduBackup$.org$apache$kudu$backup$KuduBackup$$doBackup(KuduBackup.scala:50)at org.apache.kudu.backup.KuduBackup$$anonfun$6$$anonfun$1.apply$mcV$sp(KuduBackup.scala:144)at org.apache.kudu.backup.KuduBackup$$anonfun$6$$anonfun$1.apply(KuduBackup.scala:144)at org.apache.kudu.backup.KuduBackup$$anonfun$6$$anonfun$1.apply(KuduBackup.scala:144)at scala.util.Try$.apply(Try.scala:192)at org.apache.kudu.backup.KuduBackup$$anonfun$6.apply(KuduBackup.scala:144)at org.apache.kudu.backup.KuduBackup$$anonfun$6.apply(KuduBackup.scala:143)at sca
HiWe've done a recent upgrade from Hive 1.1.0-cdh5.16.2 to Hive 3.1.3 and have noticed the difference in behaviour when no rows have been returned and file generation.On the older version (Hive 1.1.0-cdh5.16.2) it use to create empty part files (000000_0) whereas since the upgrade this isn't the case.The command to run this is beeline and the sql statement starts like:Insert overwrite directory 'some/path'ROW FORMAT DELIMITED FIELDS TERMINATED BY '|'I cannot find any definitive documentation to saw this behaviour does not exist in later versions like Hive 3.1.3Thanks
Hello,I'm running a sqoop job through Hue. This imports data from Oracle, but the value of --query is being divided by whitespace and produces sqoop flag error because it does not recognize these parametersimport --connect jdbc:oracle:thin:@server/service --query 'select * from mytable'The logs show somethng like this:Sqoop command arguments : import --connect jdbc:oracle:thin:@server/service --query 'SELECT * from mytable'-------------------------------------------------------------------------------------------------------17:48:29.329 [main] ERROR org.apache.sqoop.tool.BaseSqoopTool - Error parsing arguments for import:17:48:29.329 [main] ERROR org.apache.sqoop.tool.BaseSqoopTool - Unrecognized argument: select17:48:29.329 [main] ERROR org.apache.sqoop.tool.BaseSqoopTool - Unrecognized argument: *17:48:29.329 [main] ERROR org.apache.sqoop.tool.BaseSqoopTool - Unrecognized argument: from&nb
hi everyone ! hoping everybody has an awsome day.I am trying to create a process Group with a flow definition json i downloaded.when i upload a file.json manually and checked the nifi-request.log and the only i see is this pettiotion " http://localhost:8081/process-groups/{id}/process-groups/upload" but i don't see the body in sent request, i want to use the api rest to upload this file but documentation is not clear in this aspect pettition #1:curl --location "http://localhost:8082/nifi-api/process-groups/{id}/process-groups/upload" \--form "file=@/path/to/my/flowDefinition.json"Response: Process Group name is required pettition #2:curl --location "http://localhost:8082/nifi-api/process-groups/{id}/process-groups/upload" \--header 'Content-Type: multipart/form-data' \-F 'id=root' \-F 'name=QA_FLOW' \-F 'position[x]=577.0' \-F 'position[y]=11.0' \-F 'clientId=27bf6df2-018c-1000-362e-61166913eee4' \-F 'disconnectNode=true'-F "file=@/path/to/my/flowDefinition.jso
Hey there,we're running CDP Private Cloud Base in 7.1.9 in 4 different Stages (Lab, DEV, QA and Prod). Is it possible to add a banner in different colours to the different WebUIs so that we can always distinguish the stages well? Like changing the colours in Cloudera Manager?Thanks and Regards,Timo
Anyone have guide how to upgrade default Zeppelin in Ambari 2.7.4, i cant find it anywhereThanks in advance.
Hi , AllAfter we upgarding NiFi 1.9.2 to 1.22.0 (using cluster) , we found that ListFile will lost tracking. Just like @TimothySpann say.see: https://community.cloudera.com/t5/Support-Questions/NiFi-upgrade-1-9-2-to-1-23-0/m-p/376353#M242873Here is our ListFile setting :Listing Strategy Tracking EntitiesRecurse Subdirectories trueRecord Writer No value setInput Directory Location RemoteFile Filter [^\.].*Path Filter No value setInclude File Attributes trueMinimum File Age 1 minMaximum File Age No value setMinimum File Size 0 BMaximum File Size No value setIgnore Hidden Files trueTarget System Timestamp Precision Auto DetectEntity Tracking State Cache RedisDistributedMapCacheClientServiceEntity Tracking Time Window 365 daysEntity Tracking Initial Listing Target All AvailableEntity Tracking Node Identifier ${hostname()}Track Performance falseMaximum Number of Files to Track 1000
Hello, I have NiFi flow with EvaluateJsonPath that read a content of FlowFile with json to Data attribute. But numeric values of json are changed, i.e.:GenerateFlowFile{"Amount1": 999999999999999999.99,"Amount2": 999999999.99}->EvaluateJsonPathData $->Data{"Amount1":1.0E18,"Amount2":9.9999999999E8}How do I stop NiFi from rounding off and changing json numbers? Tested on NiFi 1.15/1.19.Thanks.
Hi ,In Apache NIFI I am consuming data from one Kafka topic and publishing that data to customer Kafka topic . For this iam using ConsumeKafka and PublishKafka processor respectively.If outgoing dataflow is idle for more than 5 minutes, the Kafka connection with customer should be terminated and reconnected when there is any new messages consumed .how to do this with publish kafka processor ??
I have a remote NIFI with single user authentication with Secured SSL certificate, I want to enable the site to site with remote NIFI from local NIFI,I am getting error like unauthorized in the remote process group of the local NIFI If I remove the authentication from the Remote NIFI, site to site is working properly and flow file is getting transferred to local NIFIcan someone help to make the site to site with user authentication
hi there,So I need your help with something. So I am extracting 4 columns out of a database. Out of these 4 columns, two columns are DATE in Oracle and I want to convert them into DATETIME (as they are going to be inserted into BigQuery). In addition to this, I am using an UpdateRecord to generate a new column and for that, I am using the following AVRO Schema:{"namespace": "example.avro","type": "record","name": "my_relevant_table","fields": [{"name": "ID_REQUEST","type": ["string","null"]},{"name": "ID_PROCESS","type": ["string","null"]},{"name": "ARCHIVE_DATE","type": ["null",{"type": "long","logicalType": "local-timestamp-millis"}]},{"name": "EXEC_DATE","type": ["null",{"type": "long","logicalType": "local-timestamp-millis"}]},{"name": "LOAD_DATE","type": ["null",{"type": "int","logicalType": "date"}]},]}Now, as you can imagine, I will encounter some null value within the ARCHIVE_DATE column, because this is a normal behavior. If I let the flow execute as it is, the AVRO File get's
Hi Team,I want to change the log level of the Hadoop security logger from INFO to ERROR. I've exported the following environment variable for thatexport HADOOP_NAMENODE_OPTS="-Dhadoop.security.logger=ERROR,RFA ${HADOOP_NAMENODE_OPTS}"I can see the new parameter has been reflected in the command linehdfs 13048 2.1 0.7 3899916 509000 ? Sl 01:22 0:29 /usr/lib/jvm/java-11-openjdk-amd64/bin/java -Dproc_namenode -Djava.net.preferIPv4Stack=true -Dhdfs.audit.logger=INFO,NullAppender -Dhadoop.security.logger=ERROR,RFA -Dyarn.log.dir=/var/log/hadoop-hdfs -Dyarn.log.file=hadoop-hdfs-namenode-hadoop-master-1.log -Dyarn.home.dir=/usr/lib/hadoop-yarn -Dyarn.root.logger=INFO,console -Djava.library.path=/usr/lib/hadoop/lib/native -Xmx2048m -Dhadoop.log.dir=/var/log/hadoop-hdfs -Dhadoop.log.file=hadoop-hdfs-namenode-hadoop-master-1.log -Dhadoop.home.dir=/usr/lib/hadoop -Dhadoop.id.str=hdfs -Dhadoop.root.logger=ERROR,RFA -Dhadoop.policy.file=hadoop-policy.xml org.apache.hadoop.hdfs.server.namenode.NameN
How to change Nifi logo in Nifi binary packages installed
I'm encountering occasional Exception when using PUTSQL processor in apache Nifi.I have already Increased innodb_lock_wait_timeout But I'm still encountering the error occasionally. How can I fix this error? And what are the optimal configurations when using putsql processor to insert large volume of records into mariadb?Variable_name;Valueinnodb_lock_wait_timeout;300Error Snippet:2023-11-24 18:04:45,837 ERROR [Timer-Driven Process Thread-51] o.apache.nifi.processors.standard.PutSQL PutSQL[id=c7255d17-018b-1000-143e-fc839881330c] Failed to update database due to a failed batch update, java.sql.BatchUpdateException: Lock wait timeout exceeded; try restarting transaction. There were a total of 1 FlowFiles that failed, 14 that succeeded, and 0 that were not execute and will be routed to retry;java.sql.BatchUpdateException: Lock wait timeout exceeded; try restarting transactionat com.mysql.cj.jdbc.exceptions.SQLError.createBatchUpdateException(SQLError.java:224)
I'm using NiFi to process .tar.gz files, extract the csv files, and upload them into S3. NiFi is currently running on a t2.large. I tested the same workflow on a t2.2xlarge, expecting an increase in performance. Yet, it didn't happen. In particular, it seems like the CompressContent and UnpackContent processors take the same amount of time, regardless of the instance type.Any idea of what I'm doing wrong or how to optimize performance?For the t2.large, I have concurrent tasks set to 2, while for the t2.2xlarge I have it set to 8. Execution on all nodes for both.Thanks
I want to set up a Nifi flow that gets data from a public RSS feed and loads it into a data lake. This RSS feed updates irregularly and when it does update it overwrites previous content. What processor(s) should I use to get data from the RSS feed (close to) when it has updated? Is it as simple as using InvokeHTTP repeatedly, checking for a change in output, then loading into data lake if the content differs from the previous invocation? Is there another way if I don't want to make the HTTP request so frequently?
Hello all, i am new to Nifi , i have Processor to InvokeHTTP and get json file ,the json format example:"{"alertDate":"2023-12-03 11:01:17","title":"XXXX","data":"XXXX, XXXX, XXXX","category":1}" "i am using the Processor ConvertJSONToSQL to send the data to PutSQL to insert to my sql data base ,my issue is :PutSQL Failed to update database for FlowFile due to The value of the sql.args.1.value is '2023-12-02 10:54:38', which cannot be converted to a timestamp" know i need to use the JoltTransformJSON but not sure what is the correct Jolt Specification i need to put,my DB columns are like this can you please help? - remember i am new to Nifi 🙂thanks a lot!
I tell you that we have updated Apache Nifi from version 1.16 to version 1.22 and we are currently having a problem connecting to the Mongo DB because the server version is very low.Is there an option that does not involve having to update the database server to be able to leave this connection functional?
Hey everyone, I want to fetch all databases and its records from CouchDB (NON-SQL) and then view all records in my Apache NiFi, after confirmation I want to send all records to my Server database.?I have not found processors of GetCouchDB. Share your thoughts that how we can do such process by using other processors ? Is there anyone to know about this process. #How to read all databases and its records from CouchDB and then by using Apache NiFi send all those records to my Server?
Hi all,The HDFS alerted that "Stale Configuration: Refresh needed" . I followed the suggestion, but i hesitated when the following image came out. I want to confirm that when i click "Restart Stale Configuration" button, the entire cluster will restart? Or only serveral servers will be restarted?
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.