Informatievlaanderen / VSDS-Linked-Data-Interactions

https://informatievlaanderen.github.io/VSDS-Linked-Data-Interactions/
European Union Public License 1.2
4 stars 6 forks source link

Starting url could not be determined for fragmentId #210

Closed sandervd closed 8 months ago

sandervd commented 1 year ago

Issue reported by @MPParsley

When ingesting this LDES: https://apidg.gent.be/opendata/adlib2eventstream/v1/dmg/tentoonstellingen The (NiFi wrapped) client throws the following error:

nifi-graph2  | 2023-06-08 12:53:45,794 ERROR [Timer-Driven Process Thread-6] b.v.i.ldes.processors.LdesClient LdesClient[id=120567ae-5a5b-3b4e-d1c4-b9d1b19d6aa2] Failed to properly initialize Processor. If still scheduled to run, NiFi will attempt to initialize and run the Processor again after the 'Administrative Yield Duration' has elapsed. Failure is due to java.lang.IllegalArgumentException: Starting url could not be determined for fragmentId: https://apidg.gent.be/opendata/adlib2eventstream/v1/dmg/tentoonstellingen?generatedAtTime=2023-03-25T01:54:08.069Z
nifi-graph2  | java.lang.IllegalArgumentException: Starting url could not be determined for fragmentId: https://apidg.gent.be/opendata/adlib2eventstream/v1/dmg/tentoonstellingen?generatedAtTime=2023-03-25T01:54:08.069Z
nifi-graph2  | at be.vlaanderen.informatievlaanderen.ldes.processors.LdesClient.lambda$getStartingUrl$0(LdesClient.java:91)
nifi-graph2  | at java.base/java.util.Optional.orElseThrow(Optional.java:403)
nifi-graph2  | at be.vlaanderen.informatievlaanderen.ldes.processors.LdesClient.getStartingUrl(LdesClient.java:90)
nifi-graph2  | at be.vlaanderen.informatievlaanderen.ldes.processors.LdesClient.onScheduled(LdesClient.java:80)
nifi-graph2  | at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
nifi-graph2  | at java.base/java.lang.reflect.Method.invoke(Method.java:577)
nifi-graph2  | at org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotations(ReflectionUtils.java:145)
nifi-graph2  | at org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotations(ReflectionUtils.java:133)
nifi-graph2  | at org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotations(ReflectionUtils.java:78)
nifi-graph2  | at org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotation(ReflectionUtils.java:55)
nifi-graph2  | at org.apache.nifi.controller.StandardProcessorNode.lambda$initiateStart$8(StandardProcessorNode.java:1736)
nifi-graph2  | at org.apache.nifi.engine.FlowEngine$3.call(FlowEngine.java:123)
nifi-graph2  | at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
nifi-graph2  | at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)

nifi-graph2  | at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)

nifi-graph2  | at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)

nifi-graph2  | at java.base/java.lang.Thread.run(Thread.java:833)
MPParsley commented 1 year ago

Thank you @sandervd, I added my nifi config json here: nifi-flow-coghent.json.zip

nifi-graph2           | 2023-06-23 10:55:15,667 INFO [Timer-Driven Process Thread-3] b.v.i.l.c.e.EndpointRequester Selected starting node: empty
nifi-graph2           | 2023-06-23 10:55:15,667 ERROR [Timer-Driven Process Thread-3] b.v.i.ldes.processors.LdesClient LdesClient[id=120567ae-5a5b-3b4e-d1c4-b9d1b19d6aa2] Failed to properly initialize Processor. If still scheduled to run, NiFi will attempt to initialize and run the Processor again after the 'Administrative Yield Duration' has elapsed. Failure is due to java.lang.IllegalArgumentException: Starting url could not be determined for fragmentId: https://apidg.gent.be/opendata/adlib2eventstream/v1/dmg/tentoonstellingen
nifi-graph2           | java.lang.IllegalArgumentException: Starting url could not be determined for fragmentId: https://apidg.gent.be/opendata/adlib2eventstream/v1/dmg/tentoonstellingen
nifi-graph2           |     at be.vlaanderen.informatievlaanderen.ldes.processors.LdesClient.lambda$getStartingUrl$0(LdesClient.java:91)
nifi-graph2           |     at java.base/java.util.Optional.orElseThrow(Optional.java:403)
nifi-graph2           |     at be.vlaanderen.informatievlaanderen.ldes.processors.LdesClient.getStartingUrl(LdesClient.java:90)
nifi-graph2           |     at be.vlaanderen.informatievlaanderen.ldes.processors.LdesClient.onScheduled(LdesClient.java:80)
nifi-graph2           |     at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
nifi-graph2           |     at java.base/java.lang.reflect.Method.invoke(Method.java:577)
nifi-graph2           |     at org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotations(ReflectionUtils.java:145)
nifi-graph2           |     at org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotations(ReflectionUtils.java:133)
nifi-graph2           |     at org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotations(ReflectionUtils.java:78)
nifi-graph2           |     at org.apache.nifi.util.ReflectionUtils.invokeMethodsWithAnnotation(ReflectionUtils.java:55)
nifi-graph2           |     at org.apache.nifi.controller.StandardProcessorNode.lambda$initiateStart$8(StandardProcessorNode.java:1736)
nifi-graph2           |     at org.apache.nifi.engine.FlowEngine$3.call(FlowEngine.java:123)
nifi-graph2           |     at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
nifi-graph2           |     at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
nifi-graph2           |     at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
nifi-graph2           |     at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
nifi-graph2           |     at java.base/java.lang.Thread.run(Thread.java:833)
rorlic commented 8 months ago

Hi, the collection you are using is a tree:Collection and not a ldes:EventStream. The LDES Client is a component to replicate & synchronize LDES's (ldes:EventStream), not tree:Collection instances.