[
https://issues.apache.org/jira/browse/NIFI-4170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16083337#comment-16083337
]
Koji Kawamura commented on NIFI-4170:
-------------------------------------
That's a good point. I agree with that.
I think following rule would be the best:
- If the issue is likely caused by incoming FlowFile, the FlowFile should be
penalized. No need to yield the processor because other FlowFile might have
correct attributes and just works.
-- When processor didn't find a CS,
[here|https://github.com/apache/nifi/blob/master/nifi-nar-bundles/nifi-websocket-bundle/nifi-websocket-processors/src/main/java/org/apache/nifi/processors/websocket/PutWebSocket.java#L183]
and
[here|https://github.com/apache/nifi/blob/master/nifi-nar-bundles/nifi-websocket-bundle/nifi-websocket-processors/src/main/java/org/apache/nifi/processors/websocket/PutWebSocket.java#L186]
- If the issue is likely caused by processor level miss configuration or target
server (WebSocket client or server), then we yield the processor. Optionally we
can penalize the FlowFile, too (just for the use-case where 'failure' is
connected back to itself).
-- When processor catches Exception,
[here|https://github.com/apache/nifi/blob/master/nifi-nar-bundles/nifi-websocket-bundle/nifi-websocket-processors/src/main/java/org/apache/nifi/processors/websocket/PutWebSocket.java#L238]
So, adding penalize at transferToFailure(), and adding context.yield() when
processor catches Exception would do above. How do you think?
> PutWebSocket processor does not support 'Penalty duration' and 'Yield
> duration' settings
> ----------------------------------------------------------------------------------------
>
> Key: NIFI-4170
> URL: https://issues.apache.org/jira/browse/NIFI-4170
> Project: Apache NiFi
> Issue Type: Improvement
> Components: Extensions
> Affects Versions: 1.3.0, 1.4.0
> Reporter: Y Wikander
> Priority: Minor
> Labels: patch
> Fix For: 1.3.0, 1.4.0
>
> Attachments:
> 0002-websocket-PutWebSocket-processor-support-Penalty-dur.patch
>
>
> PutWebSocket processor does not support 'Penalty duration' and 'Yield
> duration' settings.
> I'm assuming that calling content.yield() will also cover 'Penalty duration'.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)