Class AdminService
- java.lang.Object
-
- org.objectweb.joram.tools.rest.admin.AdminService
-
- All Implemented Interfaces:
jakarta.ws.rs.container.ContainerRequestFilter
@Path("/") @Singleton public final class AdminService extends Object implements jakarta.ws.rs.container.ContainerRequestFilter
-
-
Field Summary
Fields Modifier and Type Field Description static StringADMINprivate static StringAUTHENTICATION_SCHEMEprivate static StringAUTHORIZATION_PROPERTYprivate static booleanDEBUGprivate AdminHelperhelperprivate jakarta.servlet.http.HttpServletRequesthttpServletRequestprivate static Loggerlogger
-
Constructor Summary
Constructors Constructor Description AdminService()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description jakarta.ws.rs.core.ResponsecreateLocalConnectionFactory(jakarta.ws.rs.core.HttpHeaders headers, String jndiName, jakarta.ws.rs.core.UriInfo uriInfo)jakarta.ws.rs.core.ResponsecreateQueue(jakarta.ws.rs.core.HttpHeaders headers, String destName, String className, int serverId, boolean freeReading, boolean freeWriting, boolean bind, String jndiName, jakarta.ws.rs.core.UriInfo uriInfo, String json)jakarta.ws.rs.core.ResponsecreateQueue(jakarta.ws.rs.core.HttpHeaders headers, String destName, String className, int serverId, jakarta.ws.rs.core.UriInfo uriInfo)jakarta.ws.rs.core.ResponsecreateTcpConnectionFactory(jakarta.ws.rs.core.HttpHeaders headers, String jndiName, String host, int port, String reliableClass, jakarta.ws.rs.core.UriInfo uriInfo)jakarta.ws.rs.core.ResponsecreateTopic(jakarta.ws.rs.core.HttpHeaders headers, String destName, String className, int serverId, boolean freeReading, boolean freeWriting, boolean bind, String jndiName, jakarta.ws.rs.core.UriInfo uriInfo, String json)jakarta.ws.rs.core.ResponsecreateTopic(jakarta.ws.rs.core.HttpHeaders headers, String destName, String className, int serverId, jakarta.ws.rs.core.UriInfo uriInfo)jakarta.ws.rs.core.ResponsecreateUser(jakarta.ws.rs.core.HttpHeaders headers, String userName, @NotNull String password, int serverId, String identityClassName, jakarta.ws.rs.core.UriInfo uriInfo, String json)jakarta.ws.rs.core.ResponsecreateUser(jakarta.ws.rs.core.HttpHeaders headers, String userName, @NotNull String password, jakarta.ws.rs.core.UriInfo uriInfo)jakarta.ws.rs.core.ResponsedeleteQueue(jakarta.ws.rs.core.HttpHeaders headers, String destName, int serverId, boolean unbind, String jndiName, jakarta.ws.rs.core.UriInfo uriInfo)jakarta.ws.rs.core.ResponsedeleteTopic(jakarta.ws.rs.core.HttpHeaders headers, String destName, int serverId, boolean unbind, String jndiName, jakarta.ws.rs.core.UriInfo uriInfo)jakarta.ws.rs.core.ResponsedeleteUser(jakarta.ws.rs.core.HttpHeaders headers, String userName, @NotNull String password, int serverId, jakarta.ws.rs.core.UriInfo uriInfo)voidfilter(jakarta.ws.rs.container.ContainerRequestContext requestContext)Stringinfo(jakarta.ws.rs.core.UriInfo uriInfo)StringlistQueue(jakarta.ws.rs.core.HttpHeaders headers, int serverId, jakarta.ws.rs.core.UriInfo uriInfo)StringlistTopic(jakarta.ws.rs.core.HttpHeaders headers, int serverId, jakarta.ws.rs.core.UriInfo uriInfo)static voidlogLinks(jakarta.ws.rs.core.Response.ResponseBuilder builder)
-
-
-
Field Detail
-
logger
private static final Logger logger
-
DEBUG
private static final boolean DEBUG
-
AUTHORIZATION_PROPERTY
private static final String AUTHORIZATION_PROPERTY
- See Also:
- Constant Field Values
-
AUTHENTICATION_SCHEME
private static final String AUTHENTICATION_SCHEME
- See Also:
- Constant Field Values
-
helper
private final AdminHelper helper
-
ADMIN
public static final String ADMIN
- See Also:
- Constant Field Values
-
httpServletRequest
@Context private jakarta.servlet.http.HttpServletRequest httpServletRequest
-
-
Method Detail
-
logLinks
public static void logLinks(jakarta.ws.rs.core.Response.ResponseBuilder builder)
-
info
@GET @Produces("text/html") public String info(@Context jakarta.ws.rs.core.UriInfo uriInfo)
-
createTcpConnectionFactory
@GET @Path("/tcp/create") @Produces("text/plain") public jakarta.ws.rs.core.Response createTcpConnectionFactory(@Context jakarta.ws.rs.core.HttpHeaders headers, @QueryParam("jndi-name") String jndiName, @QueryParam("host") String host, @QueryParam("port") int port, @DefaultValue("org.objectweb.joram.client.jms.tcp.ReliableTcpClient") @QueryParam("reliable-class") String reliableClass, @Context jakarta.ws.rs.core.UriInfo uriInfo)
-
createLocalConnectionFactory
@GET @Path("/local/create") @Produces("text/plain") public jakarta.ws.rs.core.Response createLocalConnectionFactory(@Context jakarta.ws.rs.core.HttpHeaders headers, @QueryParam("jndi-name") String jndiName, @Context jakarta.ws.rs.core.UriInfo uriInfo)
-
listQueue
@GET @Path("/queue") @Produces("text/plain") public String listQueue(@Context jakarta.ws.rs.core.HttpHeaders headers, @QueryParam("server-id") int serverId, @Context jakarta.ws.rs.core.UriInfo uriInfo) throws ConnectException, AdminException- Throws:
ConnectExceptionAdminException
-
createQueue
@GET @Path("/queue/{destName}") @Produces("text/plain") public jakarta.ws.rs.core.Response createQueue(@Context jakarta.ws.rs.core.HttpHeaders headers, @PathParam("destName") String destName, @DefaultValue("org.objectweb.joram.mom.dest.Queue") @QueryParam("class-name") String className, @QueryParam("server-id") int serverId, @Context jakarta.ws.rs.core.UriInfo uriInfo)
-
createQueue
@POST @Path("/queue/{destName}") @Produces("text/plain") @Consumes("application/json") public jakarta.ws.rs.core.Response createQueue(@Context jakarta.ws.rs.core.HttpHeaders headers, @PathParam("destName") String destName, @DefaultValue("org.objectweb.joram.mom.dest.Queue") @QueryParam("class-name") String className, @DefaultValue("-1") @QueryParam("server-id") int serverId, @DefaultValue("false") @QueryParam("free-reading") boolean freeReading, @DefaultValue("false") @QueryParam("free-writing") boolean freeWriting, @DefaultValue("true") @QueryParam("jndi-bind") boolean bind, @QueryParam("jndi-name") String jndiName, @Context jakarta.ws.rs.core.UriInfo uriInfo, String json)
-
listTopic
@GET @Path("/topic") @Produces("text/plain") public String listTopic(@Context jakarta.ws.rs.core.HttpHeaders headers, @QueryParam("server-id") int serverId, @Context jakarta.ws.rs.core.UriInfo uriInfo) throws ConnectException, AdminException- Throws:
ConnectExceptionAdminException
-
createTopic
@GET @Path("/topic/{destName}") @Produces("text/plain") public jakarta.ws.rs.core.Response createTopic(@Context jakarta.ws.rs.core.HttpHeaders headers, @PathParam("destName") String destName, @DefaultValue("org.objectweb.joram.mom.dest.Topic") @QueryParam("class-name") String className, @QueryParam("server-id") int serverId, @Context jakarta.ws.rs.core.UriInfo uriInfo)
-
createTopic
@POST @Path("/topic/{destName}") @Produces("text/plain") @Consumes("application/json") public jakarta.ws.rs.core.Response createTopic(@Context jakarta.ws.rs.core.HttpHeaders headers, @PathParam("destName") String destName, @DefaultValue("org.objectweb.joram.mom.dest.Topic") @QueryParam("class-name") String className, @QueryParam("server-id") int serverId, @DefaultValue("false") @QueryParam("free-reading") boolean freeReading, @DefaultValue("false") @QueryParam("free-writing") boolean freeWriting, @DefaultValue("true") @QueryParam("jndi-bind") boolean bind, @QueryParam("jndi-name") String jndiName, @Context jakarta.ws.rs.core.UriInfo uriInfo, String json)
-
createUser
@GET @Path("/user/{userName}") @Produces("text/plain") public jakarta.ws.rs.core.Response createUser(@Context jakarta.ws.rs.core.HttpHeaders headers, @PathParam("userName") String userName, @NotNull @QueryParam("password") @NotNull String password, @Context jakarta.ws.rs.core.UriInfo uriInfo)
-
createUser
@POST @Path("/user/{userName}") @Produces("text/plain") @Consumes("application/json") public jakarta.ws.rs.core.Response createUser(@Context jakarta.ws.rs.core.HttpHeaders headers, @PathParam("userName") String userName, @NotNull @QueryParam("password") @NotNull String password, @DefaultValue("-1") @QueryParam("server-id") int serverId, @DefaultValue("org.objectweb.joram.shared.security.SimpleIdentity") @QueryParam("identity-class-name") String identityClassName, @Context jakarta.ws.rs.core.UriInfo uriInfo, String json)
-
deleteUser
@DELETE @Path("/user/{userName}") @Produces("text/plain") public jakarta.ws.rs.core.Response deleteUser(@Context jakarta.ws.rs.core.HttpHeaders headers, @PathParam("userName") String userName, @NotNull @QueryParam("password") @NotNull String password, @DefaultValue("-1") @QueryParam("server-id") int serverId, @Context jakarta.ws.rs.core.UriInfo uriInfo)
-
deleteQueue
@DELETE @Path("/queue/{destName}") @Produces("text/plain") public jakarta.ws.rs.core.Response deleteQueue(@Context jakarta.ws.rs.core.HttpHeaders headers, @PathParam("destName") String destName, @DefaultValue("-1") @QueryParam("server-id") int serverId, @DefaultValue("true") @QueryParam("jndi-unbind") boolean unbind, @QueryParam("jndi-name") String jndiName, @Context jakarta.ws.rs.core.UriInfo uriInfo)
-
deleteTopic
@DELETE @Path("/topic/{destName}") @Produces("text/plain") public jakarta.ws.rs.core.Response deleteTopic(@Context jakarta.ws.rs.core.HttpHeaders headers, @PathParam("destName") String destName, @DefaultValue("-1") @QueryParam("server-id") int serverId, @DefaultValue("true") @QueryParam("jndi-unbind") boolean unbind, @QueryParam("jndi-name") String jndiName, @Context jakarta.ws.rs.core.UriInfo uriInfo)
-
filter
public void filter(jakarta.ws.rs.container.ContainerRequestContext requestContext) throws IOException- Specified by:
filterin interfacejakarta.ws.rs.container.ContainerRequestFilter- Throws:
IOException
-
-