Pushed a PR for this. On Thu, Aug 23, 2018 at 9:23 PM Mike Thomsen <[email protected]> wrote:
> Ryan, > > Didn't see you put out a pull request in the last two weeks. Let me know > if you're actively working this, if not I can do my own patch. > > Thanks, > > Mike > > On Wed, Aug 8, 2018 at 6:03 AM Mike Thomsen <[email protected]> > wrote: > >> Yes. Use a custom validator. >> >> On Tue, Aug 7, 2018 at 1:58 PM Ryan Hendrickson < >> [email protected]> wrote: >> >>> Yea, just finished testing, it works.. I added an additional property >>> called "Date Format" and I passed in a java date format there. Now I'm >>> just wondering if there's a way to validate it's a good date format before >>> it tries to use it when it's passing docs through. Maybe a custom >>> validator? >>> >>> Ryan >>> >>> On Tue, Aug 7, 2018 at 1:53 PM Ryan Hendrickson < >>> [email protected]> wrote: >>> >>>> Haha, yea I'm testing out some code-hacking here to see what I can do >>>> too. If it works, I can try to submit a Pull Request for it. I haven't >>>> done one before, and this seems pretty easy to make it configurable. >>>> >>>> Ryan >>>> >>>> On Tue, Aug 7, 2018 at 1:48 PM Mike Thomsen <[email protected]> >>>> wrote: >>>> >>>>> Annnndd, I should have read your comment on the Jira ticket because >>>>> it's even easier than that! >>>>> >>>>> On Tue, Aug 7, 2018 at 1:47 PM Mike Thomsen <[email protected]> >>>>> wrote: >>>>> >>>>>> I just checked the code, and it's using the default Jackson mapping >>>>>> behavior for that. The Mongo driver returns a Date, and looks like >>>>>> Jackson >>>>>> is just turning that into an ISO8601 string without that level of >>>>>> precision. A custom mapper for Date objects should be able to solve that. >>>>>> I'll work it when I get some free time from the daily grind. >>>>>> >>>>>> Thanks, >>>>>> >>>>>> Mike >>>>>> >>>>>> On Tue, Aug 7, 2018 at 12:55 PM Ryan Hendrickson < >>>>>> [email protected]> wrote: >>>>>> >>>>>>> Hi all, >>>>>>> I'm using GetMongo configured with JSON Type of "Standard JSON". >>>>>>> The document I've got in Mongo has a date field that looks like the >>>>>>> following: >>>>>>> { >>>>>>> ... >>>>>>> "date" : ISODate("2018-08-06T16:20:10.912Z" >>>>>>> ... >>>>>>> } >>>>>>> >>>>>>> When GetMongo spits it out, the date comes out as: >>>>>>> "2018-08-06T16:20:10Z", noticeably missing the milliseconds. >>>>>>> >>>>>>> I've created a bug ticket here: >>>>>>> https://issues.apache.org/jira/browse/NIFI-5495. >>>>>>> >>>>>>> I'm not sure if there's a work around or anything like that. If >>>>>>> anyone else has suggestions to either add back the missing milliseconds, >>>>>>> even if it's just tagging on ".000" to get the format back, I'm all >>>>>>> ears. >>>>>>> >>>>>>> Thanks, >>>>>>> Ryan >>>>>>> >>>>>>
