This is an automated email from the ASF dual-hosted git repository.

machristie pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/airavata.git


The following commit(s) were added to refs/heads/develop by this push:
     new e271719  Regenerate GroupManagerService Python stubs
e271719 is described below

commit e271719abd7054ab9947fa6e888d856a0ed7e781
Author: Marcus Christie <machris...@apache.org>
AuthorDate: Fri Feb 9 15:28:38 2018 -0500

    Regenerate GroupManagerService Python stubs
---
 .../groupmanager/cpi/GroupManagerService-remote    |   7 +
 .../groupmanager/cpi/GroupManagerService.py        | 263 +++++++++++++++++++--
 2 files changed, 251 insertions(+), 19 deletions(-)

diff --git 
a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/airavata/service/profile/groupmanager/cpi/GroupManagerService-remote
 
b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/airavata/service/profile/groupmanager/cpi/GroupManagerService-remote
index f2634ec..583ea67 100755
--- 
a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/airavata/service/profile/groupmanager/cpi/GroupManagerService-remote
+++ 
b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/airavata/service/profile/groupmanager/cpi/GroupManagerService-remote
@@ -28,6 +28,7 @@ if len(sys.argv) <= 1 or sys.argv[1] == '--help':
     print('  bool updateGroup(AuthzToken authzToken, GroupModel groupModel)')
     print('  bool deleteGroup(AuthzToken authzToken, string groupId, string 
ownerId)')
     print('  GroupModel getGroup(AuthzToken authzToken, string groupId)')
+    print('   getGroups(AuthzToken authzToken)')
     print('   getAllGroupsUserBelongs(AuthzToken authzToken, string userName)')
     print('  bool transferGroupOwnership(AuthzToken authzToken, string 
groupId, string newOwnerId)')
     print('  bool addGroupAdmins(AuthzToken authzToken, string groupId,  
adminIds)')
@@ -137,6 +138,12 @@ elif cmd == 'getGroup':
         sys.exit(1)
     pp.pprint(client.getGroup(eval(args[0]), args[1],))
 
+elif cmd == 'getGroups':
+    if len(args) != 1:
+        print('getGroups requires 1 args')
+        sys.exit(1)
+    pp.pprint(client.getGroups(eval(args[0]),))
+
 elif cmd == 'getAllGroupsUserBelongs':
     if len(args) != 2:
         print('getAllGroupsUserBelongs requires 2 args')
diff --git 
a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/airavata/service/profile/groupmanager/cpi/GroupManagerService.py
 
b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/airavata/service/profile/groupmanager/cpi/GroupManagerService.py
index bf65fc8..899ed20 100644
--- 
a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/airavata/service/profile/groupmanager/cpi/GroupManagerService.py
+++ 
b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/airavata/service/profile/groupmanager/cpi/GroupManagerService.py
@@ -49,6 +49,13 @@ class Iface(object):
         """
         pass
 
+    def getGroups(self, authzToken):
+        """
+        Parameters:
+         - authzToken
+        """
+        pass
+
     def getAllGroupsUserBelongs(self, authzToken, userName):
         """
         Parameters:
@@ -260,6 +267,41 @@ class Client(Iface):
             raise result.ae
         raise TApplicationException(TApplicationException.MISSING_RESULT, 
"getGroup failed: unknown result")
 
