Re: DistributedMapCacheClient Groovy example

2016-07-17 Thread Sumanth Chinthagunta
Added Jira https://issues.apache.org/jira/browse/NIFI-2299 Thanks -Sumo > On Jul 17, 2016, at 4:56 AM, Matt Burgess wrote: > > Adding API JARs to the scripting NAR is a good idea since it extends the > capabilities as

Re: DistributedMapCacheClient Groovy example

2016-07-17 Thread Matt Burgess
Adding API JARs to the scripting NAR is a good idea since it extends the capabilities as you have shown. Mind writing an improvement Jira to capture this? Thanks, Matt > On Jul 17, 2016, at 4:51 AM, Sumanth Chinthagunta wrote: > > I had to custom build NiFi to add

Re: DistributedMapCacheClient Groovy example

2016-07-17 Thread Sumanth Chinthagunta
I had to custom build NiFi to add distributed-cache support for scripting processors as described here: https://github.com/xmlking/mapr-nifi-hadoop-libraries-bundle/blob/master/nifi-mapr-build.md#add-optional

Re: DistributedMapCacheClient Groovy example

2016-07-16 Thread Sumanth Chinthagunta
Hi Matt, Did you find any solution to use DistributedMapCacheClientService from Scripting processors ? I tried to use module directory with nifi-sumo-common-0.7.0-SNAPSHOT-all.jar bundling with org.apache.nifi:nifi-distributed-cache-client-service-api dependency here:

Re: DistributedMapCacheClient Groovy example

2016-07-14 Thread Matt Burgess
Sumo, That package won't be available to scripts because it is not available to ExecuteScript, that's what I meant about not being able to refer to the class directly :) Instead you can get a reference to the ControllerService by name, then just call methods even though you aren't directly

Re: DistributedMapCacheClient Groovy example

2016-07-13 Thread Sumanth Chinthagunta
Realized I also need to setup DistributedMapCacheClientService along with DistributedMapCacheServer. [ wonder how many instances service will be running in clustered env) but still looks for guidelines on how to make org.apache.nifi.distributed.cache.* available for ExecuteScript

Re: DistributedMapCacheClient Groovy example

2016-07-13 Thread Sumanth Chinthagunta
Matt, I setup DistributedMapCacheServer controller service and trying to run following script. Am I doing correct? I have couple of issues: 1. How do I make org.apache.nifi.distributed.cache.* package available for ExecuteScript? 2. When I try : cache.get("1",null,null), getting following

Re: DistributedMapCacheClient Groovy example

2016-07-13 Thread Sumanth Chinthagunta
Thanks Matt, If I create DistributedMapCacheServer controller service in NiFi cluster(two node) enveronment, will it create one instance of CacheServer or two? Sent from my iPhone > On Jul 13, 2016, at 6:13 PM, Matt Burgess wrote: > > Sumo, > > I have some example code

Re: DistributedMapCacheClient Groovy example

2016-07-13 Thread Matt Burgess
Sumo, I have some example code at http://funnifi.blogspot.com/2016/04/inspecting-your-nifi.html. Although it's not expressly for ExecuteScript it should be pretty usable as-is. Also you might be able to use the technique outlined in my other post:

DistributedMapCacheClient Groovy example

2016-07-13 Thread Sumanth Chinthagunta
looking for example script ( for ExecuteScript processor) that uses DistributedMapCacheClient to put/get key/value pair. Thanks -Sumo