[
https://issues.apache.org/jira/browse/NIFI-4747?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16316631#comment-16316631
]
Julian Gimbel commented on NIFI-4747:
-------------------------------------
I understand that when we execute the processor and the folder does not exist
it needs to throw an error. But I guess there are several use cases where the
folder contains the date and is only created once the new data is available.
Therefor this processor throws more errors then necessary and imho it would be
better to evaluate the path only when the processor is really supposed to run.
If that is not possible it would be fine to evaluate the path once when the
processor is stored and not all the time that it is in running mode but not
really scheduled. What do you think?
> GetHDFS Scheduling via CRON shows an error before it is scheduled
> -----------------------------------------------------------------
>
> Key: NIFI-4747
> URL: https://issues.apache.org/jira/browse/NIFI-4747
> Project: Apache NiFi
> Issue Type: Bug
> Components: Core Framework
> Affects Versions: 1.2.0, 1.4.0
> Environment: Linux, Windows
> Reporter: Julian Gimbel
> Priority: Blocker
> Attachments: gethdfs_cron_scheduling.PNG,
> gethdfs_cron_scheduling_error.png
>
>
> We schedule a getHDFS Processor CRON driven at "0 0 15 * * ?" so that it
> should run at 15:00:00 every day. If we start the processor it gives an error
> message even before CRON should have triggered the Processor as shown below.
> The question is why that is happening and how can it be fixed?
> 2018-01-08 14:43:01,242 ERROR [StandardProcessScheduler Thread-5]
> o.a.n.controller.StandardProcessorNode Failed to invoke @OnScheduled method
> due to java.lang.RuntimeException: Failed while executing one of processor's
> OnScheduled task.
> java.lang.RuntimeException: Failed while executing one of processor's
> OnScheduled task.
> at
> org.apache.nifi.controller.StandardProcessorNode.invokeTaskAsCancelableFuture(StandardProcessorNode.java:1483)
> at
> org.apache.nifi.controller.StandardProcessorNode.access$000(StandardProcessorNode.java:103)
> at
> org.apache.nifi.controller.StandardProcessorNode$1.run(StandardProcessorNode.java:1302)
> at
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
> at java.util.concurrent.FutureTask.run(FutureTask.java:266)
> at
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
> at
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
> at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> at java.lang.Thread.run(Thread.java:745)
> Caused by: java.util.concurrent.ExecutionException:
> java.lang.reflect.InvocationTargetException
> at java.util.concurrent.FutureTask.report(FutureTask.java:122)
> at java.util.concurrent.FutureTask.get(FutureTask.java:206)
> at
> org.apache.nifi.controller.StandardProcessorNode.invokeTaskAsCancelableFuture(StandardProcessorNode.java:1466)
> ... 9 common frames omitted
> Caused by: java.lang.reflect.InvocationTargetException: null
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:498)
> at
> org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotations(ReflectionUtils.java:137)
> at
> org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotations(ReflectionUtils.java:125)
> at
> org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotations(ReflectionUtils.java:70)
> at
> org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotation(ReflectionUtils.java:47)
> at
> org.apache.nifi.controller.StandardProcessorNode$1$1.call(StandardProcessorNode.java:1306)
> at
> org.apache.nifi.controller.StandardProcessorNode$1$1.call(StandardProcessorNode.java:1302)
> ... 6 common frames omitted
> Caused by: java.io.IOException: PropertyDescriptor
> PropertyDescriptor[Directory] has invalid value
> /nifi/pele/pele2rtdp/20180108. The directory does not exist.
> at
> org.apache.nifi.processors.hadoop.GetHDFS.onScheduled(GetHDFS.java:242)
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)