From 193ae70985bce5db8304f28ff9f3ef29dde34816 Mon Sep 17 00:00:00 2001
From: "Endi S. Dewata" <edewata@redhat.com>
Date: Thu, 30 Jan 2014 05:23:17 -0500
Subject: [PATCH] Removed @Consumes and @Provides.

The @Consumes and @Provides annotations have been removed from all
methods (except from methods that consume forms) to allow client
to use the default consumes and provides specified in the proxy.

Ticket #554
---
 .../netscape/certsrv/cert/CertRequestResource.java  | 16 ----------------
 .../src/com/netscape/certsrv/cert/CertResource.java | 14 --------------
 .../com/netscape/certsrv/group/GroupResource.java   | 15 ---------------
 .../netscape/certsrv/key/KeyRequestResource.java    |  6 ------
 .../src/com/netscape/certsrv/key/KeyResource.java   |  6 ------
 .../netscape/certsrv/logging/ActivityResource.java  |  4 ----
 .../com/netscape/certsrv/logging/AuditResource.java |  6 ------
 .../netscape/certsrv/profile/ProfileResource.java   | 12 ------------
 .../certsrv/selftests/SelfTestResource.java         |  5 -----
 .../certsrv/system/KRAConnectorResource.java        |  5 -----
 .../certsrv/system/SecurityDomainResource.java      |  4 ----
 .../netscape/certsrv/system/SystemCertResource.java |  3 ---
 .../certsrv/system/SystemConfigResource.java        |  4 ----
 .../certsrv/system/TPSConnectorResource.java        | 13 -------------
 .../tps/authenticator/AuthenticatorResource.java    | 12 ------------
 .../netscape/certsrv/tps/cert/TPSCertResource.java  |  4 ----
 .../netscape/certsrv/tps/config/ConfigResource.java |  6 ------
 .../certsrv/tps/connection/ConnectionResource.java  | 12 ------------
 .../certsrv/tps/profile/ProfileMappingResource.java | 12 ------------
 .../certsrv/tps/profile/ProfileResource.java        | 12 ------------
 .../netscape/certsrv/tps/token/TokenResource.java   | 12 ------------
 .../src/com/netscape/certsrv/user/UserResource.java | 21 ---------------------
 22 files changed, 204 deletions(-)

diff --git a/base/common/src/com/netscape/certsrv/cert/CertRequestResource.java b/base/common/src/com/netscape/certsrv/cert/CertRequestResource.java
index e1514293bd22ca295d56157239881d74d0928570..b9ae1f1fe0592bbcc4a7b64baa2ef4fecbe52749 100644
--- a/base/common/src/com/netscape/certsrv/cert/CertRequestResource.java
+++ b/base/common/src/com/netscape/certsrv/cert/CertRequestResource.java
@@ -22,7 +22,6 @@ import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
 import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.MultivaluedMap;
