/**
 * Licensed to the Apache Software Foundation (ASF) under one
 * or more contributor license agreements.  See the NOTICE file
 * distributed with this work for additional information
 * regarding copyright ownership.  The ASF licenses this file
 * to you under the Apache License, Version 2.0 (the
 * "License"); you may not use this file except in compliance
 * with the License.  You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

option java_package = "org.apache.hadoop.mapreduce.v2.proto";
option java_outer_classname = "MRServiceProtos";
option java_generic_services = true;
option java_generate_equals_and_hash = true;

import "Security.proto";
import "mr_protos.proto";
import "yarn_protos.proto";

message GetJobReportRequestProto {
  optional JobIdProto job_id = 1;
}
message GetJobReportResponseProto {
  optional JobReportProto job_report = 1;
}

message GetTaskReportRequestProto {
  optional TaskIdProto task_id = 1;
}
message GetTaskReportResponseProto {
  optional TaskReportProto task_report = 1;
}

message GetTaskAttemptReportRequestProto {
  optional TaskAttemptIdProto task_attempt_id = 1;
}
message GetTaskAttemptReportResponseProto {
  optional TaskAttemptReportProto task_attempt_report = 1;
}

message GetCountersRequestProto {
  optional JobIdProto job_id = 1;
}
message GetCountersResponseProto {
  optional CountersProto counters = 1;
}

message GetTaskAttemptCompletionEventsRequestProto {
  optional JobIdProto job_id = 1;
  optional int32 from_event_id = 2;
  optional int32 max_events = 3;
}
message GetTaskAttemptCompletionEventsResponseProto {
  repeated TaskAttemptCompletionEventProto completion_events = 1;
}

message GetTaskReportsRequestProto {
  optional JobIdProto job_id = 1;
  optional TaskTypeProto task_type = 2;
}
message GetTaskReportsResponseProto {
  repeated TaskReportProto task_reports = 1;
}

message GetDiagnosticsRequestProto {
  optional TaskAttemptIdProto task_attempt_id = 1;
}
message GetDiagnosticsResponseProto {
  repeated string diagnostics = 1;
}

message KillJobRequestProto {
  optional JobIdProto job_id = 1;
}
message KillJobResponseProto {
}

message KillTaskRequestProto {
  optional TaskIdProto task_id = 1;
}
message KillTaskResponseProto {
}

message KillTaskAttemptRequestProto {
  optional TaskAttemptIdProto task_attempt_id = 1;
}
message KillTaskAttemptResponseProto {
}

message FailTaskAttemptRequestProto {
  optional TaskAttemptIdProto task_attempt_id = 1;
}
message FailTaskAttemptResponseProto {
}

