eric can you please file a JIRA to reflect the awkward process you had to go through so we can improve it.
Thanks On Sun, Nov 5, 2017 at 9:37 AM, Eric Chaves <e...@uolet.com> wrote: > Ok, I managed to make to make it work. I had to add "log.dir=./logs" to > bootstrap.conf file in order to have the logs generated. I got a little lost > because this property is not mentioned at the docs but I could figured it > out reading the logback.xml > > Once the logs began to be generated I could see that an exception was being > raised in my scripts because I was trying to access "log" which does not > seem to be available in Service controllers. Once I removed the offending > log line, the code worked. Bottom line my attempt to debug the code was > actually breaking it. ;) > > Thanks! > > 2017-11-05 12:14 GMT-02:00 Mike Thomsen <mikerthom...@gmail.com>: >> >> They go to logs/nifi-app.log. I think <logger >> name="org.apache.nifi.processors" level="INFO"/> is actually WARN by >> default. You'll need to tinker with the log levels (it's not straight >> enable/disable) to get that working. >> >> On Sun, Nov 5, 2017 at 8:54 AM, Eric Chaves <e...@uolet.com> wrote: >>> >>> Hi Mike, I'm running nifi using the official docker image (version 1.4.0) >>> and my logs folder is empty. I was looking at bootstrap.conf, logback.xml >>> and nifi.properties but couldn't found any config value that may >>> disable/enable log. Where should those logs be going? >>> >>> 2017-11-04 12:55 GMT-02:00 Mike Thomsen <mikerthom...@gmail.com>: >>>> >>>> You may need to update the logback xml file in the conf folder. There is >>>> a line in there for the processor package. Might be too high for info. >>>> >>>> On Sat, Nov 4, 2017 at 10:50 AM Eric Chaves <e...@uolet.com> wrote: >>>>> >>>>> Hi folks, >>>>> >>>>> I'm trying to adapt the flow described at >>>>> https://community.hortonworks.com/articles/138632/data-flow-enrichment-with-nifi-lookuprecord-proces.html >>>>> using ScriptedLookupService as replacement for SimpleKeyValueLookupService >>>>> to lookup city names and enrich and incoming record. >>>>> >>>>> When I ran the flow with KeyValueLookupService the field gets enriched >>>>> properly but when I use my scriptedlookup the value always come back as >>>>> null. The script was pretty simple and I can't figure out where is my >>>>> error. I also tried the ScriptLookup (just the script, not the flow) by >>>>> AloPresto at >>>>> https://gist.github.com/alopresto/78eb1a2c2b878f75f61481269af38a9f with >>>>> the >>>>> same resutls. >>>>> >>>>> I'm trying to log.info the execution to figure out my mistakes but the >>>>> logs are going nowhere. How can I enable logging for services? >>>>> >>>>> Does anyone spot an error? >>>>> >>>>> ---[service-lookup.groovy]--- >>>>> import org.apache.nifi.lookup.StringLookupService >>>>> >>>>> class GroovyLookupService implements StringLookupService { >>>>> >>>>> def lookupTable = [ >>>>> '1': 'Paris', >>>>> '2': 'Lyon', >>>>> '3': 'Marseille', >>>>> '4': 'Toulouse', >>>>> '5': 'Nice' >>>>> ] >>>>> >>>>> @Override >>>>> Optional<String> lookup(final String key) { >>>>> log.warn('key value: ', key) >>>>> return Optional.ofNullable(lookupTable[key]) >>>>> } >>>>> } >>>>> >>>>> lookupService = new GroovyLookupService() >>>>> --- >>>>> >>> >> >