Package org.apache.hadoop.chukwa.rest.objects

Examples of org.apache.hadoop.chukwa.rest.objects.MrTask


    // get one object
    @GET
    @Path("task_id/{task_id}")
    @Produces({"application/xml","text/xml"})
    public String getByTask_IdXML( @PathParam ("task_id") String task_id) {
  MrTask model = MrTaskHome.find(task_id);
  return convertToXml(model);
    }
View Full Code Here


   
    @GET
    @Path("task_id/{task_id}")
    @Produces("application/json")
    public String getByTask_IdJason( @PathParam ("task_id") String task_id) {
  MrTask model = MrTaskHome.find(task_id);
  return convertToJson(model);
    }
View Full Code Here

   
    @GET
    @Path("task_id/{task_id}")
    @Produces({"text/plain","text/csv"})
    public String getByTask_IdCsv( @PathParam ("task_id") String task_id) {
  MrTask model = MrTaskHome.find(task_id);
  return convertToCsv(model);
    }
View Full Code Here

    private static String table="[mr_task]";
    private static final Log log = LogFactory
  .getLog(MrTaskHome.class);

    private static MrTask createMrTask(ResultSet rs) {
  MrTask obj = null;
  try {
      obj = new MrTask(

        rs.getString("task_id"),
        rs.getString("job_id"),
        rs.getTimestamp("start_time"),
        rs.getTimestamp("finish_time"),
View Full Code Here

      // get simple value
            try {
    String query = getSingleQuery(MrTaskHome.table,"task_id",task_id);
        ResultSet rs = dbw.query(query);
        if (rs.next()) {
        MrTask obj = createMrTask(rs);
        return obj;
    }
      } catch (Exception e) {
    log.error("exception:"+e.toString());
      }
View Full Code Here

TOP

Related Classes of org.apache.hadoop.chukwa.rest.objects.MrTask

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.