diff options
| author | Ade Lee <alee@redhat.com> | 2016-06-10 22:18:03 -0400 |
|---|---|---|
| committer | Endi S. Dewata <edewata@redhat.com> | 2016-06-13 21:02:32 +0200 |
| commit | 2ff3c4d50a3ca3f66db097d2c15f46417ad5a3fc (patch) | |
| tree | 661d96cb6a6f2bfcc585889aed4c6f0e67ad6974 /base/common/src/com | |
| parent | 5f1bd9ce85dbe13ce8b40e6ffcf6812d6e54a12d (diff) | |
| download | pki-2ff3c4d50a3ca3f66db097d2c15f46417ad5a3fc.tar.gz pki-2ff3c4d50a3ca3f66db097d2c15f46417ad5a3fc.tar.xz pki-2ff3c4d50a3ca3f66db097d2c15f46417ad5a3fc.zip | |
Add man page and clarify CLI for kra-connector
Diffstat (limited to 'base/common/src/com')
| -rw-r--r-- | base/common/src/com/netscape/certsrv/system/KRAConnectorClient.java | 5 | ||||
| -rw-r--r-- | base/common/src/com/netscape/certsrv/system/KRAConnectorResource.java | 8 |
2 files changed, 7 insertions, 6 deletions
diff --git a/base/common/src/com/netscape/certsrv/system/KRAConnectorClient.java b/base/common/src/com/netscape/certsrv/system/KRAConnectorClient.java index 7abb1bde8..a9c5efdaa 100644 --- a/base/common/src/com/netscape/certsrv/system/KRAConnectorClient.java +++ b/base/common/src/com/netscape/certsrv/system/KRAConnectorClient.java @@ -46,6 +46,11 @@ public class KRAConnectorClient extends Client { client.getEntity(response, Void.class); } + public void addHost(String host, String port) { + Response response = kraConnectorClient.addHost(host, port); + client.getEntity(response, Void.class); + } + public void removeConnector(String host, String port) { Response response = kraConnectorClient.removeConnector(host, port); client.getEntity(response, Void.class); diff --git a/base/common/src/com/netscape/certsrv/system/KRAConnectorResource.java b/base/common/src/com/netscape/certsrv/system/KRAConnectorResource.java index 2bf2f1958..cf52c66b0 100644 --- a/base/common/src/com/netscape/certsrv/system/KRAConnectorResource.java +++ b/base/common/src/com/netscape/certsrv/system/KRAConnectorResource.java @@ -17,13 +17,10 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.system; -import javax.ws.rs.Consumes; -import javax.ws.rs.FormParam; import javax.ws.rs.GET; import javax.ws.rs.POST; import javax.ws.rs.Path; import javax.ws.rs.QueryParam; -import javax.ws.rs.core.MediaType; import javax.ws.rs.core.Response; import org.jboss.resteasy.annotations.ClientResponseType; @@ -50,10 +47,9 @@ public interface KRAConnectorResource { public Response removeConnector(@QueryParam("host") String host, @QueryParam("port") String port); @POST - @Path("remove") - @Consumes({ MediaType.APPLICATION_FORM_URLENCODED }) + @Path("addHost") @ClientResponseType(entityType=Void.class) - public Response removeConnectorForm(@FormParam("host") String host, @FormParam("port") String port); + public Response addHost(@QueryParam("host") String host, @QueryParam("port") String port); @GET @ClientResponseType(entityType = KRAConnectorInfo.class) |
