Skip to content
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

Enhanced the Cloud Foundry (cf) client and configuration for streamlined efficiency and integration #362

Merged
merged 3 commits into from
Dec 1, 2023

Conversation

ckganesan
Copy link
Contributor

@ckganesan ckganesan commented Nov 20, 2023

Enhanced the Cloud Foundry (cf) client and configuration for the following reasons:

  1. To enable execution of both authenticated and non-authenticated requests using a single client, replacing the need for multiple clients.
  2. To incorporate support for OAuth scopes and refresh tokens, fully integrated with context handling.
  3. To extend the capabilities for reading additional information from the Cloud Foundry configuration.

@ckganesan
Copy link
Contributor Author

Hi @sneal,

Could you please review the PR?

Thanks in advance!

@sneal
Copy link
Contributor

sneal commented Nov 20, 2023

Overall I like it, especially the idiomatic Golang functional config. I'll take a closer look later this week.

@sneal
Copy link
Contributor

sneal commented Nov 29, 2023

@ckganesan Previously the client would try to re-auth with username/password or client/secret if the refresh token expired.

@ckganesan
Copy link
Contributor Author

@sneal: Following your suggestion, I have implemented the feature to automatically generate a new token upon the expiration of the refresh token.

client/test_runner.go Outdated Show resolved Hide resolved
internal/http/request.go Outdated Show resolved Hide resolved
@sneal
Copy link
Contributor

sneal commented Nov 30, 2023

@ckganesan Thanks for adding that back in, I validated this works properly. Just a couple small issues that need addressed and I'll merge it. Thanks again!

@sneal sneal merged commit 0c80f9d into cloudfoundry:main Dec 1, 2023
@ckganesan ckganesan deleted the enhance-cf-client branch December 1, 2023 17:48
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