Interface QueueApi


  • @Consumes("application/json")
    @Path("/queues")
    public interface QueueApi
    Provides access to Queues via their REST API.
    • Method Detail

      • create

        @Named("queue:create")
        @PUT
        @Path("/{name}")
        void create​(@PathParam("name")
                    String name)
        Create a queue.
        Parameters:
        name - Name of the queue. The name must not exceed 64 bytes in length, and it is limited to US-ASCII letters, digits, underscores, and hyphens.
      • delete

        @Named("queue:delete")
        @DELETE
        @Path("/{name}")
        boolean delete​(@PathParam("name")
                       String name)
        Delete a queue.
        Parameters:
        name - Name of the queue. The name must not exceed 64 bytes in length, and it is limited to US-ASCII letters, digits, underscores, and hyphens.
      • exists

        @Named("queue:get")
        @GET
        @Path("/{name}")
        boolean exists​(@PathParam("name")
                       String name)
        Check for a queue's existence.
        Parameters:
        name - Name of the queue. The name must not exceed 64 bytes in length, and it is limited to US-ASCII letters, digits, underscores, and hyphens.
      • list

        @Named("queue:list")
        @GET
        PagedIterable<Queue> list​(@QueryParam("detailed")
                                  boolean detailed)
        Lists the queues.
        Parameters:
        detailed - Determines whether queue metadata is included in the list.
      • list

        @Named("queue:list")
        @GET
        Queues list​(ListQueuesOptions options)
        Use this method to manually page through the list of queues.
      • setMetadata

        @Named("queue:setMetadata")
        @PUT
        @Path("/{name}/metadata")
        @Produces("application/json")
        void setMetadata​(@PathParam("name")
                         String name,
                         Map<String,​String> metadata)
        Sets metadata for the specified queue.

        The request body has a limit of 256 KB, excluding whitespace.

        This operation replaces any existing metadata document in its entirety. Ensure that you do not accidentally overwrite existing metadata that you want to retain.

        Parameters:
        name - Name of the queue. The name must not exceed 64 bytes in length, and it is limited to US-ASCII letters, digits, underscores, and hyphens.
        metadata - Metadata in key/value pairs.
      • getMetadata

        @Named("queue:getMetadata")
        @GET
        @Path("/{name}/metadata")
        Map<String,​String> getMetadata​(@PathParam("name")
                                             String name)
        Gets metadata for the specified queue.
        Parameters:
        name - Name of the queue. The name must not exceed 64 bytes in length, and it is limited to US-ASCII letters, digits, underscores, and hyphens.
      • getStats

        @Named("queue:getStats")
        @GET
        @Path("/{name}/stats")
        QueueStats getStats​(@PathParam("name")
                            String name)
        Gets stats for the specified queue.
        Parameters:
        name - Name of the queue. The name must not exceed 64 bytes in length, and it is limited to US-ASCII letters, digits, underscores, and hyphens.