Re: GenerateTable fetch throws error with MS SQL 2012+
Hi Matt, Does it means that all the other DBs(Oracle, MySQL, etc) might fetch duplicates rows with GenerateTableFetch? Thanks, Mohit On Thu, Aug 8, 2019 at 8:16 PM Matt Burgess wrote: > Mohit, > > MSSQL seems to have the only parser (of the more popular DBs) that > complains about an empty ORDER BY clause when doing paging (with > OFFSET / FETCH NEXT), so the default behavior is to throw an > exception. This happens when you don't supply a Max Value Column, > meaning you want to fetch all rows but haven't specified how to order > them, to ensure that each page gets unique rows and all rows are > returned. Otherwise each fetch could grab duplicate rows and some rows > may never be fetched, as the ordering is arbitrary. For some reason > other DBs (PostgreSQL, Oracle) lets you try it with the documented > caveat that the ordering is arbitrary. > > So an ordering must be applied, and to that end we added a Custom > ORDER BY Clause property [1] such that the user can provide their own > clause if no Max Value Column is specified. This property will be > available in the upcoming NiFi 1.10.0 release. The only workarounds I > know of are to use QueryDatabaseTable instead of GenerateTableFetch, > or to supply a Max Value Column property value in GenerateTableFetch. > > Regards, > Matt > > [1] https://issues.apache.org/jira/browse/NIFI-6348 > > On Thu, Aug 8, 2019 at 6:18 AM Mohit Jain wrote: > > > > Hi Team, > > > > I'm facing the following issue while using MS SQL 2012+. in Nifi 1.6.0 - > > > > GenerateTableFetch[id=87d43fae-5c02-1f3f-a58f-9fafeac5a640] > GenerateTableFetch[id=87d43fae-5c02-1f3f-a58f-9fafeac5a640] failed to > process session due to Order by clause cannot be null or empty when using > row paging; Processor Administratively Yielded for 1 sec: > java.lang.IllegalArgumentException: Order by clause cannot be null or empty > when using row paging > > > > It seems like a bug to me, is it resolved in the latest versions of Nifi? > > > > Thanks, > > Mohit > > > > > > > > > > >
SOLVED: NIFI 1.9.2 PutMongo Update An Existing Filed
This turned out to be pilot error because I had the wrong variable int the mongo collection field From: William Gosse Sent: Thursday, August 8, 2019 4:15 PM To: users@nifi.apache.org Subject: RE: NIFI 1.9.2 PutMongo Update An Existing Filed [CAUTION: This email originated from outside of Kodak Alaris. Do not click links or open attachments unless you recognize the sender and know the content is safe.] [WARNING: Potential spoofed mail] The sender of this email used an @kodakalaris.com email address, but the email did not come from a known Kodak Alaris email system. This email might not be legitimate. Delete this email unless it was sent from a known, trusted source. To avoid this notice if this email was sent from a known trusted source please submit an IT_KAre request to have this sender added as a valid email sender. Proofpoint rule module.access.rule.anti_spoofing_rule Message ID 2u8kp70xa9-1 2u8kp70xa9 I'm trying to get a PutMongo processor to preform an update on an existing field It the processor I have the following settings: Mode: update Upsert: false Update Query: {"resourceId" : ${resourceId}} Update Mode: With operators enabled Before I go into the PutMongo I do a ReplaceText to put my update operation in the content: Search Value: (?s)(^.*$) Replacement Value: {$set:{"documentId":"${documentId}"}} Replacement Strategy: Always Replace Evaluation Mode: Entire text Viewing the data providence shows me that this replacement is working correctly It's the first time I'm trying this so I'm totally open to the fact that I could be doing something wrong
RE: NIFI 1.9.2 PutMongo Update An Existing Filed
I'm trying to get a PutMongo processor to preform an update on an existing field It the processor I have the following settings: Mode: update Upsert: false Update Query: {"resourceId" : ${resourceId}} Update Mode: With operators enabled Before I go into the PutMongo I do a ReplaceText to put my update operation in the content: Search Value: (?s)(^.*$) Replacement Value: {$set:{"documentId":"${documentId}"}} Replacement Strategy: Always Replace Evaluation Mode: Entire text Viewing the data providence shows me that this replacement is working correctly It's the first time I'm trying this so I'm totally open to the fact that I could be doing something wrong
Re: GenerateTable fetch throws error with MS SQL 2012+
Mohit, MSSQL seems to have the only parser (of the more popular DBs) that complains about an empty ORDER BY clause when doing paging (with OFFSET / FETCH NEXT), so the default behavior is to throw an exception. This happens when you don't supply a Max Value Column, meaning you want to fetch all rows but haven't specified how to order them, to ensure that each page gets unique rows and all rows are returned. Otherwise each fetch could grab duplicate rows and some rows may never be fetched, as the ordering is arbitrary. For some reason other DBs (PostgreSQL, Oracle) lets you try it with the documented caveat that the ordering is arbitrary. So an ordering must be applied, and to that end we added a Custom ORDER BY Clause property [1] such that the user can provide their own clause if no Max Value Column is specified. This property will be available in the upcoming NiFi 1.10.0 release. The only workarounds I know of are to use QueryDatabaseTable instead of GenerateTableFetch, or to supply a Max Value Column property value in GenerateTableFetch. Regards, Matt [1] https://issues.apache.org/jira/browse/NIFI-6348 On Thu, Aug 8, 2019 at 6:18 AM Mohit Jain wrote: > > Hi Team, > > I'm facing the following issue while using MS SQL 2012+. in Nifi 1.6.0 - > > GenerateTableFetch[id=87d43fae-5c02-1f3f-a58f-9fafeac5a640] > GenerateTableFetch[id=87d43fae-5c02-1f3f-a58f-9fafeac5a640] failed to process > session due to Order by clause cannot be null or empty when using row paging; > Processor Administratively Yielded for 1 sec: > java.lang.IllegalArgumentException: Order by clause cannot be null or empty > when using row paging > > It seems like a bug to me, is it resolved in the latest versions of Nifi? > > Thanks, > Mohit > > > > >
Re: Custom Processor Upgrade
Thanks Mike and Bryan. Yes it seems my template was still referring the old version. I will have it updated now and will reimport. Also the version of NiFi we are using is the one that comes with CDF. I am not sure if CDF supports 1.9.2 yet or not. I will reach out to Cloudera and see if we can get it upgraded. On Thu, Aug 8, 2019, 8:51 AM Bryan Bende wrote: > What is in the template for the bundle coordinates of your processor? > and does that match the coordinates of the NAR that is deployed? > > Example: > > > org.apache.nifi > nifi-update-attribute-nar > 1.10.0-SNAPSHOT > > > If you made a new version of your NAR, say 2.0.0 and your template > references 1.0.0, then you'll need to update your template. > > On Wed, Aug 7, 2019 at 10:05 PM Mike Thomsen > wrote: > > > > If it's happening immediately upon trying to import the template, I > believe that's the error message saying that the 1.9 instance cannot find > the NAR file which provided the processor. Also, if you're referring to > 1.9.0 and not 1.9.2 you're going to want to upgrade to the latter because > there are a few critical bugs fixed in 1.9.2. > > > > On Wed, Aug 7, 2019 at 9:19 PM Bimal Mehta wrote: > >> > >> Thanks Bryan. > >> My custom processors are part of a template. However when I try to > import my template in NiFi 1.9, I get an error message saying > >> PutFeedMetadata is not known to this NiFi instance. I did update all > the dependencies to NiFi 1.9 and even the plugins. We are using a Cloudera > distributed version of NiFi 1.9. > >> Any idea why is this happening? > >> > >> Thanks > >> > >> > >> > >> On Wed, Aug 7, 2019 at 3:46 PM Bryan Bende wrote: > >>> > >>> Hello, > >>> > >>> Most likely your processor built against 1.6 would run fine in 1.9, > >>> but to make sure you just need to update any nifi dependencies in your > >>> poms to 1.9.2. > >>> > >>> If you created your project from the archetype and didn't change > >>> anything, then this should just be changing the parent in the root pom > >>> to the new version of nifi-nar-bundles. > >>> > >>> If you set it up yourself, then anywhere you depend on nifi-api you > >>> need to change. > >>> > >>> -Bryan > >>> > >>> On Wed, Aug 7, 2019 at 3:18 PM Bimal Mehta wrote: > >>> > > >>> > Hi, > >>> > > >>> > If we have a custom processor that was created with NiFi 1.6, what > are the steps we need to follow to make it work in 1.9? > >>> > Is there some sort of steps that explains the jar and pom updates we > need to do for making it work in 1.9? >
Re: Custom Processor Upgrade
What is in the template for the bundle coordinates of your processor? and does that match the coordinates of the NAR that is deployed? Example: org.apache.nifi nifi-update-attribute-nar 1.10.0-SNAPSHOT If you made a new version of your NAR, say 2.0.0 and your template references 1.0.0, then you'll need to update your template. On Wed, Aug 7, 2019 at 10:05 PM Mike Thomsen wrote: > > If it's happening immediately upon trying to import the template, I believe > that's the error message saying that the 1.9 instance cannot find the NAR > file which provided the processor. Also, if you're referring to 1.9.0 and not > 1.9.2 you're going to want to upgrade to the latter because there are a few > critical bugs fixed in 1.9.2. > > On Wed, Aug 7, 2019 at 9:19 PM Bimal Mehta wrote: >> >> Thanks Bryan. >> My custom processors are part of a template. However when I try to import my >> template in NiFi 1.9, I get an error message saying >> PutFeedMetadata is not known to this NiFi instance. I did update all the >> dependencies to NiFi 1.9 and even the plugins. We are using a Cloudera >> distributed version of NiFi 1.9. >> Any idea why is this happening? >> >> Thanks >> >> >> >> On Wed, Aug 7, 2019 at 3:46 PM Bryan Bende wrote: >>> >>> Hello, >>> >>> Most likely your processor built against 1.6 would run fine in 1.9, >>> but to make sure you just need to update any nifi dependencies in your >>> poms to 1.9.2. >>> >>> If you created your project from the archetype and didn't change >>> anything, then this should just be changing the parent in the root pom >>> to the new version of nifi-nar-bundles. >>> >>> If you set it up yourself, then anywhere you depend on nifi-api you >>> need to change. >>> >>> -Bryan >>> >>> On Wed, Aug 7, 2019 at 3:18 PM Bimal Mehta wrote: >>> > >>> > Hi, >>> > >>> > If we have a custom processor that was created with NiFi 1.6, what are >>> > the steps we need to follow to make it work in 1.9? >>> > Is there some sort of steps that explains the jar and pom updates we need >>> > to do for making it work in 1.9?
GenerateTable fetch throws error with MS SQL 2012+
Hi Team, I'm facing the following issue while using MS SQL 2012+. in Nifi 1.6.0 - *GenerateTableFetch[id=87d43fae-5c02-1f3f-a58f-9fafeac5a640] GenerateTableFetch[id=87d43fae-5c02-1f3f-a58f-9fafeac5a640] failed to process session due to Order by clause cannot be null or empty when using row paging; Processor Administratively Yielded for 1 sec: java.lang.IllegalArgumentException: Order by clause cannot be null or empty when using row paging* It seems like a bug to me, is it resolved in the latest versions of Nifi? Thanks, Mohit
Re: Unable to login to secured nifi cluster via UI
Thanks Pierre. On Wed, Aug 7, 2019 at 5:51 PM Pierre Villard wrote: > Hi Mohit, > > The initial admin you configured is the user you should use for the first > connection in order to grant authorizations to additional users/groups. The > initial admin should have been automatically added in the > authorizations.xml file created during the first start of NiFi. > > Hope this helps, > Pierre > > Le mer. 7 août 2019 à 14:12, Mohit Jain a > écrit : > >> Hi team, >> >> I'm not able to open the nifi canvas in the secured NiFi. It shows the >> following error message once I provides the credentials - >> *No applicable policies could be found. Contact the system administrator.* >> >> [image: image.png] >> Kindly help. >> >> Thanks, >> Mohit >> >>