-
Notifications
You must be signed in to change notification settings - Fork 29
feat(icp4d): Add support for icp4d #17
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
Merged
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
ffb9f2e
feat(icp4d): Add support for icp4d
ehdsouza da7dc1d
chore(set_icp): Method to explicitly set the icp_access_token
ehdsouza f9eed57
chore(python3): Fix python 3 decoding
ehdsouza e19a28f
test(base): Add more test for code coverage
ehdsouza 45c4576
feat(icp4d): Add support for icp4d url
ehdsouza 6ad4e49
fix(auth): No basic auth when Authorization header is passed
ehdsouza 07b914a
fix(icp4d): icp4d_url mandatory only if icp4d_access_token is None
ehdsouza File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm curious about the reasoning behind giving ICP4D it's own URL. If I understand correctly, ICP4D has one URL and the tokens are retrieved from a certain endpoint on the same cluster as the service requests. Therefore, only one URL should needed (unlike IAM, which has a separate service entirely).
Is that correct @mediumTaj? Let me know if I'm missing something or if you have a reason for doing this in Python!
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The url for token exchange looks different from the endpoint for API calls. This was based on the test instance provided:
@dpopp07 @mediumTaj please let me know if I understood it wrong
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, interesting. I hadn't seen that yet. Still, I wonder if there is a concrete way to parse the base URL from the service URL to use in the token manager. It seems redundant to pass in both of those when the base is the same. What do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My 2 cents... while it might be the case that the service endpoint and icp4d token service share a common part of their respective URLs, what happens when the architecture or configuration changes and that is no longer the case? It's probably best to let the user specify the service endpoint URL separate from the ICP4D token service url.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I too agree with @padamstx to have a separate url for the two.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, after talking with Phil a bit, I am convinced on accepting two separate URLs. That said, how we specifically handle that might be worth some additional discussion. Let's follow up on this tomorrow
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's discuss this on the 6/5 standup call and make sure all SDK cores (and generator) are on the same page with this.