Re: Expression language - Convert ISO 8601 to unixtimestamp

2018-12-03 Thread Kevin Doran
Hi Faisal, Out of curiosity, does the upstream system(s) guarantee that these timestamps will be unique, even at the microsecond level? (I’ve seen some systems that write a “microsecond precision” which is really just a millisecond value + a sub-millisecond value that increments every time it

Re: Expression language - Convert ISO 8601 to unixtimestamp

2018-12-03 Thread Faisal Durrani
Hi Kevin, Thank you for your mail and suggestions. I was also able to achieve the same by using the below expression ${current_ts:substring(0,19):toDate("-MM-dd'T'HH:mm:ss","UTC"):toNumber():plus(${current_ts:substring(20,23)})} So I am taking out the millisecond part of the microsecond

Re: CSV -> nested JSON

2018-12-03 Thread Mike Thomsen
Attaching a copy of a sample flow for anyone that comes along with a similar question... On Mon, Dec 3, 2018 at 12:29 PM Matt Burgess wrote: > Mike, > > I'm looking into whether this is possible with UpdateRecord or not. > For the article you mentioned, the OP wanted to nest values into a >

Re: CSV -> nested JSON

2018-12-03 Thread Matt Burgess
Mike, I'm looking into whether this is possible with UpdateRecord or not. For the article you mentioned, the OP wanted to nest values into a record that didn't exist in the input. Not sure if that's technically the same as your case but could be. In the meantime this Jolt spec should work with

Re: Expression language - Convert ISO 8601 to unixtimestamp

2018-12-03 Thread Kevin Doran
Hi Faisal, It appears whatever is writing these date strings that you have for inputs is writing microseconds, not milliseconds, So when you are using `.SS`, that is, in this case `937000` microseconds being interpreted by the expression language java parser as 937000 milliseconds (15

Re: CSV -> nested JSON

2018-12-03 Thread Mike Thomsen
Looks like I missed this: https://community.hortonworks.com/questions/212877/want-to-convert-csv-to-nested-json-using-nifi.html I'll get crackin on Jolt since that seems to be the best answer at the moment. On Mon, Dec 3, 2018 at 11:24 AM Mike Thomsen wrote: > We have a need to be able to

CSV -> nested JSON

2018-12-03 Thread Mike Thomsen
We have a need to be able to take a CSV file and convert it into a nested JSON structure. I did a simple test with GenerateFlowFile and a few ConvertRecord processors. Test was: GenerateFlowFile (JSON) -> ConvertRecord (JSON in, CSV out) -> ConvertRecord (CSV in, JSON out) and it threw an

Re: Load Balancing connection issue

2018-12-03 Thread dan young
We've been seeing issues , three times now, where it seems like a flowfile is stuck in a load balanced queue. We're not able to empty the queue or view the flowfile that appears to be in the queue. The only resolution for use right now is to detach the node where the Flowfile is in the queue, then

Re: Load Balancing connection issue

2018-12-03 Thread Mark Payne
Hi Kien, Thanks for the details! Can you tell us a bit more about how the Connection is configured? What is the Load Balance Strategy that you're using? Do you have Back-Pressure enabled? Is it configured for the default 10,000 FlowFiles / 1 GB, or have you changed those settings? Are you

Load Balancing connection issue

2018-12-03 Thread Kien Truong
Hi all, We're testing the new load-balance connection feature of NIFI 1.8. After some cluster-wide restarts, some connections with load-balancing enabled seem to stuck. The connection is always shown as actively balancing, however, the size of the queue show very little changes, also the