hadoop-yarn-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vino...@apache.org
Subject svn commit: r1489644 [1/3] - in /hadoop/common/trunk/hadoop-yarn-project: ./ hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/ hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl...
Date Tue, 04 Jun 2013 21:52:30 GMT
Author: vinodkv
Date: Tue Jun  4 21:52:11 2013
New Revision: 1489644

URL: http://svn.apache.org/r1489644
Log:
YARN-753. Added individual factory methods for all api protocol records and converted the records to be abstract classes. Contributed by Jian He.

Modified:
    hadoop/common/trunk/hadoop-yarn-project/CHANGES.txt
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/CancelDelegationTokenRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/CancelDelegationTokenResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/FinishApplicationMasterRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/FinishApplicationMasterResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetAllApplicationsRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetAllApplicationsResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetApplicationReportRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetApplicationReportResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterMetricsRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterMetricsResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterNodesRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterNodesResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetContainerStatusRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetContainerStatusResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetDelegationTokenRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetDelegationTokenResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetNewApplicationRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetNewApplicationResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueInfoRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueInfoResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueUserAclsInfoRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueUserAclsInfoResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/KillApplicationRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/KillApplicationResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshAdminAclsRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshAdminAclsResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshNodesRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshNodesResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshQueuesRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshQueuesResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshServiceAclsRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshServiceAclsResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshSuperUserGroupsConfigurationRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshSuperUserGroupsConfigurationResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshUserToGroupsMappingsRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshUserToGroupsMappingsResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RegisterApplicationMasterRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RegisterApplicationMasterResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RenewDelegationTokenRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RenewDelegationTokenResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/StartContainerRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/StartContainerResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/StopContainerRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/StopContainerResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/SubmitApplicationRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/SubmitApplicationResponse.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/CancelDelegationTokenRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/CancelDelegationTokenResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/FinishApplicationMasterRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/FinishApplicationMasterResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetAllApplicationsRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetAllApplicationsResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetApplicationReportRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetApplicationReportResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetClusterMetricsRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetClusterMetricsResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetClusterNodesRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetClusterNodesResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetContainerStatusRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetContainerStatusResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetDelegationTokenRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetDelegationTokenResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetNewApplicationRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetNewApplicationResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetQueueInfoRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetQueueInfoResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetQueueUserAclsInfoRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/GetQueueUserAclsInfoResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/KillApplicationRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/KillApplicationResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshAdminAclsRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshAdminAclsResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshNodesRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshNodesResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshQueuesRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshQueuesResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshServiceAclsRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshServiceAclsResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshSuperUserGroupsConfigurationRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshSuperUserGroupsConfigurationResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshUserToGroupsMappingsRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RefreshUserToGroupsMappingsResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RegisterApplicationMasterRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RegisterApplicationMasterResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RenewDelegationTokenRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/RenewDelegationTokenResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/StartContainerRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/StartContainerResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/StopContainerRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/StopContainerResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/SubmitApplicationRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/impl/pb/SubmitApplicationResponsePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/records/PreemptionResourceRequest.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/records/impl/pb/PreemptionContainerPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/records/impl/pb/PreemptionContractPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/records/impl/pb/PreemptionMessagePBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/records/impl/pb/PreemptionResourceRequestPBImpl.java
    hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/records/impl/pb/StrictPreemptionContractPBImpl.java

Modified: hadoop/common/trunk/hadoop-yarn-project/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/CHANGES.txt?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/CHANGES.txt (original)
+++ hadoop/common/trunk/hadoop-yarn-project/CHANGES.txt Tue Jun  4 21:52:11 2013
@@ -96,6 +96,9 @@ Release 2.1.0-beta - UNRELEASED
     YARN-755. Renamed AllocateResponse.reboot to AllocateResponse.resync. (Bikas
     Saha via vinodkv)
 
+    YARN-753. Added individual factory methods for all api protocol records and
+    converted the records to be abstract classes. (Jian He via vinodkv)
+
   NEW FEATURES
 
     YARN-482. FS: Extend SchedulingMode to intermediate queues. 

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/CancelDelegationTokenRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/CancelDelegationTokenRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/CancelDelegationTokenRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/CancelDelegationTokenRequest.java Tue Jun  4 21:52:11 2013
@@ -21,6 +21,7 @@ package org.apache.hadoop.yarn.api.proto
 import org.apache.hadoop.classification.InterfaceAudience.Public;
 import org.apache.hadoop.classification.InterfaceStability.Evolving;
 import org.apache.hadoop.yarn.api.records.Token;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * The request issued by the client to the {@code ResourceManager} to cancel a
