You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
interpretation of openapi readOnly flag in model #334
get generated java:
```java
public record Data {
@JsonProperty(value = "status", access = JsonProperty.Access.READ_ONLY)
String status
) {}
This is correct if the generated code is for the provider of the interface (i.e. server-side). But if the code is to be the client of the interface, the field should instead be annotated with JsonProperty.Access.WRITE_ONLY.
So, as a feature request, it would be useful if there was a code generation option that declared the intended usage of the generated code.
actually it turns out there is a Jacksonm flag that already does this (MapperFeature.INVERSE_READ_WRITE_ACCESS), so this wouldn;t actually be very useful.
Activity
richard-melvin commentedon Apr 9, 2025
actually it turns out there is a Jacksonm flag that already does this (
MapperFeature.INVERSE_READ_WRITE_ACCESS), so this wouldn;t actually be very useful.hauner commentedon Apr 9, 2025
interesting, I didn't know about that.