You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by bh...@apache.org on 2016/08/23 10:06:09 UTC
[1/2] git commit: updated refs/heads/master to 11c90df
Repository: cloudstack
Updated Branches:
refs/heads/master 9555492b4 -> 11c90dfb3
marvin: fix codegeneration against API discovery endpoint
This makes the commands.xml based codegeneration equivalent to the
API discovery end point based discovery.
This fixes the fields that the (api discovery based) codegenerator should
produce in the generated python classes (cmd and response classes per
api/module). The issue was that the autogenerated cloudstackAPI differed between
api-based and apidocs-based code generation. With this fix the generated classes
match exactly thereby allowing us to go with either methods to generate
cloudstackAPI.
Signed-off-by: Rohit Yadav <ro...@shapeblue.com>
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/7a53feee
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/7a53feee
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/7a53feee
Branch: refs/heads/master
Commit: 7a53feee22c873c4e35c86b3fc1d4647314b62bf
Parents: d3e4551
Author: Rohit Yadav <ro...@shapeblue.com>
Authored: Tue Jun 28 15:53:20 2016 +0530
Committer: Rohit Yadav <ro...@shapeblue.com>
Committed: Fri Aug 19 13:43:48 2016 +0530
----------------------------------------------------------------------
tools/marvin/marvin/codegenerator.py | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/7a53feee/tools/marvin/marvin/codegenerator.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/codegenerator.py b/tools/marvin/marvin/codegenerator.py
index ba2a325..14f6d13 100644
--- a/tools/marvin/marvin/codegenerator.py
+++ b/tools/marvin/marvin/codegenerator.py
@@ -368,6 +368,7 @@ class CodeGenerator(object):
self.constructResponseFromJSON(innerResponse)
paramProperty.subProperties.append(subProperty)
paramProperty.type = response['type']
+ paramProperty.dataType = response['type']
return paramProperty
def loadCmdFromJSON(self, apiStream):
@@ -404,13 +405,14 @@ class CodeGenerator(object):
assert paramProperty.name
if 'required' in param:
- paramProperty.required = param['required']
+ paramProperty.required = str(param['required']).lower()
if 'description' in param:
paramProperty.desc = param['description']
if 'type' in param:
paramProperty.type = param['type']
+ paramProperty.dataType = param['type']
csCmd.request.append(paramProperty)
[2/2] git commit: updated refs/heads/master to 11c90df
Posted by bh...@apache.org.
Merge pull request #1599 from shapeblue/independent-marvin
Marvin: Fix codegenerator to work with API discoveryThis fixes Marvin cloudstackAPI generator to work with a live running mgmt server's api discovery.
* pr/1599:
marvin: fix codegeneration against API discovery endpoint
Signed-off-by: Rohit Yadav <ro...@shapeblue.com>
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/11c90dfb
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/11c90dfb
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/11c90dfb
Branch: refs/heads/master
Commit: 11c90dfb3bf684d3a4f63bf6053f071247d67cd8
Parents: 9555492 7a53fee
Author: Rohit Yadav <ro...@shapeblue.com>
Authored: Tue Aug 23 15:35:51 2016 +0530
Committer: Rohit Yadav <ro...@shapeblue.com>
Committed: Tue Aug 23 15:35:52 2016 +0530
----------------------------------------------------------------------
tools/marvin/marvin/codegenerator.py | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------