+    def getGroups(self, authzToken):
+        """
+        Parameters:
+         - authzToken
+        """
+        self.send_getGroups(authzToken)
+        return self.recv_getGroups()
+
+    def send_getGroups(self, authzToken):
+        self._oprot.writeMessageBegin('getGroups', TMessageType.CALL, 
self._seqid)
+        args = getGroups_args()
+        args.authzToken = authzToken
+        args.write(self._oprot)
+        self._oprot.writeMessageEnd()
+        self._oprot.trans.flush()
+
+    def recv_getGroups(self):
+        iprot = self._iprot
+        (fname, mtype, rseqid) = iprot.readMessageBegin()
+        if mtype == TMessageType.EXCEPTION:
+            x = TApplicationException()
+            x.read(iprot)
+            iprot.readMessageEnd()
+            raise x
+        result = getGroups_result()
+        result.read(iprot)
+        iprot.readMessageEnd()
+        if result.success is not None:
+            return result.success
+        if result.gse is not None:
+            raise result.gse
+        if result.ae is not None:
+            raise result.ae
+        raise TApplicationException(TApplicationException.MISSING_RESULT, 
"getGroups failed: unknown result")
+
     def getAllGroupsUserBelongs(self, authzToken, userName):
         """
         Parameters:
@@ -501,6 +543,7 @@ class Processor(Iface, TProcessor):
         self._processMap["updateGroup"] = Processor.process_updateGroup
         self._processMap["deleteGroup"] = Processor.process_deleteGroup
         self._processMap["getGroup"] = Processor.process_getGroup
+        self._processMap["getGroups"] = Processor.process_getGroups
         self._processMap["getAllGroupsUserBelongs"] = 
Processor.process_getAllGroupsUserBelongs
         self._processMap["transferGroupOwnership"] = 
Processor.process_transferGroupOwnership
         self._processMap["addGroupAdmins"] = Processor.process_addGroupAdmins
@@ -623,6 +666,31 @@ class Processor(Iface, TProcessor):
         oprot.writeMessageEnd()
         oprot.trans.flush()
 
+    def process_getGroups(self, seqid, iprot, oprot):
+        args = getGroups_args()
+        args.read(iprot)
+        iprot.readMessageEnd()
+        result = getGroups_result()
+        try:
+            result.success = self._handler.getGroups(args.authzToken)
+            msg_type = TMessageType.REPLY
+        except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+            raise
+        except 
airavata.service.profile.groupmanager.cpi.error.ttypes.GroupManagerServiceException
 as gse:
+            msg_type = TMessageType.REPLY
+            result.gse = gse
+        except airavata.api.error.ttypes.AuthorizationException as ae:
+            msg_type = TMessageType.REPLY
+            result.ae = ae
+        except Exception as ex:
+            msg_type = TMessageType.EXCEPTION
+            logging.exception(ex)
+            result = 
TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+        oprot.writeMessageBegin("getGroups", msg_type, seqid)
+        result.write(oprot)
+        oprot.writeMessageEnd()
+        oprot.trans.flush()
+
     def process_getAllGroupsUserBelongs(self, seqid, iprot, oprot):
         args = getAllGroupsUserBelongs_args()
         args.read(iprot)
@@ -1441,6 +1509,163 @@ class getGroup_result(object):
         return not (self == other)
 
 
+class getGroups_args(object):
+    """
+    Attributes:
+     - authzToken
+    """
+
+    thrift_spec = (
+        None,  # 0
+        (1, TType.STRUCT, 'authzToken', 
(airavata.model.security.ttypes.AuthzToken, 
airavata.model.security.ttypes.AuthzToken.thrift_spec), None, ),  # 1
+    )
+
+    def __init__(self, authzToken=None,):
+        self.authzToken = authzToken
+
+    def read(self, iprot):
+        if iprot._fast_decode is not None and isinstance(iprot.trans, 
TTransport.CReadableTransport) and self.thrift_spec is not None:
+            iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+            return
+        iprot.readStructBegin()
+        while True:
+            (fname, ftype, fid) = iprot.readFieldBegin()
+            if ftype == TType.STOP:
+                break
+            if fid == 1:
+                if ftype == TType.STRUCT:
+                    self.authzToken = 
airavata.model.security.ttypes.AuthzToken()
+                    self.authzToken.read(iprot)
+                else:
+                    iprot.skip(ftype)
+            else:
+                iprot.skip(ftype)
+            iprot.readFieldEnd()
+        iprot.readStructEnd()
+
+    def write(self, oprot):
+        if oprot._fast_encode is not None and self.thrift_spec is not None:
+            oprot.trans.write(oprot._fast_encode(self, (self.__class__, 
self.thrift_spec)))
+            return
+        oprot.writeStructBegin('getGroups_args')
+        if self.authzToken is not None:
+            oprot.writeFieldBegin('authzToken', TType.STRUCT, 1)
+            self.authzToken.write(oprot)
+            oprot.writeFieldEnd()
+        oprot.writeFieldStop()
+        oprot.writeStructEnd()
+
+    def validate(self):
+        if self.authzToken is None:
+            raise TProtocolException(message='Required field authzToken is 
unset!')
+        return
+
+    def __repr__(self):
+        L = ['%s=%r' % (key, value)
+             for key, value in self.__dict__.items()]
+        return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+    def __eq__(self, other):
+        return isinstance(other, self.__class__) and self.__dict__ == 
other.__dict__
+
+    def __ne__(self, other):
+        return not (self == other)
+
+
+class getGroups_result(object):
+    """
+    Attributes:
+     - success
+     - gse
+     - ae
+    """
+
+    thrift_spec = (
+        (0, TType.LIST, 'success', (TType.STRUCT, 
(airavata.model.group.ttypes.GroupModel, 
airavata.model.group.ttypes.GroupModel.thrift_spec), False), None, ),  # 0
+        (1, TType.STRUCT, 'gse', 
(airavata.service.profile.groupmanager.cpi.error.ttypes.GroupManagerServiceException,
 
airavata.service.profile.groupmanager.cpi.error.ttypes.GroupManagerServiceException.thrift_spec),
 None, ),  # 1
+        (2, TType.STRUCT, 'ae', 
(airavata.api.error.ttypes.AuthorizationException, 
airavata.api.error.ttypes.AuthorizationException.thrift_spec), None, ),  # 2
+    )
+
+    def __init__(self, success=None, gse=None, ae=None,):
+        self.success = success
+        self.gse = gse
+        self.ae = ae
+
+    def read(self, iprot):
+        if iprot._fast_decode is not None and isinstance(iprot.trans, 
TTransport.CReadableTransport) and self.thrift_spec is not None:
+            iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+            return
+        iprot.readStructBegin()
+        while True:
+            (fname, ftype, fid) = iprot.readFieldBegin()
+            if ftype == TType.STOP:
+                break
+            if fid == 0:
+                if ftype == TType.LIST:
+                    self.success = []
+                    (_etype3, _size0) = iprot.readListBegin()
+                    for _i4 in range(_size0):
+                        _elem5 = airavata.model.group.ttypes.GroupModel()
+                        _elem5.read(iprot)
+                        self.success.append(_elem5)
+                    iprot.readListEnd()
+                else:
+                    iprot.skip(ftype)
+            elif fid == 1:
+                if ftype == TType.STRUCT:
+                    self.gse = 
airavata.service.profile.groupmanager.cpi.error.ttypes.GroupManagerServiceException()
+                    self.gse.read(iprot)
+                else:
+                    iprot.skip(ftype)
+            elif fid == 2:
+                if ftype == TType.STRUCT:
+                    self.ae = 
airavata.api.error.ttypes.AuthorizationException()
+                    self.ae.read(iprot)
+                else:
+                    iprot.skip(ftype)
+            else:
+                iprot.skip(ftype)
+            iprot.readFieldEnd()
+        iprot.readStructEnd()
+
+    def write(self, oprot):
+        if oprot._fast_encode is not None and self.thrift_spec is not None:
+            oprot.trans.write(oprot._fast_encode(self, (self.__class__, 
self.thrift_spec)))
+            return
+        oprot.writeStructBegin('getGroups_result')
+        if self.success is not None:
+            oprot.writeFieldBegin('success', TType.LIST, 0)
+            oprot.writeListBegin(TType.STRUCT, len(self.success))
+            for iter6 in self.success:
+                iter6.write(oprot)
+            oprot.writeListEnd()
+            oprot.writeFieldEnd()
+        if self.gse is not None:
+            oprot.writeFieldBegin('gse', TType.STRUCT, 1)
+            self.gse.write(oprot)
+            oprot.writeFieldEnd()
+        if self.ae is not None:
+            oprot.writeFieldBegin('ae', TType.STRUCT, 2)
+            self.ae.write(oprot)
+            oprot.writeFieldEnd()
+        oprot.writeFieldStop()
+        oprot.writeStructEnd()
+
+    def validate(self):
+        return
+
+    def __repr__(self):
+        L = ['%s=%r' % (key, value)
+             for key, value in self.__dict__.items()]
+        return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+    def __eq__(self, other):
+        return isinstance(other, self.__class__) and self.__dict__ == 
other.__dict__
+
+    def __ne__(self, other):
+        return not (self == other)
+
+
 class getAllGroupsUserBelongs_args(object):
     """
     Attributes:
@@ -1549,11 +1774,11 @@ class getAllGroupsUserBelongs_result(object):
             if fid == 0:
                 if ftype == TType.LIST:
                     self.success = []
-                    (_etype3, _size0) = iprot.readListBegin()
-                    for _i4 in range(_size0):
-                        _elem5 = airavata.model.group.ttypes.GroupModel()
-                        _elem5.read(iprot)
-                        self.success.append(_elem5)
+                    (_etype10, _size7) = iprot.readListBegin()
+                    for _i11 in range(_size7):
+                        _elem12 = airavata.model.group.ttypes.GroupModel()
+                        _elem12.read(iprot)
+                        self.success.append(_elem12)
                     iprot.readListEnd()
                 else:
                     iprot.skip(ftype)
@@ -1582,8 +1807,8 @@ class getAllGroupsUserBelongs_result(object):
         if self.success is not None:
             oprot.writeFieldBegin('success', TType.LIST, 0)
             oprot.writeListBegin(TType.STRUCT, len(self.success))
-            for iter6 in self.success:
-                iter6.write(oprot)
+            for iter13 in self.success:
+                iter13.write(oprot)
             oprot.writeListEnd()
             oprot.writeFieldEnd()
         if self.gse is not None:
@@ -1831,10 +2056,10 @@ class addGroupAdmins_args(object):
             elif fid == 3:
                 if ftype == TType.LIST:
                     self.adminIds = []
