-
Notifications
You must be signed in to change notification settings - Fork 11
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
Fix #1684: Update Client and Admin Console #1685
Conversation
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.
In general looks OK, but in my opinion we should not use a GET
REST API method for modifying data.
...auth-admin/src/main/java/io/getlime/security/app/admin/controller/ApplicationController.java
Outdated
Show resolved
Hide resolved
final UpdateCallbackUrlRequest request = new UpdateCallbackUrlRequest(); | ||
request.setId(id); | ||
request.setApplicationId(applicationId); | ||
request.setName(name); | ||
request.setType(type.toString()); |
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.
🤔 Why is type
a type of String instead of Enum? I know, we should solve this in a separate PR if agreed.
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 was thinking about that too, but I didn't want to include this type of change in this PR.
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.
@@ -157,7 +160,7 @@ public String applicationVersionCreate(@PathVariable("applicationId") String id, | |||
* @param model Model with passed parameters. | |||
* @return "callbackCreate" view. | |||
*/ | |||
@GetMapping("/application/detail/{applicationId}/callback/create") | |||
@GetMapping("/application/detail/{applicationId}/callback/create/form") |
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.
Changing URL is not backward compatible but for Admin API we may afford that.
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.
Yes, I think we can assume those are just called internally.
* @return Information about new callback URL object. | ||
* @throws PowerAuthClientException In case REST API call fails. | ||
*/ | ||
CreateCallbackUrlResponse createCallbackUrl(String applicationId, String name, CallbackUrlType type, String callbackUrl, List<String> attributes, HttpAuthenticationPrivate authentication) throws PowerAuthClientException; | ||
CreateCallbackUrlResponse createCallbackUrl(String applicationId, String name, CallbackUrlType type, String callbackUrl, List<String> attributes, HttpAuthenticationPrivate authentication, Duration retentionPeriod, Duration initialBackoff, Integer maxAttempts) throws PowerAuthClientException; |
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.
Carthago delenda est
In long term, I prefer using methods with request object only and mark these as deprecated.
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.
Approved now.
Update PA Admin Console and PA Client to reflect changes in Callback Management API (3 new attributes).