public class

JobQueueResource

extends ServerResource
java.lang.Object
   ↳ org.restlet.resource.Resource
     ↳ org.restlet.resource.ServerResource
       ↳ org.apache.helix.webapp.resources.JobQueueResource

Class Overview

Class for server-side resource at "/clusters/{clusterName}/jobQueues/{jobQueue}"

  • GET list job queue info
  • POST start a new job in a job queue, or stop/resume/flush/delete a job queue

  • Summary

    Public Constructors
    JobQueueResource()
    Public Methods
    Representation get()
    List job queue info

    Usage: curl http://{host:port}/clusters/{clusterName}/jobQueues/{jobQueue}

    Representation post(Representation entity)
    Start a new job in a job queue, or stop/resume/flush/delete a job queue

    Usage:

  • Start a new job in a job queue: curl -d @'./{input.txt}' -H 'Content-Type: application/json' http://{host:port}/clusters/{clusterName}/jobQueues/{jobQueue}

    input.txt: jsonParameters={"command":"start"}&newJob={newJobConfig.yaml}

    For newJobConfig.yaml, see parse(String)

  • Stop/resume/flush/delete a job queue: curl -d 'jsonParameters={"command":"{stop/resume/flush/delete}"}' -H "Content-Type: application/json" http://{host:port}/clusters/{clusterName}/jobQueues/{jobQueue}
  • [Expand]
    Inherited Methods
    From class org.restlet.resource.ServerResource
    From class org.restlet.resource.Resource
    From class java.lang.Object

    Public Constructors

    public JobQueueResource ()

    Public Methods

    public Representation get ()

    List job queue info

    Usage: curl http://{host:port}/clusters/{clusterName}/jobQueues/{jobQueue}

    public Representation post (Representation entity)

    Start a new job in a job queue, or stop/resume/flush/delete a job queue

    Usage:

  • Start a new job in a job queue: curl -d @'./{input.txt}' -H 'Content-Type: application/json' http://{host:port}/clusters/{clusterName}/jobQueues/{jobQueue}

    input.txt: jsonParameters={"command":"start"}&newJob={newJobConfig.yaml}

    For newJobConfig.yaml, see parse(String)

  • Stop/resume/flush/delete a job queue: curl -d 'jsonParameters={"command":"{stop/resume/flush/delete}"}' -H "Content-Type: application/json" http://{host:port}/clusters/{clusterName}/jobQueues/{jobQueue}