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
You may not want a certain repository, a query method on a repository, or a field of your entity to be exported at all. Examples include hiding fields like password on a User object and similar sensitive data. To tell the exporter to not export these items, annotate them with @RestResource and set exported = false.
[...]
to skip exporting a field, you can annotate the field with @RestResource(exported = false), as follows:
where I want to "hide" both profiles and label fields from a rest repository; yet in the rest interface I see that the endpoints still return all the fields
keep in mind that I also use the same entity in a "normal" controller+service-based rest interface in the same application, so I cannot really use the jackson annotations, because they will hide the fields also there
The text was updated successfully, but these errors were encountered:
According to https://docs.spring.io/spring-data/rest/reference/customizing/configuring-the-rest-url-path.html#customizing-sdr.hiding-repositories
[...]
but this doesn't seems to work, not with association nor with "normal" attributes:
if I have defined an entity like
where I want to "hide" both
profiles
andlabel
fields from a rest repository; yet in the rest interface I see that the endpoints still return all the fieldskeep in mind that I also use the same entity in a "normal" controller+service-based rest interface in the same application, so I cannot really use the jackson annotations, because they will hide the fields also there
The text was updated successfully, but these errors were encountered: