summaryrefslogtreecommitdiffstats
path: root/base/common/src/com/netscape/certsrv/logging
diff options
context:
space:
mode:
authorEndi S. Dewata <edewata@redhat.com>2014-02-14 13:22:03 -0500
committerEndi S. Dewata <edewata@redhat.com>2014-02-18 11:35:25 -0500
commite4c002c7a47025ec99ee11f093749a2cc50f22d2 (patch)
treebd62ee2f477e5d8bf41cd0600c52dfdea39e222e /base/common/src/com/netscape/certsrv/logging
parent841672c941c1d1cb3ae7a4b2a678e7e5521bccf6 (diff)
downloadpki-e4c002c7a47025ec99ee11f093749a2cc50f22d2.tar.gz
pki-e4c002c7a47025ec99ee11f093749a2cc50f22d2.tar.xz
pki-e4c002c7a47025ec99ee11f093749a2cc50f22d2.zip
Updated REST interface for audit.
The REST interface for audit has been modified to return Response objects to allow better handling of server responses. Ticket #554
Diffstat (limited to 'base/common/src/com/netscape/certsrv/logging')
-rw-r--r--base/common/src/com/netscape/certsrv/logging/AuditClient.java3
-rw-r--r--base/common/src/com/netscape/certsrv/logging/AuditResource.java3
2 files changed, 4 insertions, 2 deletions
diff --git a/base/common/src/com/netscape/certsrv/logging/AuditClient.java b/base/common/src/com/netscape/certsrv/logging/AuditClient.java
index 959304d92..95d2c7fb4 100644
--- a/base/common/src/com/netscape/certsrv/logging/AuditClient.java
+++ b/base/common/src/com/netscape/certsrv/logging/AuditClient.java
@@ -41,7 +41,8 @@ public class AuditClient extends Client {
}
public AuditConfig getAuditConfig() {
- return resource.getAuditConfig();
+ Response response = resource.getAuditConfig();
+ return client.getEntity(response, AuditConfig.class);
}
public AuditConfig updateAuditConfig(AuditConfig auditConfig) {
diff --git a/base/common/src/com/netscape/certsrv/logging/AuditResource.java b/base/common/src/com/netscape/certsrv/logging/AuditResource.java
index 4b705a5f9..1220b89bc 100644
--- a/base/common/src/com/netscape/certsrv/logging/AuditResource.java
+++ b/base/common/src/com/netscape/certsrv/logging/AuditResource.java
@@ -35,8 +35,9 @@ import org.jboss.resteasy.annotations.ClientResponseType;
public interface AuditResource {
@GET
+ @ClientResponseType(entityType=AuditConfig.class)
@Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- public AuditConfig getAuditConfig();
+ public Response getAuditConfig();
@PUT
@ClientResponseType(entityType=AuditConfig.class)