@@ -28,7 +29,15 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Evolving
-public interface CancelDelegationTokenRequest {
-  Token getDelegationToken();
-  void setDelegationToken(Token dToken);
+public abstract class CancelDelegationTokenRequest {
+
+  public static CancelDelegationTokenRequest newInstance(Token dToken) {
+    CancelDelegationTokenRequest request =
+        Records.newRecord(CancelDelegationTokenRequest.class);
+    request.setDelegationToken(dToken);
+    return request;
+  }
+
+  public abstract Token getDelegationToken();
+  public abstract void setDelegationToken(Token dToken);
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/CancelDelegationTokenResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/CancelDelegationTokenResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/CancelDelegationTokenResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/CancelDelegationTokenResponse.java Tue Jun  4 21:52:11 2013
@@ -20,6 +20,7 @@ package org.apache.hadoop.yarn.api.proto
 
 import org.apache.hadoop.classification.InterfaceAudience.Public;
 import org.apache.hadoop.classification.InterfaceStability.Evolving;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * The response from the {@code ResourceManager} to a cancelDelegationToken
@@ -27,5 +28,10 @@ import org.apache.hadoop.classification.
  */
 @Public
 @Evolving
-public interface CancelDelegationTokenResponse {
+public abstract class CancelDelegationTokenResponse {
+  public static CancelDelegationTokenResponse newInstance() {
+    CancelDelegationTokenResponse response =
+        Records.newRecord(CancelDelegationTokenResponse.class);
+    return response;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/FinishApplicationMasterRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/FinishApplicationMasterRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/FinishApplicationMasterRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/FinishApplicationMasterRequest.java Tue Jun  4 21:52:11 2013
@@ -23,6 +23,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.yarn.api.AMRMProtocol;
 import org.apache.hadoop.yarn.api.records.ApplicationAttemptId;
 import org.apache.hadoop.yarn.api.records.FinalApplicationStatus;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The finalization request sent by the <code>ApplicationMaster</code> to
@@ -45,7 +46,19 @@ import org.apache.hadoop.yarn.api.record
  *
  * @see AMRMProtocol#finishApplicationMaster(FinishApplicationMasterRequest)
  */
-public interface FinishApplicationMasterRequest {
+public abstract class FinishApplicationMasterRequest {
+
+  public static FinishApplicationMasterRequest newInstance(
+      ApplicationAttemptId appAttemptId, FinalApplicationStatus finalAppStatus,
+      String diagnostics, String url) {
+    FinishApplicationMasterRequest request =
+        Records.newRecord(FinishApplicationMasterRequest.class);
+    request.setAppAttemptId(appAttemptId);
+    request.setFinishApplicationStatus(finalAppStatus);
+    request.setDiagnostics(diagnostics);
+    request.setTrackingUrl(url);
+    return request;
+  }
 
   /**
    * Get the <code>ApplicationAttemptId</code> being managed by the
@@ -55,7 +68,7 @@ public interface FinishApplicationMaster
    */
   @Public
   @Stable
-  ApplicationAttemptId getApplicationAttemptId();
+  public abstract ApplicationAttemptId getApplicationAttemptId();
 
   /**
    * Set the <code>ApplicationAttemptId</code> being managed by the
@@ -65,7 +78,7 @@ public interface FinishApplicationMaster
    */
   @Public
   @Stable
-  void setAppAttemptId(ApplicationAttemptId applicationAttemptId);
+  public abstract void setAppAttemptId(ApplicationAttemptId applicationAttemptId);
 
   /**
    * Get <em>final state</em> of the <code>ApplicationMaster</code>.
@@ -73,7 +86,7 @@ public interface FinishApplicationMaster
    */
   @Public
   @Stable
-  FinalApplicationStatus getFinalApplicationStatus();
+  public abstract FinalApplicationStatus getFinalApplicationStatus();
 
   /**
    * Set the <em>finish state</em> of the <code>ApplicationMaster</code>
@@ -81,7 +94,7 @@ public interface FinishApplicationMaster
    */
   @Public
   @Stable
-  void setFinishApplicationStatus(FinalApplicationStatus finishState);
+  public abstract void setFinishApplicationStatus(FinalApplicationStatus finishState);
 
   /**
    * Get <em>diagnostic information</em> on application failure.
@@ -89,7 +102,7 @@ public interface FinishApplicationMaster
    */
   @Public
   @Stable
-  String getDiagnostics();
+  public abstract String getDiagnostics();
 
   /**
    * Set <em>diagnostic information</em> on application failure.
@@ -97,7 +110,7 @@ public interface FinishApplicationMaster
    */
   @Public
   @Stable
-  void setDiagnostics(String diagnostics);
+  public abstract void setDiagnostics(String diagnostics);
 
   /**
    * Get the <em>tracking URL</em> for the <code>ApplicationMaster</code>.
@@ -105,7 +118,7 @@ public interface FinishApplicationMaster
    */
   @Public
   @Stable
-  String getTrackingUrl();
+  public abstract String getTrackingUrl();
 
   /**
    * Set the <em>tracking URL</em>for the <code>ApplicationMaster</code>
@@ -114,6 +127,6 @@ public interface FinishApplicationMaster
    */
   @Public
   @Stable
-  void setTrackingUrl(String url);
+  public abstract void setTrackingUrl(String url);
 
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/FinishApplicationMasterResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/FinishApplicationMasterResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/FinishApplicationMasterResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/FinishApplicationMasterResponse.java Tue Jun  4 21:52:11 2013
@@ -21,6 +21,7 @@ package org.apache.hadoop.yarn.api.proto
 import org.apache.hadoop.classification.InterfaceAudience.Public;
 import org.apache.hadoop.classification.InterfaceStability.Stable;
 import org.apache.hadoop.yarn.api.AMRMProtocol;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>ResourceManager</code> to a 
@@ -32,6 +33,10 @@ import org.apache.hadoop.yarn.api.AMRMPr
  */
 @Public
 @Stable
-public interface FinishApplicationMasterResponse {
-
+public abstract class FinishApplicationMasterResponse {
+  public static FinishApplicationMasterResponse newInstance() {
+    FinishApplicationMasterResponse response =
+        Records.newRecord(FinishApplicationMasterResponse.class);
+    return response;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetAllApplicationsRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetAllApplicationsRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetAllApplicationsRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetAllApplicationsRequest.java Tue Jun  4 21:52:11 2013
@@ -21,6 +21,7 @@ package org.apache.hadoop.yarn.api.proto
 import org.apache.hadoop.classification.InterfaceAudience.Public;
 import org.apache.hadoop.classification.InterfaceStability.Stable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The request from clients to get a report of all Applications
@@ -32,5 +33,10 @@ import org.apache.hadoop.yarn.api.Client
  */
 @Public
 @Stable
-public interface GetAllApplicationsRequest {
+public abstract class GetAllApplicationsRequest {
+  public static GetAllApplicationsRequest newInstance() {
+    GetAllApplicationsRequest request =
+        Records.newRecord(GetAllApplicationsRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetAllApplicationsResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetAllApplicationsResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetAllApplicationsResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetAllApplicationsResponse.java Tue Jun  4 21:52:11 2013
@@ -26,6 +26,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.classification.InterfaceStability.Unstable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
 import org.apache.hadoop.yarn.api.records.ApplicationReport;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>ResourceManager</code> to a client
@@ -40,16 +41,25 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetAllApplicationsResponse {
+public abstract class GetAllApplicationsResponse {
+
+  public static GetAllApplicationsResponse newInstance(
+      List<ApplicationReport> applications) {
+    GetAllApplicationsResponse response =
+        Records.newRecord(GetAllApplicationsResponse.class);
+    response.setApplicationList(applications);
+    return response;
+  }
+
   /**
    * Get <code>ApplicationReport</code> for all applications.
    * @return <code>ApplicationReport</code> for all applications
    */
   @Public
   @Stable
-  List<ApplicationReport> getApplicationList();
+  public abstract List<ApplicationReport> getApplicationList();
   
   @Private
   @Unstable
-  void setApplicationList(List<ApplicationReport> applications);
+  public abstract void setApplicationList(List<ApplicationReport> applications);
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetApplicationReportRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetApplicationReportRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetApplicationReportRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetApplicationReportRequest.java Tue Jun  4 21:52:11 2013
@@ -23,6 +23,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
 import org.apache.hadoop.yarn.api.records.ApplicationId;
 import org.apache.hadoop.yarn.api.records.ApplicationReport;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The request sent by a client to the <code>ResourceManager</code> to 
@@ -36,16 +37,25 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetApplicationReportRequest {
+public abstract class GetApplicationReportRequest {
+
+  public static GetApplicationReportRequest newInstance(
+      ApplicationId applicationId) {
+    GetApplicationReportRequest request =
+        Records.newRecord(GetApplicationReportRequest.class);
+    request.setApplicationId(applicationId);
+    return request;
+  }
+
   /**
    * Get the <code>ApplicationId</code> of the application.
    * @return <code>ApplicationId</code> of the application
    */
-  public ApplicationId getApplicationId();
+  public abstract ApplicationId getApplicationId();
   
   /**
    * Set the <code>ApplicationId</code> of the application
    * @param applicationId <code>ApplicationId</code> of the application
    */
-  public void setApplicationId(ApplicationId applicationId);
+  public abstract void setApplicationId(ApplicationId applicationId);
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetApplicationReportResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetApplicationReportResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetApplicationReportResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetApplicationReportResponse.java Tue Jun  4 21:52:11 2013
@@ -24,6 +24,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.classification.InterfaceStability.Unstable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
 import org.apache.hadoop.yarn.api.records.ApplicationReport;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>ResourceManager</code> to a client
@@ -37,16 +38,25 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetApplicationReportResponse {
+public abstract class GetApplicationReportResponse {
+
+  public static GetApplicationReportResponse newInstance(
+      ApplicationReport ApplicationReport) {
+    GetApplicationReportResponse response =
+        Records.newRecord(GetApplicationReportResponse.class);
+    response.setApplicationReport(ApplicationReport);
+    return response;
+  }
+
   /**
    * Get the <code>ApplicationReport</code> for the application.
    * @return <code>ApplicationReport</code> for the application
    */
   @Public
   @Stable
-  public ApplicationReport getApplicationReport();
+  public abstract ApplicationReport getApplicationReport();
   
   @Private
   @Unstable
-  public void setApplicationReport(ApplicationReport ApplicationReport);
+  public abstract void setApplicationReport(ApplicationReport ApplicationReport);
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterMetricsRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterMetricsRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterMetricsRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterMetricsRequest.java Tue Jun  4 21:52:11 2013
@@ -21,6 +21,7 @@ package org.apache.hadoop.yarn.api.proto
 import org.apache.hadoop.classification.InterfaceAudience.Public;
 import org.apache.hadoop.classification.InterfaceStability.Stable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The request sent by clients to get cluster metrics from the 
@@ -32,6 +33,10 @@ import org.apache.hadoop.yarn.api.Client
  */
 @Public
 @Stable
-public interface GetClusterMetricsRequest {
-
+public abstract class GetClusterMetricsRequest {
+  public static GetClusterMetricsRequest newInstance() {
+    GetClusterMetricsRequest request =
+        Records.newRecord(GetClusterMetricsRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterMetricsResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterMetricsResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterMetricsResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterMetricsResponse.java Tue Jun  4 21:52:11 2013
@@ -24,6 +24,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.classification.InterfaceStability.Unstable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
 import org.apache.hadoop.yarn.api.records.YarnClusterMetrics;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>ResourceManager</code> to a client
@@ -34,16 +35,25 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetClusterMetricsResponse {
+public abstract class GetClusterMetricsResponse {
+
+  public static GetClusterMetricsResponse
+      newInstance(YarnClusterMetrics metrics) {
+    GetClusterMetricsResponse response =
+        Records.newRecord(GetClusterMetricsResponse.class);
+    response.setClusterMetrics(metrics);
+    return response;
+  }
+
   /**
    * Get the <code>YarnClusterMetrics</code> for the cluster.
    * @return <code>YarnClusterMetrics</code> for the cluster
    */
   @Public
   @Stable
-  public YarnClusterMetrics getClusterMetrics();
+  public abstract YarnClusterMetrics getClusterMetrics();
   
   @Private
   @Unstable
-  public void setClusterMetrics(YarnClusterMetrics metrics);
+  public abstract void setClusterMetrics(YarnClusterMetrics metrics);
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterNodesRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterNodesRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterNodesRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterNodesRequest.java Tue Jun  4 21:52:11 2013
@@ -21,6 +21,7 @@ package org.apache.hadoop.yarn.api.proto
 import org.apache.hadoop.classification.InterfaceAudience.Public;
 import org.apache.hadoop.classification.InterfaceStability.Stable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The request from clients to get a report of all nodes
@@ -32,6 +33,10 @@ import org.apache.hadoop.yarn.api.Client
  */
 @Public
 @Stable
-public interface GetClusterNodesRequest {
-
+public abstract class GetClusterNodesRequest {
+  public static GetClusterNodesRequest newInstance() {
+    GetClusterNodesRequest request =
+        Records.newRecord(GetClusterNodesRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterNodesResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterNodesResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterNodesResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetClusterNodesResponse.java Tue Jun  4 21:52:11 2013
@@ -26,6 +26,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.classification.InterfaceStability.Unstable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
 import org.apache.hadoop.yarn.api.records.NodeReport;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>ResourceManager</code> to a client
@@ -40,16 +41,25 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetClusterNodesResponse {
+public abstract class GetClusterNodesResponse {
+
+  public static GetClusterNodesResponse
+      newInstance(List<NodeReport> nodeReports) {
+    GetClusterNodesResponse response =
+        Records.newRecord(GetClusterNodesResponse.class);
+    response.setNodeReports(nodeReports);
+    return response;
+  }
+
   /**
    * Get <code>NodeReport</code> for all nodes in the cluster.
    * @return <code>NodeReport</code> for all nodes in the cluster
    */
   @Public
   @Stable
-  List<NodeReport> getNodeReports();
+  public abstract List<NodeReport> getNodeReports();
   
   @Private
   @Unstable
-  void setNodeReports(List<NodeReport> nodeReports);
+  public abstract void setNodeReports(List<NodeReport> nodeReports);
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetContainerStatusRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetContainerStatusRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetContainerStatusRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetContainerStatusRequest.java Tue Jun  4 21:52:11 2013
@@ -23,6 +23,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.yarn.api.ContainerManager;
 import org.apache.hadoop.yarn.api.records.ContainerId;
 import org.apache.hadoop.yarn.api.records.ContainerStatus;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The request sent by the <code>ApplicationMaster</code> to the
@@ -32,7 +33,15 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetContainerStatusRequest {
+public abstract class GetContainerStatusRequest {
+
+  public static GetContainerStatusRequest newInstance(ContainerId containerId) {
+    GetContainerStatusRequest request =
+        Records.newRecord(GetContainerStatusRequest.class);
+    request.setContainerId(containerId);
+    return request;
+  }
+
   /**
    * Get the <code>ContainerId</code> of container for which to obtain the
    * <code>ContainerStatus</code>.

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetContainerStatusResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetContainerStatusResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetContainerStatusResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetContainerStatusResponse.java Tue Jun  4 21:52:11 2013
@@ -24,6 +24,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.classification.InterfaceStability.Unstable;
 import org.apache.hadoop.yarn.api.ContainerManager;
 import org.apache.hadoop.yarn.api.records.ContainerStatus;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>NodeManager</code> to the 
@@ -34,7 +35,16 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetContainerStatusResponse {
+public abstract class GetContainerStatusResponse {
+
+  public static GetContainerStatusResponse newInstance(
+      ContainerStatus containerStatus) {
+    GetContainerStatusResponse response =
+        Records.newRecord(GetContainerStatusResponse.class);
+    response.setStatus(containerStatus);
+    return response;
+  }
+
   /**
    * Get the <code>ContainerStatus</code> of the container.
    * @return <code>ContainerStatus</code> of the container

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetDelegationTokenRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetDelegationTokenRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetDelegationTokenRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetDelegationTokenRequest.java Tue Jun  4 21:52:11 2013
@@ -20,6 +20,7 @@ package org.apache.hadoop.yarn.api.proto
 
 import org.apache.hadoop.classification.InterfaceAudience.Public;
 import org.apache.hadoop.classification.InterfaceStability.Evolving;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * The request issued by the client to get a delegation token from
@@ -28,7 +29,15 @@ import org.apache.hadoop.classification.
  */
 @Public
 @Evolving
-public interface GetDelegationTokenRequest {
-  String getRenewer();
-  void setRenewer(String renewer);
+public abstract class GetDelegationTokenRequest {
+
+  public GetDelegationTokenRequest newInstance(String renewer) {
+    GetDelegationTokenRequest request =
+        Records.newRecord(GetDelegationTokenRequest.class);
+    request.setRenewer(renewer);
+    return request;
+  }
+
+  public abstract String getRenewer();
+  public abstract void setRenewer(String renewer);
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetDelegationTokenResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetDelegationTokenResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetDelegationTokenResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetDelegationTokenResponse.java Tue Jun  4 21:52:11 2013
@@ -22,6 +22,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.classification.InterfaceStability.Evolving;
 import org.apache.hadoop.security.token.delegation.AbstractDelegationTokenIdentifier;
 import org.apache.hadoop.yarn.api.records.Token;
+import org.apache.hadoop.yarn.util.Records;
 
 
 /**
@@ -32,13 +33,20 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Evolving
-public interface GetDelegationTokenResponse {
+public abstract class GetDelegationTokenResponse {
+
+  public static GetDelegationTokenResponse newInstance(Token rmDTToken) {
+    GetDelegationTokenResponse response =
+        Records.newRecord(GetDelegationTokenResponse.class);
+    response.setRMDelegationToken(rmDTToken);
+    return response;
+  }
 
   /**
    * The Delegation tokens have a identifier which maps to
    * {@link AbstractDelegationTokenIdentifier}.
    *
    */
-  Token getRMDelegationToken();
-  void setRMDelegationToken(Token rmDTToken);
+  public abstract Token getRMDelegationToken();
+  public abstract void setRMDelegationToken(Token rmDTToken);
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetNewApplicationRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetNewApplicationRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetNewApplicationRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetNewApplicationRequest.java Tue Jun  4 21:52:11 2013
@@ -22,6 +22,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.classification.InterfaceStability.Stable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
 import org.apache.hadoop.yarn.api.records.ApplicationId;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The request sent by clients to get a new {@link ApplicationId} for
@@ -33,6 +34,10 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetNewApplicationRequest {
-
+public abstract class GetNewApplicationRequest {
+  public static GetNewApplicationRequest newInstance() {
+    GetNewApplicationRequest request =
+        Records.newRecord(GetNewApplicationRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetNewApplicationResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetNewApplicationResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetNewApplicationResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetNewApplicationResponse.java Tue Jun  4 21:52:11 2013
@@ -25,6 +25,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
 import org.apache.hadoop.yarn.api.records.ApplicationId;
 import org.apache.hadoop.yarn.api.records.Resource;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>ResourceManager</code> to the client for 
@@ -34,7 +35,19 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetNewApplicationResponse {
+public abstract class GetNewApplicationResponse {
+
+  public static GetNewApplicationResponse newInstance(
+      ApplicationId applicationId, Resource minCapability,
+      Resource maxCapability) {
+    GetNewApplicationResponse response =
+        Records.newRecord(GetNewApplicationResponse.class);
+    response.setApplicationId(applicationId);
+    response.setMinimumResourceCapability(minCapability);
+    response.setMaximumResourceCapability(maxCapability);
+    return response;
+  }
+
   /**
    * Get the <em>new</em> <code>ApplicationId</code> allocated by the 
    * <code>ResourceManager</code>.
@@ -56,11 +69,11 @@ public interface GetNewApplicationRespon
    */
   @Public
   @Stable
-  public Resource getMinimumResourceCapability();
+  public abstract Resource getMinimumResourceCapability();
   
   @Private
   @Unstable
-  public void setMinimumResourceCapability(Resource capability);
+  public abstract void setMinimumResourceCapability(Resource capability);
   
   /**
    * Get the maximum capability for any {@link Resource} allocated by the 
@@ -69,9 +82,9 @@ public interface GetNewApplicationRespon
    */
   @Public
   @Stable
-  public Resource getMaximumResourceCapability();
+  public abstract Resource getMaximumResourceCapability();
   
   @Private
   @Unstable
-  public void setMaximumResourceCapability(Resource capability); 
+  public abstract void setMaximumResourceCapability(Resource capability); 
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueInfoRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueInfoRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueInfoRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueInfoRequest.java Tue Jun  4 21:52:11 2013
@@ -21,6 +21,7 @@ package org.apache.hadoop.yarn.api.proto
 import org.apache.hadoop.classification.InterfaceAudience.Public;
 import org.apache.hadoop.classification.InterfaceStability.Stable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The request sent by clients to get <em>queue information</em>
@@ -30,58 +31,70 @@ import org.apache.hadoop.yarn.api.Client
  */
 @Public
 @Stable
-public interface GetQueueInfoRequest {
+public abstract class GetQueueInfoRequest {
+
+  public static GetQueueInfoRequest
+      newInstance(String queueName, boolean includeApplications,
+          boolean includeChildQueues, boolean recursive) {
+    GetQueueInfoRequest request = Records.newRecord(GetQueueInfoRequest.class);
+    request.setQueueName(queueName);
+    request.setIncludeApplications(includeApplications);
+    request.setIncludeChildQueues(includeChildQueues);
+    request.setRecursive(recursive);
+    return request;
+  }
+
   /**
    * Get the <em>queue name</em> for which to get queue information.
    * @return <em>queue name</em> for which to get queue information
    */
-  String getQueueName();
+  public abstract String getQueueName();
   
   /**
    * Set the <em>queue name</em> for which to get queue information
    * @param queueName <em>queue name</em> for which to get queue information
    */
-  void setQueueName(String queueName);
+  public abstract void setQueueName(String queueName);
 
   /**
    * Is information about <em>active applications<e/m> required?
    * @return <code>true</code> if applications' information is to be included,
    *         else <code>false</code>
    */
-  boolean getIncludeApplications();
+  public abstract boolean getIncludeApplications();
 
   /**
    * Should we get fetch information about <em>active applications</em>?
    * @param includeApplications fetch information about <em>active 
    *                            applications</em>?
    */
-  void setIncludeApplications(boolean includeApplications);
+  public abstract void setIncludeApplications(boolean includeApplications);
 
   /**
    * Is information about <em>child queues</em> required?
    * @return <code>true</code> if information about child queues is required,
    *         else <code>false</code>
    */
-  boolean getIncludeChildQueues();
+  public abstract boolean getIncludeChildQueues();
   
   /**
    * Should we fetch information about <em>child queues</em>?
    * @param includeChildQueues fetch information about <em>child queues</em>?
    */
-  void setIncludeChildQueues(boolean includeChildQueues);
+  public abstract void setIncludeChildQueues(boolean includeChildQueues);
 
   /**
    * Is information on the entire <em>child queue hierarchy</em> required?
    * @return <code>true</code> if information about entire hierarchy is 
    *         required, <code>false</code> otherwise
    */
-  boolean getRecursive();
+  public abstract boolean getRecursive();
   
   /**
    * Should we fetch information on the entire <em>child queue hierarchy</em>?
    * @param recursive fetch information on the entire <em>child queue 
    *                  hierarchy</em>?
    */
-  void setRecursive(boolean recursive);
+  public abstract void setRecursive(boolean recursive);
 }
 

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueInfoResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueInfoResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueInfoResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueInfoResponse.java Tue Jun  4 21:52:11 2013
@@ -24,6 +24,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.classification.InterfaceStability.Unstable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
 import org.apache.hadoop.yarn.api.records.QueueInfo;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>ResourceManager</code> to a client
@@ -38,14 +39,21 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetQueueInfoResponse {
+public abstract class GetQueueInfoResponse {
+
+  public static GetQueueInfoResponse newInstance(QueueInfo queueInfo) {
+    GetQueueInfoResponse response = Records.newRecord(GetQueueInfoResponse.class);
+    response.setQueueInfo(queueInfo);
+    return response;
+  }
+
   /**
    * Get the <code>QueueInfo</code> for the specified queue.
    * @return <code>QueueInfo</code> for the specified queue
    */
-  QueueInfo getQueueInfo();
+  public abstract QueueInfo getQueueInfo();
   
   @Private
   @Unstable
-  void setQueueInfo(QueueInfo queueInfo);
+  public abstract void setQueueInfo(QueueInfo queueInfo);
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueUserAclsInfoRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueUserAclsInfoRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueUserAclsInfoRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueUserAclsInfoRequest.java Tue Jun  4 21:52:11 2013
@@ -21,6 +21,7 @@ package org.apache.hadoop.yarn.api.proto
 import org.apache.hadoop.classification.InterfaceAudience.Public;
 import org.apache.hadoop.classification.InterfaceStability.Stable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The request sent by clients to the <code>ResourceManager</code> to 
@@ -32,6 +33,10 @@ import org.apache.hadoop.yarn.api.Client
  */
 @Public
 @Stable
-public interface GetQueueUserAclsInfoRequest {
-
+public abstract class GetQueueUserAclsInfoRequest {
+  public static GetQueueUserAclsInfoRequest newInstance() {
+    GetQueueUserAclsInfoRequest request =
+        Records.newRecord(GetQueueUserAclsInfoRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueUserAclsInfoResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueUserAclsInfoResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueUserAclsInfoResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/GetQueueUserAclsInfoResponse.java Tue Jun  4 21:52:11 2013
@@ -27,6 +27,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
 import org.apache.hadoop.yarn.api.records.QueueACL;
 import org.apache.hadoop.yarn.api.records.QueueUserACLInfo;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>ResourceManager</code> to clients
@@ -41,7 +42,15 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface GetQueueUserAclsInfoResponse {
+public abstract class GetQueueUserAclsInfoResponse {
+
+  public static GetQueueUserAclsInfoResponse newInstance(
+      List<QueueUserACLInfo> queueUserAclsList) {
+    GetQueueUserAclsInfoResponse response =
+        Records.newRecord(GetQueueUserAclsInfoResponse.class);
+    response.setUserAclsInfoList(queueUserAclsList);
+    return response;
+  }
 
   /**
    * Get the <code>QueueUserACLInfo</code> per queue for the user.
@@ -49,10 +58,11 @@ public interface GetQueueUserAclsInfoRes
    */
   @Public
   @Stable
-  public List<QueueUserACLInfo> getUserAclsInfoList();
+  public abstract List<QueueUserACLInfo> getUserAclsInfoList();
   
   @Private
   @Unstable
-  public void setUserAclsInfoList(List<QueueUserACLInfo> queueUserAclsList);
+  public abstract void setUserAclsInfoList(
+      List<QueueUserACLInfo> queueUserAclsList);
   
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/KillApplicationRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/KillApplicationRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/KillApplicationRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/KillApplicationRequest.java Tue Jun  4 21:52:11 2013
@@ -24,6 +24,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.classification.InterfaceStability.Unstable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
 import org.apache.hadoop.yarn.api.records.ApplicationId;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The request sent by the client to the <code>ResourceManager</code>
@@ -36,7 +37,15 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface KillApplicationRequest {
+public abstract class KillApplicationRequest {
+
+  public static KillApplicationRequest newInstance(ApplicationId applicationId) {
+    KillApplicationRequest request =
+        Records.newRecord(KillApplicationRequest.class);
+    request.setApplicationId(applicationId);
+    return request;
+  }
+
   /**
    * Get the <code>ApplicationId</code> of the application to be aborted.
    * @return <code>ApplicationId</code> of the application to be aborted

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/KillApplicationResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/KillApplicationResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/KillApplicationResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/KillApplicationResponse.java Tue Jun  4 21:52:11 2013
@@ -21,6 +21,7 @@ package org.apache.hadoop.yarn.api.proto
 import org.apache.hadoop.classification.InterfaceAudience.Public;
 import org.apache.hadoop.classification.InterfaceStability.Stable;
 import org.apache.hadoop.yarn.api.ClientRMProtocol;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>ResourceManager</code> to the client
@@ -32,6 +33,10 @@ import org.apache.hadoop.yarn.api.Client
  */
 @Public
 @Stable
-public interface KillApplicationResponse {
-
+public abstract class KillApplicationResponse {
+  public static KillApplicationResponse newInstance() {
+    KillApplicationResponse response =
+        Records.newRecord(KillApplicationResponse.class);
+    return response;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshAdminAclsRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshAdminAclsRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshAdminAclsRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshAdminAclsRequest.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshAdminAclsRequest {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshAdminAclsRequest {
+  public static RefreshAdminAclsRequest newInstance() {
+    RefreshAdminAclsRequest request =
+        Records.newRecord(RefreshAdminAclsRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshAdminAclsResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshAdminAclsResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshAdminAclsResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshAdminAclsResponse.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshAdminAclsResponse {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshAdminAclsResponse {
+  public static RefreshAdminAclsResponse newInstance() {
+    RefreshAdminAclsResponse response =
+        Records.newRecord(RefreshAdminAclsResponse.class);
+    return response;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshNodesRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshNodesRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshNodesRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshNodesRequest.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,11 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshNodesRequest {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshNodesRequest {
+  public static RefreshNodesRequest newInstance() {
+    RefreshNodesRequest request = Records.newRecord(RefreshNodesRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshNodesResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshNodesResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshNodesResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshNodesResponse.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshNodesResponse {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshNodesResponse {
+  public static RefreshNodesResponse newInstance() {
+    RefreshNodesResponse response =
+        Records.newRecord(RefreshNodesResponse.class);
+    return response;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshQueuesRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshQueuesRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshQueuesRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshQueuesRequest.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshQueuesRequest {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshQueuesRequest {
+  public static RefreshQueuesRequest newInstance() {
+    RefreshQueuesRequest request =
+        Records.newRecord(RefreshQueuesRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshQueuesResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshQueuesResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshQueuesResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshQueuesResponse.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshQueuesResponse {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshQueuesResponse {
+  public static RefreshQueuesResponse newInstance() {
+    RefreshQueuesResponse response =
+        Records.newRecord(RefreshQueuesResponse.class);
+    return response;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshServiceAclsRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshServiceAclsRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshServiceAclsRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshServiceAclsRequest.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshServiceAclsRequest {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshServiceAclsRequest {
+  public static RefreshServiceAclsRequest newInstance() {
+    RefreshServiceAclsRequest request =
+        Records.newRecord(RefreshServiceAclsRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshServiceAclsResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshServiceAclsResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshServiceAclsResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshServiceAclsResponse.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshServiceAclsResponse {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshServiceAclsResponse {
+  public static RefreshServiceAclsResponse newInstance() {
+    RefreshServiceAclsResponse response =
+        Records.newRecord(RefreshServiceAclsResponse.class);
+    return response;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshSuperUserGroupsConfigurationRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshSuperUserGroupsConfigurationRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshSuperUserGroupsConfigurationRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshSuperUserGroupsConfigurationRequest.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshSuperUserGroupsConfigurationRequest {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshSuperUserGroupsConfigurationRequest {
+  public static RefreshSuperUserGroupsConfigurationRequest newInstance() {
+    RefreshSuperUserGroupsConfigurationRequest request =
+        Records.newRecord(RefreshSuperUserGroupsConfigurationRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshSuperUserGroupsConfigurationResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshSuperUserGroupsConfigurationResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshSuperUserGroupsConfigurationResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshSuperUserGroupsConfigurationResponse.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshSuperUserGroupsConfigurationResponse {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshSuperUserGroupsConfigurationResponse {
+  public static RefreshSuperUserGroupsConfigurationResponse newInstance() {
+    RefreshSuperUserGroupsConfigurationResponse response =
+        Records.newRecord(RefreshSuperUserGroupsConfigurationResponse.class);
+    return response;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshUserToGroupsMappingsRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshUserToGroupsMappingsRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshUserToGroupsMappingsRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshUserToGroupsMappingsRequest.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshUserToGroupsMappingsRequest {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshUserToGroupsMappingsRequest {
+  public static RefreshUserToGroupsMappingsRequest newInstance() {
+    RefreshUserToGroupsMappingsRequest request =
+        Records.newRecord(RefreshUserToGroupsMappingsRequest.class);
+    return request;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshUserToGroupsMappingsResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshUserToGroupsMappingsResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshUserToGroupsMappingsResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RefreshUserToGroupsMappingsResponse.java Tue Jun  4 21:52:11 2013
@@ -18,6 +18,12 @@
 
 package org.apache.hadoop.yarn.api.protocolrecords;
 
-public interface RefreshUserToGroupsMappingsResponse {
+import org.apache.hadoop.yarn.util.Records;
 
+public abstract class RefreshUserToGroupsMappingsResponse {
+  public static RefreshUserToGroupsMappingsResponse newInstance() {
+    RefreshUserToGroupsMappingsResponse response =
+        Records.newRecord(RefreshUserToGroupsMappingsResponse.class);
+    return response;
+  }
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RegisterApplicationMasterRequest.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RegisterApplicationMasterRequest.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RegisterApplicationMasterRequest.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RegisterApplicationMasterRequest.java Tue Jun  4 21:52:11 2013
@@ -24,6 +24,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.classification.InterfaceStability.Unstable;
 import org.apache.hadoop.yarn.api.AMRMProtocol;
 import org.apache.hadoop.yarn.api.records.ApplicationAttemptId;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The request sent by the <code>ApplicationMaster</code> to 
@@ -45,7 +46,19 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface RegisterApplicationMasterRequest {
+public abstract class RegisterApplicationMasterRequest {
+
+  public static RegisterApplicationMasterRequest newInstance(
+      ApplicationAttemptId applicationAttemptId, String host, int port,
+      String trackingUrl) {
+    RegisterApplicationMasterRequest request =
+        Records.newRecord(RegisterApplicationMasterRequest.class);
+    request.setApplicationAttemptId(applicationAttemptId);
+    request.setHost(host);
+    request.setRpcPort(port);
+    request.setTrackingUrl(trackingUrl);
+    return request;
+  }
 
   /**
    * Get the <code>ApplicationAttemptId</code> being managed by the 
@@ -55,7 +68,7 @@ public interface RegisterApplicationMast
    */
   @Public
   @Stable
-  ApplicationAttemptId getApplicationAttemptId();
+  public abstract ApplicationAttemptId getApplicationAttemptId();
   
   /**
    * Set the <code>ApplicationAttemptId</code> being managed by the 
@@ -65,7 +78,7 @@ public interface RegisterApplicationMast
    */
   @Public
   @Stable
-  void setApplicationAttemptId(ApplicationAttemptId applicationAttemptId);
+  public abstract void setApplicationAttemptId(ApplicationAttemptId applicationAttemptId);
 
   /**
    * Get the <em>host</em> on which the <code>ApplicationMaster</code> is 
@@ -74,7 +87,7 @@ public interface RegisterApplicationMast
    */
   @Public
   @Stable
-  String getHost();
+  public abstract String getHost();
   
   /**
    * Set the <em>host</em> on which the <code>ApplicationMaster</code> is 
@@ -84,7 +97,7 @@ public interface RegisterApplicationMast
    */
   @Private
   @Unstable
-  void setHost(String host);
+  public abstract void setHost(String host);
 
   /**
    * Get the <em>RPC port</em> on which the <code>ApplicationMaster</code> 
@@ -94,7 +107,7 @@ public interface RegisterApplicationMast
    */
   @Public
   @Stable
-  int getRpcPort();
+  public abstract int getRpcPort();
   
   /**
    * Set the <em>RPC port<em> on which the <code>ApplicationMaster</code> is 
@@ -104,7 +117,7 @@ public interface RegisterApplicationMast
    */
   @Public
   @Stable
-  void setRpcPort(int port);
+  public abstract void setRpcPort(int port);
 
   /**
    * Get the <em>tracking URL</em> for the <code>ApplicationMaster</code>.
@@ -112,7 +125,7 @@ public interface RegisterApplicationMast
    */
   @Public
   @Stable
-  String getTrackingUrl();
+  public abstract String getTrackingUrl();
   
   /**
    * Set the <em>tracking URL</em> for the <code>ApplicationMaster</code>.
@@ -121,5 +134,5 @@ public interface RegisterApplicationMast
    */
   @Public
   @Stable
-  void setTrackingUrl(String trackingUrl);
+  public abstract void setTrackingUrl(String trackingUrl);
 }

Modified: hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RegisterApplicationMasterResponse.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RegisterApplicationMasterResponse.java?rev=1489644&r1=1489643&r2=1489644&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RegisterApplicationMasterResponse.java (original)
+++ hadoop/common/trunk/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/protocolrecords/RegisterApplicationMasterResponse.java Tue Jun  4 21:52:11 2013
@@ -27,6 +27,7 @@ import org.apache.hadoop.classification.
 import org.apache.hadoop.yarn.api.AMRMProtocol;
 import org.apache.hadoop.yarn.api.records.ApplicationAccessType;
 import org.apache.hadoop.yarn.api.records.Resource;
+import org.apache.hadoop.yarn.util.Records;
 
 /**
  * <p>The response sent by the <code>ResourceManager</code> to a new 
@@ -43,8 +44,19 @@ import org.apache.hadoop.yarn.api.record
  */
 @Public
 @Stable
-public interface RegisterApplicationMasterResponse {
-  
+public abstract class RegisterApplicationMasterResponse {
+
+  public static RegisterApplicationMasterResponse newInstance(
+      Resource minCapability, Resource maxCapability,
+      Map<ApplicationAccessType, String> acls) {
+    RegisterApplicationMasterResponse response =
+        Records.newRecord(RegisterApplicationMasterResponse.class);
+    response.setMinimumResourceCapability(minCapability);
+    response.setMaximumResourceCapability(maxCapability);
+    response.setApplicationACLs(acls);
+    return response;
+  }
+
   /**
    * Get the minimum capability for any {@link Resource} allocated by the 
    * <code>ResourceManager</code> in the cluster.
@@ -52,11 +64,11 @@ public interface RegisterApplicationMast
    */
   @Public
   @Stable
-  public Resource getMinimumResourceCapability();
+  public abstract Resource getMinimumResourceCapability();
   
   @Private
   @Unstable
-  public void setMinimumResourceCapability(Resource capability);
+  public abstract void setMinimumResourceCapability(Resource capability);
   
   /**
    * Get the maximum capability for any {@link Resource} allocated by the 
@@ -65,11 +77,11 @@ public interface RegisterApplicationMast
    */
   @Public
   @Stable
-  public Resource getMaximumResourceCapability();
+  public abstract Resource getMaximumResourceCapability();
   
   @Private
   @Unstable
-  public void setMaximumResourceCapability(Resource capability);
+  public abstract void setMaximumResourceCapability(Resource capability);
 
   /**
    * Get the <code>ApplicationACL</code>s for the application. 
@@ -77,7 +89,7 @@ public interface RegisterApplicationMast
    */
   @Public
   @Stable
-  public Map<ApplicationAccessType, String> getApplicationACLs();
+  public abstract Map<ApplicationAccessType, String> getApplicationACLs();
 
   /**
    * Set the <code>ApplicationACL</code>s for the application. 
@@ -85,5 +97,5 @@ public interface RegisterApplicationMast
    */
   @Private
   @Unstable
-  public void setApplicationACLs(Map<ApplicationAccessType, String> acls);
+  public abstract void setApplicationACLs(Map<ApplicationAccessType, String> acls);
 }



Mime
View raw message