@@ -42,15 +41,12 @@ public interface CertRequestResource {
     @POST
     @Path("certrequests")
     @ClientResponseType(entityType=CertRequestInfos.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @Consumes({ MediaType.APPLICATION_FORM_URLENCODED })
     public Response enrollCert(MultivaluedMap<String, String> form);
 
     @POST
     @Path("certrequests")
     @ClientResponseType(entityType=CertRequestInfos.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response enrollCert(CertEnrollmentRequest data);
 
     /**
@@ -59,7 +55,6 @@ public interface CertRequestResource {
     @GET
     @Path("certrequests/{id}")
     @ClientResponseType(entityType=CertRequestInfo.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getRequestInfo(@PathParam("id") RequestId id);
 
     /**
@@ -68,7 +63,6 @@ public interface CertRequestResource {
     @GET
     @Path("agent/certrequests")
     @ClientResponseType(entityType=CertRequestInfos.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certrequests")
     @AuthMethodMapping("certrequests")
     public Response listRequests(@QueryParam("requestState") String requestState,
@@ -81,7 +75,6 @@ public interface CertRequestResource {
     @GET
     @Path("agent/certrequests/{id}")
     @ClientResponseType(entityType=CertReviewResponse.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certrequests")
     @AuthMethodMapping("certrequests")
     public Response reviewRequest(@PathParam("id") RequestId id);
@@ -89,7 +82,6 @@ public interface CertRequestResource {
     @GET
     @Path("certrequests/profiles")
     @ClientResponseType(entityType=ProfileDataInfos.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response listEnrollmentTemplates(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
@@ -97,13 +89,11 @@ public interface CertRequestResource {
     @GET
     @Path("certrequests/profiles/{id}")
     @ClientResponseType(entityType=CertEnrollmentRequest.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getEnrollmentTemplate(@PathParam("id") String id);
 
     @POST
     @Path("agent/certrequests/{id}/approve")
     @ClientResponseType(entityType=Void.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certrequests")
     @AuthMethodMapping("certrequests")
     public Response approveRequest(@PathParam("id") RequestId id, CertReviewResponse data);
@@ -111,7 +101,6 @@ public interface CertRequestResource {
     @POST
     @Path("agent/certrequests/{id}/reject")
     @ClientResponseType(entityType=Void.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certrequests")
     @AuthMethodMapping("certrequests")
     public Response rejectRequest(@PathParam("id") RequestId id, CertReviewResponse data);
@@ -119,7 +108,6 @@ public interface CertRequestResource {
     @POST
     @Path("agent/certrequests/{id}/cancel")
     @ClientResponseType(entityType=Void.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certrequests")
     @AuthMethodMapping("certrequests")
     public Response cancelRequest(@PathParam("id") RequestId id, CertReviewResponse data);
@@ -127,7 +115,6 @@ public interface CertRequestResource {
     @POST
     @Path("agent/certrequests/{id}/update")
     @ClientResponseType(entityType=Void.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certrequests")
     @AuthMethodMapping("certrequests")
     public Response updateRequest(@PathParam("id") RequestId id, CertReviewResponse data);
@@ -135,7 +122,6 @@ public interface CertRequestResource {
     @POST
     @Path("agent/certrequests/{id}/validate")
     @ClientResponseType(entityType=Void.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certrequests")
     @AuthMethodMapping("certrequests")
     public Response validateRequest(@PathParam("id") RequestId id, CertReviewResponse data);
@@ -143,7 +129,6 @@ public interface CertRequestResource {
     @POST
     @Path("agent/certrequests/{id}/unassign")
     @ClientResponseType(entityType=Void.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certrequests")
     @AuthMethodMapping("certrequests")
     public Response unassignRequest(@PathParam("id") RequestId id, CertReviewResponse data);
@@ -151,7 +136,6 @@ public interface CertRequestResource {
     @POST
     @Path("agent/certrequests/{id}/assign")
     @ClientResponseType(entityType=Void.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certrequests")
     @AuthMethodMapping("certrequests")
     public Response assignRequest(@PathParam("id") RequestId id, CertReviewResponse data);
diff --git a/base/common/src/com/netscape/certsrv/cert/CertResource.java b/base/common/src/com/netscape/certsrv/cert/CertResource.java
index 23e8987557093f269bad997edf7559e92fabcaf4..c5a5823ea90af354b20007d5a2b91762853b795f 100644
--- a/base/common/src/com/netscape/certsrv/cert/CertResource.java
+++ b/base/common/src/com/netscape/certsrv/cert/CertResource.java
@@ -1,13 +1,10 @@
 package com.netscape.certsrv.cert;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -22,7 +19,6 @@ public interface CertResource {
     @GET
     @Path("certs")
     @ClientResponseType(entityType=CertDataInfos.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response listCerts(
             @QueryParam("status") String status,
             @QueryParam("maxResults") Integer maxResults,
@@ -33,8 +29,6 @@ public interface CertResource {
     @POST
     @Path("certs/search")
     @ClientResponseType(entityType=CertDataInfos.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response searchCerts(
             CertSearchRequest data,
             @QueryParam("start") Integer start,
@@ -43,13 +37,11 @@ public interface CertResource {
     @GET
     @Path("certs/{id}")
     @ClientResponseType(entityType=CertData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getCert(@PathParam("id") CertId id);
 
     @GET
     @Path("agent/certs/{id}")
     @ClientResponseType(entityType=CertData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certs")
     @AuthMethodMapping("certs")
     public Response reviewCert(@PathParam("id") CertId id);
@@ -57,8 +49,6 @@ public interface CertResource {
     @POST
     @Path("agent/certs/{id}/revoke-ca")
     @ClientResponseType(entityType=CertRequestInfo.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certs")
     @AuthMethodMapping("certs")
     public Response revokeCACert(@PathParam("id") CertId id, CertRevokeRequest request);
@@ -66,8 +56,6 @@ public interface CertResource {
     @POST
     @Path("agent/certs/{id}/revoke")
     @ClientResponseType(entityType=CertRequestInfo.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certs")
     @AuthMethodMapping("certs")
     public Response revokeCert(@PathParam("id") CertId id, CertRevokeRequest request);
@@ -75,8 +63,6 @@ public interface CertResource {
     @POST
     @Path("agent/certs/{id}/unrevoke")
     @ClientResponseType(entityType=CertRequestInfo.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("certs")
     @AuthMethodMapping("certs")
     public Response unrevokeCert(@PathParam("id") CertId id, CertUnrevokeRequest request);
diff --git a/base/common/src/com/netscape/certsrv/group/GroupResource.java b/base/common/src/com/netscape/certsrv/group/GroupResource.java
index f1dfe40261ff4297248721aa7f17f819aee3402b..2f42f4aa7d7d948875ab7c5e5955709f2f646000 100644
--- a/base/common/src/com/netscape/certsrv/group/GroupResource.java
+++ b/base/common/src/com/netscape/certsrv/group/GroupResource.java
@@ -18,15 +18,12 @@
 
 package com.netscape.certsrv.group;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.DELETE;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -45,7 +42,6 @@ public interface GroupResource {
 
     @GET
     @ClientResponseType(entityType=GroupCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findGroups(
             @QueryParam("filter") String filter,
             @QueryParam("start") Integer start,
@@ -53,33 +49,26 @@ public interface GroupResource {
 
     @POST
     @ClientResponseType(entityType=GroupData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response addGroup(GroupData groupData);
 
     @GET
     @Path("{groupID}")
     @ClientResponseType(entityType=GroupData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getGroup(@PathParam("groupID") String groupID);
 
     @PATCH
     @Path("{groupID}")
     @ClientResponseType(entityType=GroupData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response modifyGroup(@PathParam("groupID") String groupID, GroupData groupData);
 
     @DELETE
     @Path("{groupID}")
     @ClientResponseType(entityType=Void.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response removeGroup(@PathParam("groupID") String groupID);
 
     @GET
     @Path("{groupID}/members")
     @ClientResponseType(entityType=GroupMemberCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findGroupMembers(
             @PathParam("groupID") String groupID,
             @QueryParam("start") Integer start,
@@ -88,19 +77,15 @@ public interface GroupResource {
     @POST
     @Path("{groupID}/members")
     @ClientResponseType(entityType=GroupMemberData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response addGroupMember(@PathParam("groupID") String groupID, String memberID);
 
     @GET
     @Path("{groupID}/members/{memberID}")
     @ClientResponseType(entityType=GroupMemberData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getGroupMember(@PathParam("groupID") String groupID, @PathParam("memberID") String memberID);
 
     @DELETE
     @Path("{groupID}/members/{memberID}")
     @ClientResponseType(entityType=Void.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response removeGroupMember(@PathParam("groupID") String groupID, @PathParam("memberID") String memberID);
 }
diff --git a/base/common/src/com/netscape/certsrv/key/KeyRequestResource.java b/base/common/src/com/netscape/certsrv/key/KeyRequestResource.java
index 867136bc1220ea1beb8f9fb38c7bdd43f18062e8..4bdd5fe05b4d68d5da9ee24625172316947f2a32 100644
--- a/base/common/src/com/netscape/certsrv/key/KeyRequestResource.java
+++ b/base/common/src/com/netscape/certsrv/key/KeyRequestResource.java
@@ -5,7 +5,6 @@ import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
 import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.MultivaluedMap;
@@ -41,7 +40,6 @@ public interface KeyRequestResource {
      */
     @GET
     @ClientResponseType(entityType=KeyRequestInfoCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response listRequests(@QueryParam("requestState") String requestState,
                                             @QueryParam("requestType") String requestType,
                                             @QueryParam("clientID") String clientID,
@@ -52,14 +50,11 @@ public interface KeyRequestResource {
 
     @POST
     @ClientResponseType(entityType=KeyRequestResponse.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @Consumes({ MediaType.APPLICATION_FORM_URLENCODED})
     public Response createRequest(MultivaluedMap<String, String> form);
 
     @POST
     @ClientResponseType(entityType=KeyRequestResponse.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response createRequest(ResourceMessage data);
 
     /**
@@ -68,7 +63,6 @@ public interface KeyRequestResource {
     @GET
     @Path("{id}")
     @ClientResponseType(entityType=KeyRequestInfo.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getRequestInfo(@PathParam("id") RequestId id);
 
     @POST
diff --git a/base/common/src/com/netscape/certsrv/key/KeyResource.java b/base/common/src/com/netscape/certsrv/key/KeyResource.java
index 5b5bf7a7444cd900f16bad8f3b078f46196c616f..a497f92f07a29d73d8d0b8c283021ecfbfd74170 100644
--- a/base/common/src/com/netscape/certsrv/key/KeyResource.java
+++ b/base/common/src/com/netscape/certsrv/key/KeyResource.java
@@ -5,7 +5,6 @@ import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
 import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.MultivaluedMap;
@@ -25,7 +24,6 @@ public interface KeyResource {
 
     @GET
     @ClientResponseType(entityType=KeyInfoCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response listKeys(@QueryParam("clientID") String clientID,
                                  @QueryParam("status") String status,
                                  @QueryParam("maxResults") Integer maxResults,
@@ -36,7 +34,6 @@ public interface KeyResource {
     @GET
     @Path("active/{clientID}")
     @ClientResponseType(entityType=KeyInfo.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getActiveKeyInfo(@PathParam("clientID") String clientID);
 
     @GET
@@ -60,15 +57,12 @@ public interface KeyResource {
     @POST
     @Path("retrieve")
     @ClientResponseType(entityType=KeyData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response retrieveKey(KeyRecoveryRequest data);
 
     // retrieval - used to test integration with a browser
     @POST
     @Path("retrieve")
     @ClientResponseType(entityType=KeyData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @Consumes({ MediaType.APPLICATION_FORM_URLENCODED })
     public Response retrieveKey(MultivaluedMap<String, String> form);
 }
diff --git a/base/common/src/com/netscape/certsrv/logging/ActivityResource.java b/base/common/src/com/netscape/certsrv/logging/ActivityResource.java
index 715233e63028cc9d53c17f3875c6c19d7fab8e7b..bc6d375caacae5bffda6b10dca0189188cde551f 100644
--- a/base/common/src/com/netscape/certsrv/logging/ActivityResource.java
+++ b/base/common/src/com/netscape/certsrv/logging/ActivityResource.java
@@ -20,9 +20,7 @@ package com.netscape.certsrv.logging;
 import javax.ws.rs.GET;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -36,7 +34,6 @@ public interface ActivityResource {
 
     @GET
     @ClientResponseType(entityType=ActivityCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findActivities(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
@@ -44,6 +41,5 @@ public interface ActivityResource {
     @GET
     @Path("{activityID}")
     @ClientResponseType(entityType=ActivityData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getActivity(@PathParam("activityID") String activityID);
 }
diff --git a/base/common/src/com/netscape/certsrv/logging/AuditResource.java b/base/common/src/com/netscape/certsrv/logging/AuditResource.java
index 1220b89bc34641b09b04535348976b5bdf8f4659..13be4d827de24825545d35df877688972077e0de 100644
--- a/base/common/src/com/netscape/certsrv/logging/AuditResource.java
+++ b/base/common/src/com/netscape/certsrv/logging/AuditResource.java
@@ -17,12 +17,9 @@
 // --- END COPYRIGHT BLOCK ---
 package com.netscape.certsrv.logging;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.GET;
 import javax.ws.rs.PUT;
 import javax.ws.rs.Path;
-import javax.ws.rs.Produces;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -36,12 +33,9 @@ public interface AuditResource {
 
     @GET
     @ClientResponseType(entityType=AuditConfig.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getAuditConfig();
 
     @PUT
     @ClientResponseType(entityType=AuditConfig.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response updateAuditConfig(AuditConfig configData);
 }
diff --git a/base/common/src/com/netscape/certsrv/profile/ProfileResource.java b/base/common/src/com/netscape/certsrv/profile/ProfileResource.java
index 28b173bd430fe711dfd7aec18fd49ebb97d4871f..87449b27e749c6088f65b53192eb5ac101263f1e 100644
--- a/base/common/src/com/netscape/certsrv/profile/ProfileResource.java
+++ b/base/common/src/com/netscape/certsrv/profile/ProfileResource.java
@@ -1,15 +1,12 @@
 package com.netscape.certsrv.profile;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.DELETE;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.PUT;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -24,7 +21,6 @@ public interface ProfileResource {
     @GET
     @ClientResponseType(entityType=ProfileDataInfos.class)
     @ACLMapping("profiles.list")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response listProfiles(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
@@ -33,36 +29,28 @@ public interface ProfileResource {
     @Path("{id}")
     @ClientResponseType(entityType=ProfileData.class)
     @ACLMapping("profiles.read")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response retrieveProfile(@PathParam("id") String id);
 
     @POST
     @ClientResponseType(entityType=ProfileData.class)
     @ACLMapping("profiles.create")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response createProfile(ProfileData data);
 
     @POST
     @Path("{id}")
     @ClientResponseType(entityType=Void.class)
     @ACLMapping("profiles.approve")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response modifyProfileState(@PathParam("id") String id, @QueryParam("action") String action);
 
     @PUT
     @Path("{id}")
     @ClientResponseType(entityType=ProfileData.class)
     @ACLMapping("profiles.modify")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response modifyProfile(@PathParam("id") String id, ProfileData data);
 
     @DELETE
     @Path("{id}")
     @ClientResponseType(entityType=Void.class)
     @ACLMapping("profiles.delete")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response deleteProfile(@PathParam("id") String id);
-
 }
\ No newline at end of file
diff --git a/base/common/src/com/netscape/certsrv/selftests/SelfTestResource.java b/base/common/src/com/netscape/certsrv/selftests/SelfTestResource.java
index 35c322d86b054280806ead7e77f737f05690e596..90dfcb4b163b7798879892203e8a7305e8269200 100644
--- a/base/common/src/com/netscape/certsrv/selftests/SelfTestResource.java
+++ b/base/common/src/com/netscape/certsrv/selftests/SelfTestResource.java
@@ -21,9 +21,7 @@ import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -42,20 +40,17 @@ public interface SelfTestResource {
 
     @GET
     @ClientResponseType(entityType=SelfTestCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findSelfTests(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
 
     @POST
     @ClientResponseType(entityType=Void.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("selftests.execute")
     public Response executeSelfTests(@QueryParam("action") String action);
 
     @GET
     @Path("{selfTestID}")
     @ClientResponseType(entityType=SelfTestData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getSelfTest(@PathParam("selfTestID") String selfTestID);
 }
diff --git a/base/common/src/com/netscape/certsrv/system/KRAConnectorResource.java b/base/common/src/com/netscape/certsrv/system/KRAConnectorResource.java
index 474994e9e07255ab81a2ff671f38a4a5c202de1f..970224b9a83d6ef119bf954b08ba0210cd62ea6e 100644
--- a/base/common/src/com/netscape/certsrv/system/KRAConnectorResource.java
+++ b/base/common/src/com/netscape/certsrv/system/KRAConnectorResource.java
@@ -21,7 +21,6 @@ import javax.ws.rs.Consumes;
 import javax.ws.rs.FormParam;
 import javax.ws.rs.POST;
 import javax.ws.rs.Path;
-import javax.ws.rs.Produces;
 import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.MultivaluedMap;
 
@@ -38,19 +37,15 @@ public interface KRAConnectorResource {
 
     @POST
     @Path("add")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public void addConnector(KRAConnectorInfo info);
 
     @POST
     @Path("add")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @Consumes({ MediaType.APPLICATION_FORM_URLENCODED })
     public void addConnector(MultivaluedMap<String, String> form);
 
     @POST
     @Path("remove")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @Consumes({ MediaType.APPLICATION_FORM_URLENCODED })
     public void removeConnector(@FormParam("host") String host, @FormParam("port") String port);
 
diff --git a/base/common/src/com/netscape/certsrv/system/SecurityDomainResource.java b/base/common/src/com/netscape/certsrv/system/SecurityDomainResource.java
index 740786f793b60a448e561ffee7d2eadbf46fe306..7522c53a644a38c8c103bfec1ba7cc0f8e42dcc6 100644
--- a/base/common/src/com/netscape/certsrv/system/SecurityDomainResource.java
+++ b/base/common/src/com/netscape/certsrv/system/SecurityDomainResource.java
@@ -19,9 +19,7 @@ package com.netscape.certsrv.system;
 
 import javax.ws.rs.GET;
 import javax.ws.rs.Path;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 
 import com.netscape.certsrv.acls.ACLMapping;
 import com.netscape.certsrv.authentication.AuthMethodMapping;
@@ -34,7 +32,6 @@ public interface SecurityDomainResource {
 
     @GET
     @Path("installToken")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("securityDomain.installToken")
     @AuthMethodMapping("securityDomain.installToken")
     public InstallToken getInstallToken(
@@ -43,6 +40,5 @@ public interface SecurityDomainResource {
 
     @GET
     @Path("domainInfo")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public DomainInfo getDomainInfo();
 }
diff --git a/base/common/src/com/netscape/certsrv/system/SystemCertResource.java b/base/common/src/com/netscape/certsrv/system/SystemCertResource.java
index d13be9ab4a2f3b8e6a73b9020b175b1c1f486ab4..3a9d6e125c2d6ccfd2028ed4df91128bb87b646b 100644
--- a/base/common/src/com/netscape/certsrv/system/SystemCertResource.java
+++ b/base/common/src/com/netscape/certsrv/system/SystemCertResource.java
@@ -2,8 +2,6 @@ package com.netscape.certsrv.system;
 
 import javax.ws.rs.GET;
 import javax.ws.rs.Path;
-import javax.ws.rs.Produces;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -19,7 +17,6 @@ public interface SystemCertResource {
     @GET
     @Path("transport")
     @ClientResponseType(entityType=CertData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getTransportCert();
 
 }
\ No newline at end of file
diff --git a/base/common/src/com/netscape/certsrv/system/SystemConfigResource.java b/base/common/src/com/netscape/certsrv/system/SystemConfigResource.java
index 2809baaa6fb43d2c82fa3dea0519c5ea0e7da9b9..db4f35ac3f5600a73f8a95e831d0becab993b80b 100644
--- a/base/common/src/com/netscape/certsrv/system/SystemConfigResource.java
+++ b/base/common/src/com/netscape/certsrv/system/SystemConfigResource.java
@@ -20,7 +20,6 @@ package com.netscape.certsrv.system;
 import javax.ws.rs.Consumes;
 import javax.ws.rs.POST;
 import javax.ws.rs.Path;
-import javax.ws.rs.Produces;
 import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.MultivaluedMap;
 
@@ -33,13 +32,10 @@ public interface SystemConfigResource {
 
     @POST
     @Path("configure")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @Consumes({ MediaType.APPLICATION_FORM_URLENCODED })
     public ConfigurationResponse configure(MultivaluedMap<String, String> form);
 
     @POST
     @Path("configure")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public ConfigurationResponse configure(ConfigurationRequest data);
 }
diff --git a/base/common/src/com/netscape/certsrv/system/TPSConnectorResource.java b/base/common/src/com/netscape/certsrv/system/TPSConnectorResource.java
index 43213d0f401988eb49718d72fda363e9c0f1018c..af440d35e5159b87c82c117868c89ea12b086355 100644
--- a/base/common/src/com/netscape/certsrv/system/TPSConnectorResource.java
+++ b/base/common/src/com/netscape/certsrv/system/TPSConnectorResource.java
@@ -17,16 +17,13 @@
 // --- END COPYRIGHT BLOCK ---
 package com.netscape.certsrv.system;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.DELETE;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.PUT;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -43,7 +40,6 @@ import com.netscape.certsrv.key.KeyData;
 public interface TPSConnectorResource {
     @GET
     @ClientResponseType(entityType=TPSConnectorCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findConnectors(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
@@ -51,27 +47,22 @@ public interface TPSConnectorResource {
     @GET
     @Path("{id}")
     @ClientResponseType(entityType=TPSConnectorData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getConnector(@PathParam("id") String id);
 
     @GET
     @Path("search")
     @ClientResponseType(entityType=TPSConnectorData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getConnector(@QueryParam("host") String host,
             @QueryParam("port") String port);
 
     @POST
     @ClientResponseType(entityType=TPSConnectorData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response createConnector(@QueryParam("host") String host,
             @QueryParam("port") String port);
 
     @POST
     @Path("{id}")
     @ClientResponseType(entityType=TPSConnectorData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response modifyConnector(@PathParam("id") String id, TPSConnectorData data);
 
     @DELETE
@@ -83,14 +74,12 @@ public interface TPSConnectorResource {
     @Path("{id}/shared-secret")
     @ClientResponseType(entityType=KeyData.class)
     @ACLMapping("admin.sharedsecret")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response createSharedSecret(@PathParam("id") String id);
 
     @PUT
     @Path("{id}/shared-secret")
     @ClientResponseType(entityType=KeyData.class)
     @ACLMapping("admin.sharedsecret")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response replaceSharedSecret(@PathParam("id") String id);
 
     @DELETE
@@ -101,7 +90,6 @@ public interface TPSConnectorResource {
 
     @DELETE
     @ClientResponseType(entityType=Void.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response deleteConnector(@QueryParam("host") String host,
             @QueryParam("port") String port);
 
@@ -109,6 +97,5 @@ public interface TPSConnectorResource {
     @Path("{id}/shared-secret")
     @ClientResponseType(entityType=KeyData.class)
     @ACLMapping("admin.sharedsecret")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getSharedSecret(@PathParam("id") String id);
 }
diff --git a/base/common/src/com/netscape/certsrv/tps/authenticator/AuthenticatorResource.java b/base/common/src/com/netscape/certsrv/tps/authenticator/AuthenticatorResource.java
index 452f8ea56f7e4d213b7561ea7110cf878d7c6ee1..ce570edf134ad29040f51529e25001fb53938a16 100644
--- a/base/common/src/com/netscape/certsrv/tps/authenticator/AuthenticatorResource.java
+++ b/base/common/src/com/netscape/certsrv/tps/authenticator/AuthenticatorResource.java
@@ -17,16 +17,13 @@
 // --- END COPYRIGHT BLOCK ---
 package com.netscape.certsrv.tps.authenticator;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.DELETE;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.PUT;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -45,7 +42,6 @@ public interface AuthenticatorResource {
 
     @GET
     @ClientResponseType(entityType=AuthenticatorCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findAuthenticators(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
@@ -53,22 +49,17 @@ public interface AuthenticatorResource {
     @GET
     @Path("{authenticatorID}")
     @ClientResponseType(entityType=AuthenticatorData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getAuthenticator(@PathParam("authenticatorID") String authenticatorID);
 
     @POST
     @ACLMapping("authenticators.add")
     @ClientResponseType(entityType=AuthenticatorData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response addAuthenticator(AuthenticatorData authenticatorData);
 
     @PUT
     @Path("{authenticatorID}")
     @ACLMapping("authenticators.modify")
     @ClientResponseType(entityType=AuthenticatorData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response updateAuthenticator(
             @PathParam("authenticatorID") String authenticatorID,
             AuthenticatorData authenticatorData);
@@ -77,8 +68,6 @@ public interface AuthenticatorResource {
     @Path("{authenticatorID}")
     @ACLMapping("authenticators.approve")
     @ClientResponseType(entityType=AuthenticatorData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response changeAuthenticatorStatus(
             @PathParam("authenticatorID") String authenticatorID,
             @QueryParam("action") String action);
@@ -87,6 +76,5 @@ public interface AuthenticatorResource {
     @Path("{authenticatorID}")
     @ClientResponseType(entityType=Void.class)
     @ACLMapping("authenticators.remove")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response removeAuthenticator(@PathParam("authenticatorID") String authenticatorID);
 }
diff --git a/base/common/src/com/netscape/certsrv/tps/cert/TPSCertResource.java b/base/common/src/com/netscape/certsrv/tps/cert/TPSCertResource.java
index 2ea24eed8e05d73c05c85962273caeb0c0b9f688..cf95dad893214812846a3d95ce56a3a4a65add21 100644
--- a/base/common/src/com/netscape/certsrv/tps/cert/TPSCertResource.java
+++ b/base/common/src/com/netscape/certsrv/tps/cert/TPSCertResource.java
@@ -20,9 +20,7 @@ package com.netscape.certsrv.tps.cert;
 import javax.ws.rs.GET;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -36,7 +34,6 @@ public interface TPSCertResource {
 
     @GET
     @ClientResponseType(entityType=TPSCertCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findCerts(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
@@ -44,6 +41,5 @@ public interface TPSCertResource {
     @GET
     @Path("{certID}")
     @ClientResponseType(entityType=TPSCertData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getCert(@PathParam("certID") String certID);
 }
diff --git a/base/common/src/com/netscape/certsrv/tps/config/ConfigResource.java b/base/common/src/com/netscape/certsrv/tps/config/ConfigResource.java
index 6c2187a2a1754effbf759e664c4a19c7d00c443f..a7f33fada74b35d3801057866353381833851fe4 100644
--- a/base/common/src/com/netscape/certsrv/tps/config/ConfigResource.java
+++ b/base/common/src/com/netscape/certsrv/tps/config/ConfigResource.java
@@ -17,12 +17,9 @@
 // --- END COPYRIGHT BLOCK ---
 package com.netscape.certsrv.tps.config;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.GET;
 import javax.ws.rs.PUT;
 import javax.ws.rs.Path;
-import javax.ws.rs.Produces;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -41,13 +38,10 @@ public interface ConfigResource {
 
     @GET
     @ClientResponseType(entityType=ConfigData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getConfig();
 
     @PUT
     @ClientResponseType(entityType=ConfigData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("config.modify")
     public Response updateConfig(ConfigData configData);
 }
diff --git a/base/common/src/com/netscape/certsrv/tps/connection/ConnectionResource.java b/base/common/src/com/netscape/certsrv/tps/connection/ConnectionResource.java
index 72334a04b81548ff09f1abdbd4d155771b349129..136cc8784059b566f8bcc2e0c0d14e6dad83c6b2 100644
--- a/base/common/src/com/netscape/certsrv/tps/connection/ConnectionResource.java
+++ b/base/common/src/com/netscape/certsrv/tps/connection/ConnectionResource.java
@@ -17,16 +17,13 @@
 // --- END COPYRIGHT BLOCK ---
 package com.netscape.certsrv.tps.connection;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.DELETE;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.PUT;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -45,7 +42,6 @@ public interface ConnectionResource {
 
     @GET
     @ClientResponseType(entityType=ConnectionCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findConnections(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
@@ -53,22 +49,17 @@ public interface ConnectionResource {
     @GET
     @Path("{connectionID}")
     @ClientResponseType(entityType=ConnectionData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getConnection(@PathParam("connectionID") String connectionID);
 
     @POST
     @ACLMapping("connections.add")
     @ClientResponseType(entityType=ConnectionData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response addConnection(ConnectionData connectionData);
 
     @PUT
     @Path("{connectionID}")
     @ACLMapping("connections.modify")
     @ClientResponseType(entityType=ConnectionData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response updateConnection(
             @PathParam("connectionID") String connectionID,
             ConnectionData connectionData);
@@ -77,8 +68,6 @@ public interface ConnectionResource {
     @Path("{connectionID}")
     @ACLMapping("connections.approve")
     @ClientResponseType(entityType=ConnectionData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response changeConnectionStatus(
             @PathParam("connectionID") String connectionID,
             @QueryParam("action") String action);
@@ -87,6 +76,5 @@ public interface ConnectionResource {
     @Path("{connectionID}")
     @ClientResponseType(entityType=Void.class)
     @ACLMapping("connections.remove")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response removeConnection(@PathParam("connectionID") String connectionID);
 }
diff --git a/base/common/src/com/netscape/certsrv/tps/profile/ProfileMappingResource.java b/base/common/src/com/netscape/certsrv/tps/profile/ProfileMappingResource.java
index 19d62bce0c6f6e32b7792f8f0c38014a2d562e3b..694a1810e4642c7b699a5e538cecfc32901bceb3 100644
--- a/base/common/src/com/netscape/certsrv/tps/profile/ProfileMappingResource.java
+++ b/base/common/src/com/netscape/certsrv/tps/profile/ProfileMappingResource.java
@@ -17,16 +17,13 @@
 // --- END COPYRIGHT BLOCK ---
 package com.netscape.certsrv.tps.profile;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.DELETE;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.PUT;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -45,7 +42,6 @@ public interface ProfileMappingResource {
 
     @GET
     @ClientResponseType(entityType=ProfileMappingCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findProfileMappings(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
@@ -53,22 +49,17 @@ public interface ProfileMappingResource {
     @GET
     @Path("{profileMappingID}")
     @ClientResponseType(entityType=ProfileMappingData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getProfileMapping(@PathParam("profileMappingID") String profileMappingID);
 
     @POST
     @ACLMapping("profile-mappings.add")
     @ClientResponseType(entityType=ProfileMappingData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response addProfileMapping(ProfileMappingData profileMappingData);
 
     @PUT
     @Path("{profileMappingID}")
     @ACLMapping("profile-mappings.modify")
     @ClientResponseType(entityType=ProfileMappingData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response updateProfileMapping(
             @PathParam("profileMappingID") String profileMappingID,
             ProfileMappingData profileMappingData);
@@ -77,8 +68,6 @@ public interface ProfileMappingResource {
     @Path("{profileMappingID}")
     @ACLMapping("profiles-mappings.approve")
     @ClientResponseType(entityType=ProfileMappingData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response changeProfileMappingStatus(
             @PathParam("profileMappingID") String profileMappingID,
             @QueryParam("action") String action);
@@ -87,6 +76,5 @@ public interface ProfileMappingResource {
     @Path("{profileMappingID}")
     @ClientResponseType(entityType=Void.class)
     @ACLMapping("profile-mappings.remove")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response removeProfileMapping(@PathParam("profileMappingID") String profileMappingID);
 }
diff --git a/base/common/src/com/netscape/certsrv/tps/profile/ProfileResource.java b/base/common/src/com/netscape/certsrv/tps/profile/ProfileResource.java
index 45e0520c495f588a2be429a3d8b082de04c2572e..4cb466f2f20d8f402f53704ed8853cfe91329d16 100644
--- a/base/common/src/com/netscape/certsrv/tps/profile/ProfileResource.java
+++ b/base/common/src/com/netscape/certsrv/tps/profile/ProfileResource.java
@@ -17,16 +17,13 @@
 // --- END COPYRIGHT BLOCK ---
 package com.netscape.certsrv.tps.profile;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.DELETE;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.PUT;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -45,7 +42,6 @@ public interface ProfileResource {
 
     @GET
     @ClientResponseType(entityType=ProfileCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findProfiles(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
@@ -53,22 +49,17 @@ public interface ProfileResource {
     @GET
     @Path("{profileID}")
     @ClientResponseType(entityType=ProfileData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getProfile(@PathParam("profileID") String profileID);
 
     @POST
     @ACLMapping("profiles.add")
     @ClientResponseType(entityType=ProfileData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response addProfile(ProfileData profileData);
 
     @PUT
     @Path("{profileID}")
     @ACLMapping("profiles.modify")
     @ClientResponseType(entityType=ProfileData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response updateProfile(
             @PathParam("profileID") String profileID,
             ProfileData profileData);
@@ -77,8 +68,6 @@ public interface ProfileResource {
     @Path("{profileID}")
     @ACLMapping("profiles.approve")
     @ClientResponseType(entityType=ProfileData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response changeProfileStatus(
             @PathParam("profileID") String profileID,
             @QueryParam("action") String action);
@@ -87,6 +76,5 @@ public interface ProfileResource {
     @Path("{profileID}")
     @ClientResponseType(entityType=Void.class)
     @ACLMapping("profiles.remove")
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response removeProfile(@PathParam("profileID") String profileID);
 }
diff --git a/base/common/src/com/netscape/certsrv/tps/token/TokenResource.java b/base/common/src/com/netscape/certsrv/tps/token/TokenResource.java
index 294ace128c36a1ae28e49a2ef64d36180254d7a6..f88ce399c9c4626b8677d20014ed8d94021a42ae 100644
--- a/base/common/src/com/netscape/certsrv/tps/token/TokenResource.java
+++ b/base/common/src/com/netscape/certsrv/tps/token/TokenResource.java
@@ -17,16 +17,13 @@
 // --- END COPYRIGHT BLOCK ---
 package com.netscape.certsrv.tps.token;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.DELETE;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.PUT;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -46,7 +43,6 @@ public interface TokenResource {
 
     @GET
     @ClientResponseType(entityType=TokenCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findTokens(
             @QueryParam("start") Integer start,
             @QueryParam("size") Integer size);
@@ -54,21 +50,16 @@ public interface TokenResource {
     @GET
     @Path("{tokenID}")
     @ClientResponseType(entityType=TokenData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getToken(@PathParam("tokenID") String tokenID);
 
     @POST
     @ClientResponseType(entityType=TokenData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("tokens.add")
     public Response addToken(TokenData tokenData);
 
     @PUT
     @Path("{tokenID}")
     @ClientResponseType(entityType=TokenData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("tokens.modify")
     public Response replaceToken(
             @PathParam("tokenID") String tokenID,
@@ -77,8 +68,6 @@ public interface TokenResource {
     @PATCH
     @Path("{tokenID}")
     @ClientResponseType(entityType=TokenData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("tokens.modify")
     public Response modifyToken(
             @PathParam("tokenID") String tokenID,
@@ -87,7 +76,6 @@ public interface TokenResource {
     @DELETE
     @Path("{tokenID}")
     @ClientResponseType(entityType=Void.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     @ACLMapping("tokens.remove")
     public Response removeToken(@PathParam("tokenID") String tokenID);
 }
diff --git a/base/common/src/com/netscape/certsrv/user/UserResource.java b/base/common/src/com/netscape/certsrv/user/UserResource.java
index cbda69a4cb68d298581bbc3db3fe3d5df5d08ab6..771750f311e50b3dc2c32152886b2aca2d4e094b 100644
--- a/base/common/src/com/netscape/certsrv/user/UserResource.java
+++ b/base/common/src/com/netscape/certsrv/user/UserResource.java
@@ -18,16 +18,13 @@
 
 package com.netscape.certsrv.user;
 
-import javax.ws.rs.Consumes;
 import javax.ws.rs.DELETE;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.PUT;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
 import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 
 import org.jboss.resteasy.annotations.ClientResponseType;
@@ -49,7 +46,6 @@ public interface UserResource {
 
     @GET
     @ClientResponseType(entityType=UserCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findUsers(
             @QueryParam("filter") String filter,
             @QueryParam("start") Integer start,
@@ -57,40 +53,31 @@ public interface UserResource {
 
     @POST
     @ClientResponseType(entityType=UserData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response addUser(UserData userData);
 
     @GET
     @Path("{userID}")
     @ClientResponseType(entityType=UserData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getUser(@PathParam("userID") String userID);
 
     @PUT
     @Path("{userID}")
     @ClientResponseType(entityType=UserData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response replaceUser(@PathParam("userID") String userID, UserData userData);
 
     @PATCH
     @Path("{userID}")
     @ClientResponseType(entityType=UserData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response modifyUser(@PathParam("userID") String userID, UserData userData);
 
     @DELETE
     @Path("{userID}")
     @ClientResponseType(entityType=Void.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response removeUser(@PathParam("userID") String userID);
 
     @GET
     @Path("{userID}/certs")
     @ClientResponseType(entityType=UserCertCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findUserCerts(
             @PathParam("userID") String userID,
             @QueryParam("start") Integer start,
@@ -100,26 +87,21 @@ public interface UserResource {
     @POST
     @Path("{userID}/certs")
     @ClientResponseType(entityType=UserCertData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response addUserCert(@PathParam("userID") String userID, UserCertData userCertData);
 
     @GET
     @Path("{userID}/certs/{certID}")
     @ClientResponseType(entityType=UserCertData.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response getUserCert(@PathParam("userID") String userID, @PathParam("certID") String certID);
 
     @DELETE
     @Path("{userID}/certs/{certID}")
     @ClientResponseType(entityType=Void.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response removeUserCert(@PathParam("userID") String userID, @PathParam("certID") String certID);
 
     @GET
     @Path("{userID}/memberships")
     @ClientResponseType(entityType=UserMembershipCollection.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response findUserMemberships(
             @PathParam("userID") String userID,
             @QueryParam("start") Integer start,
@@ -128,13 +110,10 @@ public interface UserResource {
     @POST
     @Path("{userID}/memberships")
     @ClientResponseType(entityType=UserMembershipData.class)
-    @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response addUserMembership(@PathParam("userID") String userID, String groupID);
 
     @DELETE
     @Path("{userID}/memberships/{groupID}")
     @ClientResponseType(entityType=Void.class)
-    @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
     public Response removeUserMembership(@PathParam("userID") String userID, @PathParam("groupID") String groupID);
 }
-- 
1.8.4.2

