- Subscribe to RSS Feed
- Mark Question as New
- Mark Question as Read
- Float this Question for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
InvokeHTTP write a property on Failure Condition
- Labels:
-
Apache NiFi
Created ‎06-03-2019 01:40 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am working on a NIFI flow that begins with an InvokeHTTP processor.
On the occasion that there is a connection timeout (Failure condition), I wish to assign the InvokeHTTP processor Remote URL value to a new property and have this property passed as data (attribute) through the "Failure" path to another processor. Is it possible to do within the same InvokeHTTP processor?
Can anyone help?
Created ‎06-19-2019 11:34 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I solved this by using a GenerateFlowFile processor to create an attribute url and to trigger the InvokeHTTP processor at the schedule rate of interest.
On a failure condition (e.g. InvokeHTTP connection timeout) I use an UpdateAttribute processor to assign to the attribute url the Remote URL using a Regex: ${invokehttp.java.exception.message:substringAfterLast('/'):substringBefore(':')}
Created ‎06-19-2019 11:34 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I solved this by using a GenerateFlowFile processor to create an attribute url and to trigger the InvokeHTTP processor at the schedule rate of interest.
On a failure condition (e.g. InvokeHTTP connection timeout) I use an UpdateAttribute processor to assign to the attribute url the Remote URL using a Regex: ${invokehttp.java.exception.message:substringAfterLast('/'):substringBefore(':')}
