From 93105a2182478308f09b9b3f81c2149149dd60c0 Mon Sep 17 00:00:00 2001 From: Pedro Igor Date: Thu, 15 Jun 2017 09:49:20 -0300 Subject: [PATCH] [KEYCLOAK-5056] - @NoCache to scope admin api --- .../org/keycloak/authorization/admin/ResourceSetService.java | 3 ++- .../java/org/keycloak/authorization/admin/ScopeService.java | 5 +++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/services/src/main/java/org/keycloak/authorization/admin/ResourceSetService.java b/services/src/main/java/org/keycloak/authorization/admin/ResourceSetService.java index b0666f1144..3c7f34fbde 100644 --- a/services/src/main/java/org/keycloak/authorization/admin/ResourceSetService.java +++ b/services/src/main/java/org/keycloak/authorization/admin/ResourceSetService.java @@ -86,6 +86,7 @@ public class ResourceSetService { } @POST + @NoCache @Consumes("application/json") @Produces("application/json") public Response create(@Context UriInfo uriInfo, ResourceRepresentation resource) { @@ -288,8 +289,8 @@ public class ResourceSetService { @Path("/search") @GET - @Produces("application/json") @NoCache + @Produces("application/json") public Response find(@QueryParam("name") String name) { this.auth.requireView(); StoreFactory storeFactory = authorization.getStoreFactory(); diff --git a/services/src/main/java/org/keycloak/authorization/admin/ScopeService.java b/services/src/main/java/org/keycloak/authorization/admin/ScopeService.java index d59a6de32e..a2a2320d7c 100644 --- a/services/src/main/java/org/keycloak/authorization/admin/ScopeService.java +++ b/services/src/main/java/org/keycloak/authorization/admin/ScopeService.java @@ -77,6 +77,7 @@ public class ScopeService { } @POST + @NoCache @Consumes(MediaType.APPLICATION_JSON) @Produces(MediaType.APPLICATION_JSON) public Response create(@Context UriInfo uriInfo, ScopeRepresentation scope) { @@ -150,6 +151,7 @@ public class ScopeService { @Path("{id}") @GET + @NoCache @Produces(MediaType.APPLICATION_JSON) public Response findById(@PathParam("id") String id) { this.auth.requireView(); @@ -164,6 +166,7 @@ public class ScopeService { @Path("{id}/resources") @GET + @NoCache @Produces(MediaType.APPLICATION_JSON) public Response getResources(@PathParam("id") String id) { this.auth.requireView(); @@ -186,6 +189,7 @@ public class ScopeService { @Path("{id}/permissions") @GET + @NoCache @Produces(MediaType.APPLICATION_JSON) public Response getPermissions(@PathParam("id") String id) { this.auth.requireView(); @@ -231,6 +235,7 @@ public class ScopeService { } @GET + @NoCache @Produces("application/json") public Response findAll(@QueryParam("scopeId") String id, @QueryParam("name") String name,