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

Dysfunctional PatchRequest Deserialization in Quarkus Example #557

Open
kuebler opened this issue Apr 8, 2024 · 2 comments
Open

Dysfunctional PatchRequest Deserialization in Quarkus Example #557

kuebler opened this issue Apr 8, 2024 · 2 comments

Comments

@kuebler
Copy link

kuebler commented Apr 8, 2024

It looks like the deserialization of PatchRequest payloads in the quarkus sample doesn't work properly. Here's the request we're sending:

PATCH http://<host>:<port>/v2/Users/<id>

{
  "schemas": [
    "urn:ietf:params:scim:api:messages:2.0:PatchOp"
  ],
  "Operations": [
    {
      "op": "replace",
      "path": "userName",
      "value": "newName"
    }
  ]
}

However, debugging the patch endpoint reveals that the list of patch operations isn't populated:

patch-request-deserialzation

This does, however, work well with the Spring Boot sample, so it looks like this is something specific to the Quarkus sample app. Any help with that would be greatly appreciated - no idea what's causing this.

@bdemers
Copy link
Member

bdemers commented Apr 12, 2024

I wasn't able to reproduce this. Which Java, OS, etc are you using?
(I cannot see why that would cause an issue, but I making guesses)

Also make sure your request sets the content-type to application/scim+json
That said, if you are using a different content-type, and info is getting lost let us know.

@kuebler
Copy link
Author

kuebler commented Apr 12, 2024

Running Java 21 on macOS sonoma. Just checked, using content-type application/scim+json does actually make a difference, with that, the Quarkus example does deserialize the PatchOperations properly, with application/json, however, I'm getting the result I mentioned above. The Spring Boot example, however, doesn't seem to care whether application/json or application/scim+json is used - deserialization works in both cases.

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

No branches or pull requests

2 participants