yarn_service_protos.proto 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186
  1. /**
  2. * Licensed to the Apache Software Foundation (ASF) under one
  3. * or more contributor license agreements. See the NOTICE file
  4. * distributed with this work for additional information
  5. * regarding copyright ownership. The ASF licenses this file
  6. * to you under the Apache License, Version 2.0 (the
  7. * "License"); you may not use this file except in compliance
  8. * with the License. You may obtain a copy of the License at
  9. *
  10. * http://www.apache.org/licenses/LICENSE-2.0
  11. *
  12. * Unless required by applicable law or agreed to in writing, software
  13. * distributed under the License is distributed on an "AS IS" BASIS,
  14. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. * See the License for the specific language governing permissions and
  16. * limitations under the License.
  17. */
  18. /**
  19. * These .proto interfaces are public and stable.
  20. * Please see http://wiki.apache.org/hadoop/Compatibility
  21. * for what changes are allowed for a *stable* .proto interface.
  22. */
  23. option java_package = "org.apache.hadoop.yarn.proto";
  24. option java_outer_classname = "YarnServiceProtos";
  25. option java_generic_services = true;
  26. option java_generate_equals_and_hash = true;
  27. import "Security.proto";
  28. import "yarn_protos.proto";
  29. //////////////////////////////////////////////////////
  30. /////// AM_RM_Protocol ///////////////////////////////
  31. //////////////////////////////////////////////////////
  32. message RegisterApplicationMasterRequestProto {
  33. optional ApplicationAttemptIdProto application_attempt_id = 1;
  34. optional string host = 2;
  35. optional int32 rpc_port = 3;
  36. optional string tracking_url = 4;
  37. }
  38. message RegisterApplicationMasterResponseProto {
  39. optional ResourceProto maximumCapability = 1;
  40. optional bytes client_to_am_token_master_key = 2;
  41. repeated ApplicationACLMapProto application_ACLs = 3;
  42. }
  43. message FinishApplicationMasterRequestProto {
  44. optional ApplicationAttemptIdProto application_attempt_id = 1;
  45. optional string diagnostics = 2;
  46. optional string tracking_url = 3;
  47. optional FinalApplicationStatusProto final_application_status = 4;
  48. }
  49. message FinishApplicationMasterResponseProto {
  50. }
  51. message AllocateRequestProto {
  52. optional ApplicationAttemptIdProto application_attempt_id = 1;
  53. repeated ResourceRequestProto ask = 2;
  54. repeated ContainerIdProto release = 3;
  55. optional ResourceBlacklistRequestProto blacklist_request = 4;
  56. optional int32 response_id = 5;
  57. optional float progress = 6;
  58. }
  59. message NMTokenProto {
  60. optional NodeIdProto nodeId = 1;
  61. optional hadoop.common.TokenProto token = 2;
  62. }
  63. message AllocateResponseProto {
  64. optional AMCommandProto a_m_command = 1;
  65. optional int32 response_id = 2;
  66. repeated ContainerProto allocated_containers = 3;
  67. repeated ContainerStatusProto completed_container_statuses = 4;
  68. optional ResourceProto limit = 5;
  69. repeated NodeReportProto updated_nodes = 6;
  70. optional int32 num_cluster_nodes = 7;
  71. optional PreemptionMessageProto preempt = 8;
  72. repeated NMTokenProto nm_tokens = 9;
  73. }
  74. //////////////////////////////////////////////////////
  75. /////// client_RM_Protocol ///////////////////////////
  76. //////////////////////////////////////////////////////
  77. message GetNewApplicationRequestProto {
  78. }
  79. message GetNewApplicationResponseProto {
  80. optional ApplicationIdProto application_id = 1;
  81. optional ResourceProto maximumCapability = 2;
  82. }
  83. message GetApplicationReportRequestProto {
  84. optional ApplicationIdProto application_id = 1;
  85. }
  86. message GetApplicationReportResponseProto {
  87. optional ApplicationReportProto application_report = 1;
  88. }
  89. message SubmitApplicationRequestProto {
  90. optional ApplicationSubmissionContextProto application_submission_context= 1;
  91. }
  92. message SubmitApplicationResponseProto {
  93. }
  94. message KillApplicationRequestProto {
  95. optional ApplicationIdProto application_id = 1;
  96. }
  97. message KillApplicationResponseProto {
  98. }
  99. message GetClusterMetricsRequestProto {
  100. }
  101. message GetClusterMetricsResponseProto {
  102. optional YarnClusterMetricsProto cluster_metrics = 1;
  103. }
  104. message GetAllApplicationsRequestProto {
  105. }
  106. message GetAllApplicationsResponseProto {
  107. repeated ApplicationReportProto applications = 1;
  108. }
  109. message GetClusterNodesRequestProto {
  110. repeated NodeStateProto nodeStates = 1;
  111. }
  112. message GetClusterNodesResponseProto {
  113. repeated NodeReportProto nodeReports = 1;
  114. }
  115. message GetQueueInfoRequestProto {
  116. optional string queueName = 1;
  117. optional bool includeApplications = 2;
  118. optional bool includeChildQueues = 3;
  119. optional bool recursive = 4;
  120. }
  121. message GetQueueInfoResponseProto {
  122. optional QueueInfoProto queueInfo = 1;
  123. }
  124. message GetQueueUserAclsInfoRequestProto {
  125. }
  126. message GetQueueUserAclsInfoResponseProto {
  127. repeated QueueUserACLInfoProto queueUserAcls = 1;
  128. }
  129. //////////////////////////////////////////////////////
  130. /////// client_NM_Protocol ///////////////////////////
  131. //////////////////////////////////////////////////////
  132. message StartContainerRequestProto {
  133. optional ContainerLaunchContextProto container_launch_context = 1;
  134. optional hadoop.common.TokenProto container_token = 2;
  135. }
  136. message StartContainerResponseProto {
  137. repeated StringBytesMapProto services_meta_data = 1;
  138. }
  139. message StopContainerRequestProto {
  140. optional ContainerIdProto container_id = 1;
  141. }
  142. message StopContainerResponseProto {
  143. }
  144. message GetContainerStatusRequestProto {
  145. optional ContainerIdProto container_id = 1;
  146. }
  147. message GetContainerStatusResponseProto {
  148. optional ContainerStatusProto status = 1;
  149. }