Package org.apache.aurora.gen

Examples of org.apache.aurora.gen.TaskQuery


    Response response = new Response()
        .setResponseCode(OK)
        .setResult(Result.scheduleStatusResult(new ScheduleStatusResult()
            .setTasks(ImmutableList.of(task))));

    TaskQuery query = new TaskQuery()
        .setStatuses(ImmutableSet.of(RUNNING))
        .setTaskIds(ImmutableSet.of("a"));

    expect(thrift.getTasksStatus(query)).andReturn(response);
View Full Code Here


    assertQueryResults(Query.jobScoped(JobKeys.from("role-b", "env-b", "job-b")).active(), TASK_B);
    assertQueryResults(Query.jobScoped(JobKeys.from("role-b", "devel", "job-b")).active());

    // Explicitly call out the current differing behaviors for types of empty query conditions.
    // Specifically - null task IDs and empty task IDs are different than other 'IN' conditions..
    assertQueryResults(new TaskQuery().setTaskIds(null), TASK_A, TASK_B, TASK_C, TASK_D);
    assertQueryResults(new TaskQuery().setTaskIds(ImmutableSet.<String>of()));
    assertQueryResults(
        new TaskQuery().setInstanceIds(ImmutableSet.<Integer>of()),
        TASK_A, TASK_B, TASK_C, TASK_D);
    assertQueryResults(
        new TaskQuery().setStatuses(ImmutableSet.<ScheduleStatus>of()),
        TASK_A, TASK_B, TASK_C, TASK_D);
  }
View Full Code Here

TOP

Related Classes of org.apache.aurora.gen.TaskQuery

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.