[
https://issues.apache.org/jira/browse/MINIFICPP-254?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16196134#comment-16196134
]
marco polo edited comment on MINIFICPP-254 at 10/8/17 2:35 PM:
---------------------------------------------------------------
[~fstakem] Thanks for finding this. It is backwards, and no tests can cover
this branch because it's a condition we won't allow through other layers of
change ( or shouldn't ). There really isn't a need for a lock at all since the
only place it can be changed is within initialization and that's currently
single threaded; however, I'm inclined to leave the locking in place with a
fix. Do you intend to submit a PR or shall I make the change? If you submit a
PR against this ticket I can take a look, approve, and merge it. It appears to
happen further down in another function, so I'm sure the error was copy/pasted.
Long term I think the lock will stay only if we have that be a configurable
piece of the component. As such I'm not sure it will be.
was (Author: phrocker):
[~fstakem] Thanks for finding this. It is backwards, and no tests can cover
this branch because it's a condition we won't allow through other layers of
change ( or shouldn't ). There really isn't a need for a lock at all since the
only place it can be changed is within initialization and that's currently
single threaded; however, I'm inclined to leave the locking in place with a
fix. Do you intend to submit a PR or shall I make the change? If you submit a
PR against this ticket I can take a look, approve, and merge it. It appears to
happen further down in another function, so I'm sure the error was copy/pasted.
> Connectable lock incorrect
> --------------------------
>
> Key: MINIFICPP-254
> URL: https://issues.apache.org/jira/browse/MINIFICPP-254
> Project: NiFi MiNiFi C++
> Issue Type: Question
> Reporter: Fredrick Stakem
> Priority: Minor
>
> On class Connectable line 68 you define a lock required if it is running in
> function isSupportedRelationship(). If the Connectable is running then
> relationship_ does not change in the code. The relationship_ only can be
> changed when the state is not running. Is this backwards?
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)