storm-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bo...@apache.org
Subject [5/6] storm git commit: Address review comments
Date Mon, 30 Jul 2018 18:22:53 GMT
Address review comments


Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/950bd181
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/950bd181
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/950bd181

Branch: refs/heads/master
Commit: 950bd1819cbef92ea12d93d2fae9324895e667a1
Parents: e0795f1
Author: Stig Rohde Døssing <srdo@apache.org>
Authored: Thu Jul 12 19:28:59 2018 +0200
Committer: Stig Rohde Døssing <srdo@apache.org>
Committed: Thu Jul 12 19:30:20 2018 +0200

----------------------------------------------------------------------
 .../org/apache/storm/generated/ClusterSummary.java  | 16 ++++++++--------
 storm-client/src/py/storm/ttypes.py                 | 13 +++++++------
 storm-client/src/storm.thrift                       | 10 +++++++---
 3 files changed, 22 insertions(+), 17 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/storm/blob/950bd181/storm-client/src/jvm/org/apache/storm/generated/ClusterSummary.java
----------------------------------------------------------------------
diff --git a/storm-client/src/jvm/org/apache/storm/generated/ClusterSummary.java b/storm-client/src/jvm/org/apache/storm/generated/ClusterSummary.java
index 400e06d..d5567a0 100644
--- a/storm-client/src/jvm/org/apache/storm/generated/ClusterSummary.java
+++ b/storm-client/src/jvm/org/apache/storm/generated/ClusterSummary.java
@@ -29,8 +29,8 @@ public class ClusterSummary implements org.apache.storm.thrift.TBase<ClusterSumm
   private static final org.apache.storm.thrift.protocol.TStruct STRUCT_DESC = new org.apache.storm.thrift.protocol.TStruct("ClusterSummary");
 
   private static final org.apache.storm.thrift.protocol.TField SUPERVISORS_FIELD_DESC = new
org.apache.storm.thrift.protocol.TField("supervisors", org.apache.storm.thrift.protocol.TType.LIST,
(short)1);
-  private static final org.apache.storm.thrift.protocol.TField TOPOLOGIES_FIELD_DESC = new
org.apache.storm.thrift.protocol.TField("topologies", org.apache.storm.thrift.protocol.TType.LIST,
(short)2);
-  private static final org.apache.storm.thrift.protocol.TField NIMBUSES_FIELD_DESC = new
org.apache.storm.thrift.protocol.TField("nimbuses", org.apache.storm.thrift.protocol.TType.LIST,
(short)3);
+  private static final org.apache.storm.thrift.protocol.TField TOPOLOGIES_FIELD_DESC = new
org.apache.storm.thrift.protocol.TField("topologies", org.apache.storm.thrift.protocol.TType.LIST,
(short)3);
+  private static final org.apache.storm.thrift.protocol.TField NIMBUSES_FIELD_DESC = new
org.apache.storm.thrift.protocol.TField("nimbuses", org.apache.storm.thrift.protocol.TType.LIST,
(short)4);
 
   private static final org.apache.storm.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY
= new ClusterSummaryStandardSchemeFactory();
   private static final org.apache.storm.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY
= new ClusterSummaryTupleSchemeFactory();
@@ -42,8 +42,8 @@ public class ClusterSummary implements org.apache.storm.thrift.TBase<ClusterSumm
   /** The set of fields this struct contains, along with convenience methods for finding
and manipulating them. */
   public enum _Fields implements org.apache.storm.thrift.TFieldIdEnum {
     SUPERVISORS((short)1, "supervisors"),
-    TOPOLOGIES((short)2, "topologies"),
-    NIMBUSES((short)3, "nimbuses");
+    TOPOLOGIES((short)3, "topologies"),
+    NIMBUSES((short)4, "nimbuses");
 
     private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String,
_Fields>();
 
@@ -60,9 +60,9 @@ public class ClusterSummary implements org.apache.storm.thrift.TBase<ClusterSumm
       switch(fieldId) {
         case 1: // SUPERVISORS
           return SUPERVISORS;
-        case 2: // TOPOLOGIES
+        case 3: // TOPOLOGIES
           return TOPOLOGIES;
-        case 3: // NIMBUSES
+        case 4: // NIMBUSES
           return NIMBUSES;
         default:
           return null;
@@ -566,7 +566,7 @@ public class ClusterSummary implements org.apache.storm.thrift.TBase<ClusterSumm
               org.apache.storm.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
             }
             break;
-          case 2: // TOPOLOGIES
+          case 3: // TOPOLOGIES
             if (schemeField.type == org.apache.storm.thrift.protocol.TType.LIST) {
               {
                 org.apache.storm.thrift.protocol.TList _list139 = iprot.readListBegin();
@@ -585,7 +585,7 @@ public class ClusterSummary implements org.apache.storm.thrift.TBase<ClusterSumm
               org.apache.storm.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
             }
             break;
-          case 3: // NIMBUSES
+          case 4: // NIMBUSES
             if (schemeField.type == org.apache.storm.thrift.protocol.TType.LIST) {
               {
                 org.apache.storm.thrift.protocol.TList _list142 = iprot.readListBegin();

http://git-wip-us.apache.org/repos/asf/storm/blob/950bd181/storm-client/src/py/storm/ttypes.py
----------------------------------------------------------------------
diff --git a/storm-client/src/py/storm/ttypes.py b/storm-client/src/py/storm/ttypes.py
index e20c926..16f35a4 100644
--- a/storm-client/src/py/storm/ttypes.py
+++ b/storm-client/src/py/storm/ttypes.py
@@ -2630,7 +2630,7 @@ class ClusterSummary(object):
                     iprot.readListEnd()
                 else:
                     iprot.skip(ftype)
-            elif fid == 2:
+            elif fid == 3:
                 if ftype == TType.LIST:
                     self.topologies = []
                     (_etype130, _size127) = iprot.readListBegin()
@@ -2641,7 +2641,7 @@ class ClusterSummary(object):
                     iprot.readListEnd()
                 else:
                     iprot.skip(ftype)
-            elif fid == 3:
+            elif fid == 4:
                 if ftype == TType.LIST:
                     self.nimbuses = []
                     (_etype136, _size133) = iprot.readListBegin()
@@ -2670,14 +2670,14 @@ class ClusterSummary(object):
             oprot.writeListEnd()
             oprot.writeFieldEnd()
         if self.topologies is not None:
-            oprot.writeFieldBegin('topologies', TType.LIST, 2)
+            oprot.writeFieldBegin('topologies', TType.LIST, 3)
             oprot.writeListBegin(TType.STRUCT, len(self.topologies))
             for iter140 in self.topologies:
                 iter140.write(oprot)
             oprot.writeListEnd()
             oprot.writeFieldEnd()
         if self.nimbuses is not None:
-            oprot.writeFieldBegin('nimbuses', TType.LIST, 3)
+            oprot.writeFieldBegin('nimbuses', TType.LIST, 4)
             oprot.writeListBegin(TType.STRUCT, len(self.nimbuses))
             for iter141 in self.nimbuses:
                 iter141.write(oprot)
@@ -10819,8 +10819,9 @@ all_structs.append(ClusterSummary)
 ClusterSummary.thrift_spec = (
     None,  # 0
     (1, TType.LIST, 'supervisors', (TType.STRUCT, [SupervisorSummary, None], False), None,
),  # 1
-    (2, TType.LIST, 'topologies', (TType.STRUCT, [TopologySummary, None], False), None, ),
 # 2
-    (3, TType.LIST, 'nimbuses', (TType.STRUCT, [NimbusSummary, None], False), None, ),  #
3
+    None,  # 2
+    (3, TType.LIST, 'topologies', (TType.STRUCT, [TopologySummary, None], False), None, ),
 # 3
+    (4, TType.LIST, 'nimbuses', (TType.STRUCT, [NimbusSummary, None], False), None, ),  #
4
 )
 all_structs.append(ErrorInfo)
 ErrorInfo.thrift_spec = (

http://git-wip-us.apache.org/repos/asf/storm/blob/950bd181/storm-client/src/storm.thrift
----------------------------------------------------------------------
diff --git a/storm-client/src/storm.thrift b/storm-client/src/storm.thrift
index 9997c8e..9753ff5 100644
--- a/storm-client/src/storm.thrift
+++ b/storm-client/src/storm.thrift
@@ -206,8 +206,9 @@ struct NimbusSummary {
 
 struct ClusterSummary {
   1: required list<SupervisorSummary> supervisors;
-  2: required list<TopologySummary> topologies;
-  3: required list<NimbusSummary> nimbuses;
+  //2: Removed. Do not reuse.
+  3: required list<TopologySummary> topologies;
+  4: required list<NimbusSummary> nimbuses;
 }
 
 struct ErrorInfo {
@@ -711,6 +712,9 @@ struct WorkerMetrics {
 }
 
 service Nimbus {
+  //Removed methods, be careful about reusing these names
+  //string beginFileDownload(1: string file) throws (1: AuthorizationException aze);
+
   void submitTopology(1: string name, 2: string uploadedJarLocation, 3: string jsonConf,
4: StormTopology topology) throws (1: AlreadyAliveException e, 2: InvalidTopologyException
ite, 3: AuthorizationException aze);
   void submitTopologyWithOpts(1: string name, 2: string uploadedJarLocation, 3: string jsonConf,
4: StormTopology topology, 5: SubmitOptions options) throws (1: AlreadyAliveException e, 2:
InvalidTopologyException ite, 3: AuthorizationException aze);
   void killTopology(1: string name) throws (1: NotAliveException e, 2: AuthorizationException
aze);
@@ -757,7 +761,7 @@ service Nimbus {
   string beginFileUpload() throws (1: AuthorizationException aze);
   void uploadChunk(1: string location, 2: binary chunk) throws (1: AuthorizationException
aze);
   void finishFileUpload(1: string location) throws (1: AuthorizationException aze);
-
+  
   //can stop downloading chunks when receive 0-length byte array back
   binary downloadChunk(1: string id) throws (1: AuthorizationException aze);
 


Mime
View raw message