You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "simonbence (via GitHub)" <gi...@apache.org> on 2023/10/31 22:34:35 UTC
[PR] NIFI-12229 Refine NiFiRegistry client lifecycle: replacing actual client when SSL service changes [nifi]
simonbence opened a new pull request, #7965:
URL: https://github.com/apache/nifi/pull/7965
# Summary
[NIFI-12229](https://issues.apache.org/jira/browse/NIFI-12229)
# Tracking
Please complete the following tracking steps prior to pull request creation.
### Issue Tracking
- [ ] [Apache NiFi Jira](https://issues.apache.org/jira/browse/NIFI) issue created
### Pull Request Tracking
- [ ] Pull Request title starts with Apache NiFi Jira issue number, such as `NIFI-00000`
- [ ] Pull Request commit message starts with Apache NiFi Jira issue number, as such `NIFI-00000`
### Pull Request Formatting
- [ ] Pull Request based on current revision of the `main` branch
- [ ] Pull Request refers to a feature branch with one commit containing changes
# Verification
Please indicate the verification steps performed prior to pull request creation.
### Build
- [ ] Build completed using `mvn clean install -P contrib-check`
- [ ] JDK 21
### Licensing
- [ ] New dependencies are compatible with the [Apache License 2.0](https://apache.org/licenses/LICENSE-2.0) according to the [License Policy](https://www.apache.org/legal/resolved.html)
- [ ] New dependencies are documented in applicable `LICENSE` and `NOTICE` files
### Documentation
- [ ] Documentation formatting appears as expected in rendered files
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-12229 Refine NiFiRegistry client lifecycle: replacing actual client when SSL service changes [nifi]
Posted by "markap14 (via GitHub)" <gi...@apache.org>.
markap14 commented on PR #7965:
URL: https://github.com/apache/nifi/pull/7965#issuecomment-1790832184
Yeah, I think it's better to solve this at the framework level as well. The approach I would recommend would probably be to update the Registry Client Node object so that when validation is performed, if it goes from INVALID to VALID, we call any method annotated with `@OnEnabled`. That way, if a Controller Service that it uses were to be disabled and re-enabled, it would call the `@OnEnabled` method and that, in turn, would be responsible for recreating the underlying client based on the new SSL Context configuration.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-12229 Refine NiFiRegistry client lifecycle: replacing actual client when SSL service changes [nifi]
Posted by "simonbence (via GitHub)" <gi...@apache.org>.
simonbence closed pull request #7965: NIFI-12229 Refine NiFiRegistry client lifecycle: replacing actual client when SSL service changes
URL: https://github.com/apache/nifi/pull/7965
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-12229 Refine NiFiRegistry client lifecycle: replacing actual client when SSL service changes [nifi]
Posted by "pvillard31 (via GitHub)" <gi...@apache.org>.
pvillard31 commented on PR #7965:
URL: https://github.com/apache/nifi/pull/7965#issuecomment-1788239534
I feel like the reported problem could happen in any implementation of the Registry Client, not just this one. Instead of taking this approach that is quite specific to the SSL controller service, should we consider adding something at the framework level to trigger a "refresh" method anytime the configuration of the component is changed? It would then be up to the component to implement whatever makes sense in this refresh method. Thoughts?
Note: I'm fine with this approach to solve the immediate problem but I feel like we could have a more generic approach in case there are some other implementations of the Registry Client interface.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-12229 Refine NiFiRegistry client lifecycle: replacing actual client when SSL service changes [nifi]
Posted by "simonbence (via GitHub)" <gi...@apache.org>.
simonbence commented on PR #7965:
URL: https://github.com/apache/nifi/pull/7965#issuecomment-1790512269
@pvillard31 @exceptionfactory Thanks for the feedback!
As of this given case, the behaviour is specific to the way this particular implementation works. Other implementations, if they are caching some internal state depending on "controller service" property might have a similar challenge.
@exceptionfactory You are perfectly right, the Flow Registry Client currently has no such lifecycle states like active-deactivated, that is correct. At the time of changing the Client to a component, this was an intentional choice due to the number of questions would come with this behavioural change (and due to avoiding any break in the previous behaviour). The questions include: what should happen with the existing versioned flows when the registry is deactivated? It looks like a different case compared to the situation when the registry is unintenionally unreachable and might result some confusion. An other possibility you mention is to "hook on" some existing event like validation or as you mention, the (de)activation of the dependent Controller Services but I am not aware of any support in the framework for this.
What I propose to do is to move on with this fix (which in some cases can cause misbehaviour as it is now) and for a wider scope solution it would be beneficial to start a discussion about the level of support we aim for: I can easily imagine that an additional hookpoint might be useful for other components as well.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NIFI-12229 Refine NiFiRegistry client lifecycle: replacing actual client when SSL service changes [nifi]
Posted by "simonbence (via GitHub)" <gi...@apache.org>.
simonbence commented on PR #7965:
URL: https://github.com/apache/nifi/pull/7965#issuecomment-1792120295
As suggested I will raise a new PR with a framework level solution. I think, @markap14 's suggestion might be the best balance between feature richness and unnecessary complexity I will aim for that.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org