-                    (_etype10, _size7) = iprot.readListBegin()
-                    for _i11 in range(_size7):
-                        _elem12 = iprot.readString().decode('utf-8') if 
sys.version_info[0] == 2 else iprot.readString()
-                        self.adminIds.append(_elem12)
+                    (_etype17, _size14) = iprot.readListBegin()
+                    for _i18 in range(_size14):
+                        _elem19 = iprot.readString().decode('utf-8') if 
sys.version_info[0] == 2 else iprot.readString()
+                        self.adminIds.append(_elem19)
                     iprot.readListEnd()
                 else:
                     iprot.skip(ftype)
@@ -1859,8 +2084,8 @@ class addGroupAdmins_args(object):
         if self.adminIds is not None:
             oprot.writeFieldBegin('adminIds', TType.LIST, 3)
             oprot.writeListBegin(TType.STRING, len(self.adminIds))
-            for iter13 in self.adminIds:
-                oprot.writeString(iter13.encode('utf-8') if 
sys.version_info[0] == 2 else iter13)
+            for iter20 in self.adminIds:
+                oprot.writeString(iter20.encode('utf-8') if 
sys.version_info[0] == 2 else iter20)
             oprot.writeListEnd()
             oprot.writeFieldEnd()
         oprot.writeFieldStop()
@@ -2015,10 +2240,10 @@ class removeGroupAdmins_args(object):
             elif fid == 3:
                 if ftype == TType.LIST:
                     self.adminIds = []
-                    (_etype17, _size14) = iprot.readListBegin()
-                    for _i18 in range(_size14):
-                        _elem19 = iprot.readString().decode('utf-8') if 
sys.version_info[0] == 2 else iprot.readString()
-                        self.adminIds.append(_elem19)
+                    (_etype24, _size21) = iprot.readListBegin()
+                    for _i25 in range(_size21):
+                        _elem26 = iprot.readString().decode('utf-8') if 
sys.version_info[0] == 2 else iprot.readString()
+                        self.adminIds.append(_elem26)
                     iprot.readListEnd()
                 else:
                     iprot.skip(ftype)
@@ -2043,8 +2268,8 @@ class removeGroupAdmins_args(object):
         if self.adminIds is not None:
             oprot.writeFieldBegin('adminIds', TType.LIST, 3)
             oprot.writeListBegin(TType.STRING, len(self.adminIds))
-            for iter20 in self.adminIds:
-                oprot.writeString(iter20.encode('utf-8') if 
sys.version_info[0] == 2 else iter20)
+            for iter27 in self.adminIds:
+                oprot.writeString(iter27.encode('utf-8') if 
sys.version_info[0] == 2 else iter27)
             oprot.writeListEnd()
             oprot.writeFieldEnd()
         oprot.writeFieldStop()

-- 
To stop receiving notification emails like this one, please contact
machris...@apache.org.

Reply via email to