Skip to content

Revert"Revert "fix UPS defined as existing service resources are not working" #1687

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

stiv03
Copy link
Contributor

@stiv03 stiv03 commented Aug 21, 2025

No description provided.

@stiv03 stiv03 changed the title Revert "fix UPS defined as existing service resources are not working" Revert"Revert "fix UPS defined as existing service resources are not working" Aug 21, 2025
Comment on lines 81 to 84
public static boolean isExistingUserProvidedService(Resource resource, CloudControllerClient client) {
CloudServiceInstance serviceInstance = client.getServiceInstanceWithoutAuxiliaryContent(NameUtil.getServiceName(resource), false);
return serviceInstance != null && serviceInstance.isUserProvided();
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This function does too many things, gets the service instance, checks for null, for user provided, etc, got the idea.
You can remove it and make proper checks in the function where this function is invoked and split them in small functions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants