{"action":"closed","number":90,"pull_request":{"url":"https://api.github.com/repos/nuagenetworks/monolithe/pulls/90","id":185576764,"html_url":"https://github.com/nuagenetworks/monolithe/pull/90","diff_url":"https://github.com/nuagenetworks/monolithe/pull/90.diff","patch_url":"https://github.com/nuagenetworks/monolithe/pull/90.patch","issue_url":"https://api.github.com/repos/nuagenetworks/monolithe/issues/90","number":90,"state":"closed","locked":false,"title":"undefined as default if default value not specified and for read-only attrs","user":{"login":"killanch","id":24920919,"avatar_url":"https://avatars2.githubusercontent.com/u/24920919?v=4","gravatar_id":"","url":"https://api.github.com/users/killanch","html_url":"https://github.com/killanch","followers_url":"https://api.github.com/users/killanch/followers","following_url":"https://api.github.com/users/killanch/following{/other_user}","gists_url":"https://api.github.com/users/killanch/gists{/gist_id}","starred_url":"https://api.github.com/users/killanch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/killanch/subscriptions","organizations_url":"https://api.github.com/users/killanch/orgs","repos_url":"https://api.github.com/users/killanch/repos","events_url":"https://api.github.com/users/killanch/events{/privacy}","received_events_url":"https://api.github.com/users/killanch/received_events","type":"User","site_admin":false},"body":"sample generated code:\r\n```\r\nimport NUAttribute from 'service/NUAttribute';\r\nimport ServiceClassRegistry from 'service/ServiceClassRegistry';\r\nimport NUEntity from 'service/NUEntity';\r\nimport { NUCommandCommandEnum, NUCommandStatusEnum, NUCommandOverrideEnum } from './enums';\r\n\r\n\r\n/* Represents Command entity\r\n   A Command represents an operation that needs to be executed on an entity (NSG, Gateway, ...)\r\n   which requires little processing by VSD, but may result in a long activity on the external\r\n   entity.  An example would be to trigger an action on VSD so that a Gateway download a new image.\r\n   VSDs handling of the request is limited to generating a message to be sent to the device on which\r\n   the download process is expected.  The device then acts on the request and proceeds with the\r\n   download...  That may be a long process.  The commands API is similar to the Jobs API with\r\n   regards to triggering operations on objects.\r\n*/\r\nexport default class NUCommand extends NUEntity {\r\n    constructor(...args) {\r\n        super(...args);\r\n        this.defineProperties({\r\n            detail: undefined,\r\n            detailedStatus: undefined,\r\n            detailedStatusCode: undefined,\r\n            command: NUCommandCommandEnum.UNKNOWN.name,\r\n            commandInformation: undefined,\r\n            associatedParam: undefined,\r\n            associatedParamType: undefined,\r\n            status: undefined,\r\n            fullCommand: undefined,\r\n            summary: undefined,\r\n            override: NUCommandOverrideEnum.UNSPECIFIED.name,\r\n        });\r\n    }\r\n\r\n    static entityDescriptor = {\r\n        description: `A Command represents an operation that needs to be executed on an entity (NSG, Gateway, ...) which requires little processing by VSD, but may result in a long activity on the external entity.  An example would be to trigger an action on VSD so that a Gateway download a new image.  VSDs handling of the request is limited to generating a message to be sent to the device on which the download process is expected.  The device then acts on the request and proceeds with the download...  That may be a long process.  The commands API is similar to the Jobs API with regards to triggering operations on objects.`,\r\n        userlabel: `Command`,\r\n    }\r\n\r\n    static attributeDescriptors = {\r\n        ...NUEntity.attributeDescriptors,\r\n        detail: new NUAttribute({\r\n            localName: 'detail',\r\n            attributeType: NUAttribute.ATTR_TYPE_STRING,\r\n            description: `Details about the command execution as reported directly from the NSG independent of status codes.`,\r\n            isReadOnly: true,\r\n            userlabel: `Detail`,\r\n        }),\r\n        detailedStatus: new NUAttribute({\r\n            localName: 'detailedStatus',\r\n            attributeType: NUAttribute.ATTR_TYPE_STRING,\r\n            description: `A string representing the detailed status of the operation that was triggered by the execution of the Command instance.`,\r\n            isReadOnly: true,\r\n            isTransient: true,\r\n            userlabel: `Detailed Status`,\r\n        }),\r\n        detailedStatusCode: new NUAttribute({\r\n            localName: 'detailedStatusCode',\r\n            attributeType: NUAttribute.ATTR_TYPE_INTEGER,\r\n            description: `A numerical code mapping to a list of detailed statuses that can apply to a Command instance.`,\r\n            isReadOnly: true,\r\n            canOrder: true,\r\n            canSearch: true,\r\n            userlabel: `Detailed Status Code`,\r\n        }),\r\n        command: new NUAttribute({\r\n            localName: 'command',\r\n            attributeType: NUAttribute.ATTR_TYPE_ENUM,\r\n            description: `Specifies the type of command that is stated for execution on the system receiving the operation request.  A request for download, a request for upgrade, a request for revocation, ...`,\r\n            isRequired: true,\r\n            isCreateOnly: true,\r\n            canOrder: true,\r\n            canSearch: true,\r\n            choices: [NUCommandCommandEnum.NSG_APPLY_PATCH,\r\n                NUCommandCommandEnum.NSG_DOWNLOAD_OS_IMAGE,\r\n                NUCommandCommandEnum.NSG_UPGRADE_TO_IMAGE, NUCommandCommandEnum.UNKNOWN],\r\n            userlabel: `Command Requested`,\r\n        }),\r\n        commandInformation: new NUAttribute({\r\n            localName: 'commandInformation',\r\n            attributeType: NUAttribute.ATTR_TYPE_STRING,\r\n            description: `Informative details on what command is to be executed.  It complements the commandType attribute.  An example of a value could be a URL, a version number, a UUID of another object, ...`,\r\n            isReadOnly: true,\r\n            userlabel: `Command Information`,\r\n        }),\r\n        associatedParam: new NUAttribute({\r\n            localName: 'associatedParam',\r\n            attributeType: NUAttribute.ATTR_TYPE_STRING,\r\n            description: `Parameters to be supplied for execution of this command. This could either be a string of parameters or ID of an object supplying parameters.`,\r\n            userlabel: `Associated Parameter`,\r\n        }),\r\n        associatedParamType: new NUAttribute({\r\n            localName: 'associatedParamType',\r\n            attributeType: NUAttribute.ATTR_TYPE_STRING,\r\n            description: `Type of the object which supplies parameters for this command.`,\r\n            canOrder: true,\r\n            canSearch: true,\r\n            userlabel: `Associated Parameter Type`,\r\n        }),\r\n        status: new NUAttribute({\r\n            localName: 'status',\r\n            attributeType: NUAttribute.ATTR_TYPE_ENUM,\r\n            description: `The status of the Command from a VSD perspective.`,\r\n            isReadOnly: true,\r\n            canOrder: true,\r\n            canSearch: true,\r\n            choices: [NUCommandStatusEnum.COMPLETE, NUCommandStatusEnum.FAILED,\r\n                NUCommandStatusEnum.STARTED, NUCommandStatusEnum.UNKNOWN],\r\n            userlabel: `Status`,\r\n        }),\r\n        fullCommand: new NUAttribute({\r\n            localName: 'fullCommand',\r\n            attributeType: NUAttribute.ATTR_TYPE_STRING,\r\n            description: `Full command including parameters that is to be executed.`,\r\n            isReadOnly: true,\r\n            userlabel: `Full Command`,\r\n        }),\r\n        summary: new NUAttribute({\r\n            localName: 'summary',\r\n            attributeType: NUAttribute.ATTR_TYPE_STRING,\r\n            description: `A generated summary for the action giving some general context on the command executed.`,\r\n            isRequired: true,\r\n            isReadOnly: true,\r\n            userlabel: `Summary`,\r\n        }),\r\n        override: new NUAttribute({\r\n            localName: 'override',\r\n            attributeType: NUAttribute.ATTR_TYPE_ENUM,\r\n            description: `Operator specified action which overrides the normal life cycle of a command.`,\r\n            canOrder: true,\r\n            canSearch: true,\r\n            choices: [NUCommandOverrideEnum.ABANDON, NUCommandOverrideEnum.UNSPECIFIED],\r\n            userlabel: `Override`,\r\n        }),\r\n    }\r\n\r\n    static getClassName() {\r\n        return 'NUCommand';\r\n    }\r\n    \r\n    static getAllowedJobCommands() {\r\n        return [];\r\n    }\r\n    \r\n    static supportsAlarms() {\r\n        return false;\r\n    }\r\n    \r\n    static getInstanceFromID(ID) {\r\n        const instance = new NUCommand();\r\n        instance.ID = ID;\r\n        return instance;\r\n    }\r\n    \r\n    get RESTName() {\r\n        return 'command';\r\n    }\r\n    \r\n    get resourceName() {\r\n        return 'commands';\r\n    }\r\n    \r\n    getClassName() {\r\n        return NUCommand.getClassName();\r\n    }\r\n\r\n    getAllowedJobCommands() {\r\n        return NUCommand.getAllowedJobCommands();\r\n    }\r\n}\r\n\r\nServiceClassRegistry.register(NUCommand);\r\n```","created_at":"2018-05-02T22:23:06Z","updated_at":"2018-05-02T22:27:24Z","closed_at":"2018-05-02T22:27:24Z","merged_at":"2018-05-02T22:27:24Z","merge_commit_sha":"21e73f5acd3c983a81e74df58c8c84a32533e397","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/nuagenetworks/monolithe/pulls/90/commits","review_comments_url":"https://api.github.com/repos/nuagenetworks/monolithe/pulls/90/comments","review_comment_url":"https://api.github.com/repos/nuagenetworks/monolithe/pulls/comments{/number}","comments_url":"https://api.github.com/repos/nuagenetworks/monolithe/issues/90/comments","statuses_url":"https://api.github.com/repos/nuagenetworks/monolithe/statuses/46026b4173c61d92cd19ed0d6288e704d0b7aa1f","head":{"label":"killanch:RODefault","ref":"RODefault","sha":"46026b4173c61d92cd19ed0d6288e704d0b7aa1f","user":{"login":"killanch","id":24920919,"avatar_url":"https://avatars2.githubusercontent.com/u/24920919?v=4","gravatar_id":"","url":"https://api.github.com/users/killanch","html_url":"https://github.com/killanch","followers_url":"https://api.github.com/users/killanch/followers","following_url":"https://api.github.com/users/killanch/following{/other_user}","gists_url":"https://api.github.com/users/killanch/gists{/gist_id}","starred_url":"https://api.github.com/users/killanch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/killanch/subscriptions","organizations_url":"https://api.github.com/users/killanch/orgs","repos_url":"https://api.github.com/users/killanch/repos","events_url":"https://api.github.com/users/killanch/events{/privacy}","received_events_url":"https://api.github.com/users/killanch/received_events","type":"User","site_admin":false},"repo":{"id":82965059,"name":"monolithe","full_name":"killanch/monolithe","owner":{"login":"killanch","id":24920919,"avatar_url":"https://avatars2.githubusercontent.com/u/24920919?v=4","gravatar_id":"","url":"https://api.github.com/users/killanch","html_url":"https://github.com/killanch","followers_url":"https://api.github.com/users/killanch/followers","following_url":"https://api.github.com/users/killanch/following{/other_user}","gists_url":"https://api.github.com/users/killanch/gists{/gist_id}","starred_url":"https://api.github.com/users/killanch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/killanch/subscriptions","organizations_url":"https://api.github.com/users/killanch/orgs","repos_url":"https://api.github.com/users/killanch/repos","events_url":"https://api.github.com/users/killanch/events{/privacy}","received_events_url":"https://api.github.com/users/killanch/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/killanch/monolithe","description":"generic and extendable code generator from specifications.","fork":true,"url":"https://api.github.com/repos/killanch/monolithe","forks_url":"https://api.github.com/repos/killanch/monolithe/forks","keys_url":"https://api.github.com/repos/killanch/monolithe/keys{/key_id}","collaborators_url":"https://api.github.com/repos/killanch/monolithe/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/killanch/monolithe/teams","hooks_url":"https://api.github.com/repos/killanch/monolithe/hooks","issue_events_url":"https://api.github.com/repos/killanch/monolithe/issues/events{/number}","events_url":"https://api.github.com/repos/killanch/monolithe/events","assignees_url":"https://api.github.com/repos/killanch/monolithe/assignees{/user}","branches_url":"https://api.github.com/repos/killanch/monolithe/branches{/branch}","tags_url":"https://api.github.com/repos/killanch/monolithe/tags","blobs_url":"https://api.github.com/repos/killanch/monolithe/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/killanch/monolithe/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/killanch/monolithe/git/refs{/sha}","trees_url":"https://api.github.com/repos/killanch/monolithe/git/trees{/sha}","statuses_url":"https://api.github.com/repos/killanch/monolithe/statuses/{sha}","languages_url":"https://api.github.com/repos/killanch/monolithe/languages","stargazers_url":"https://api.github.com/repos/killanch/monolithe/stargazers","contributors_url":"https://api.github.com/repos/killanch/monolithe/contributors","subscribers_url":"https://api.github.com/repos/killanch/monolithe/subscribers","subscription_url":"https://api.github.com/repos/killanch/monolithe/subscription","commits_url":"https://api.github.com/repos/killanch/monolithe/commits{/sha}","git_commits_url":"https://api.github.com/repos/killanch/monolithe/git/commits{/sha}","comments_url":"https://api.github.com/repos/killanch/monolithe/comments{/number}","issue_comment_url":"https://api.github.com/repos/killanch/monolithe/issues/comments{/number}","contents_url":"https://api.github.com/repos/killanch/monolithe/contents/{+path}","compare_url":"https://api.github.com/repos/killanch/monolithe/compare/{base}...{head}","merges_url":"https://api.github.com/repos/killanch/monolithe/merges","archive_url":"https://api.github.com/repos/killanch/monolithe/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/killanch/monolithe/downloads","issues_url":"https://api.github.com/repos/killanch/monolithe/issues{/number}","pulls_url":"https://api.github.com/repos/killanch/monolithe/pulls{/number}","milestones_url":"https://api.github.com/repos/killanch/monolithe/milestones{/number}","notifications_url":"https://api.github.com/repos/killanch/monolithe/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/killanch/monolithe/labels{/name}","releases_url":"https://api.github.com/repos/killanch/monolithe/releases{/id}","deployments_url":"https://api.github.com/repos/killanch/monolithe/deployments","created_at":"2017-02-23T19:47:33Z","updated_at":"2018-05-02T22:04:36Z","pushed_at":"2018-05-02T22:21:08Z","git_url":"git://github.com/killanch/monolithe.git","ssh_url":"git@github.com:killanch/monolithe.git","clone_url":"https://github.com/killanch/monolithe.git","svn_url":"https://github.com/killanch/monolithe","homepage":"","size":3695,"stargazers_count":0,"watchers_count":0,"language":"HTML","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"nuagenetworks:master","ref":"master","sha":"81848e881bd4453fb45a13f3a4db080f0c75fd90","user":{"login":"nuagenetworks","id":3334345,"avatar_url":"https://avatars1.githubusercontent.com/u/3334345?v=4","gravatar_id":"","url":"https://api.github.com/users/nuagenetworks","html_url":"https://github.com/nuagenetworks","followers_url":"https://api.github.com/users/nuagenetworks/followers","following_url":"https://api.github.com/users/nuagenetworks/following{/other_user}","gists_url":"https://api.github.com/users/nuagenetworks/gists{/gist_id}","starred_url":"https://api.github.com/users/nuagenetworks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nuagenetworks/subscriptions","organizations_url":"https://api.github.com/users/nuagenetworks/orgs","repos_url":"https://api.github.com/users/nuagenetworks/repos","events_url":"https://api.github.com/users/nuagenetworks/events{/privacy}","received_events_url":"https://api.github.com/users/nuagenetworks/received_events","type":"Organization","site_admin":false},"repo":{"id":43180465,"name":"monolithe","full_name":"nuagenetworks/monolithe","owner":{"login":"nuagenetworks","id":3334345,"avatar_url":"https://avatars1.githubusercontent.com/u/3334345?v=4","gravatar_id":"","url":"https://api.github.com/users/nuagenetworks","html_url":"https://github.com/nuagenetworks","followers_url":"https://api.github.com/users/nuagenetworks/followers","following_url":"https://api.github.com/users/nuagenetworks/following{/other_user}","gists_url":"https://api.github.com/users/nuagenetworks/gists{/gist_id}","starred_url":"https://api.github.com/users/nuagenetworks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nuagenetworks/subscriptions","organizations_url":"https://api.github.com/users/nuagenetworks/orgs","repos_url":"https://api.github.com/users/nuagenetworks/repos","events_url":"https://api.github.com/users/nuagenetworks/events{/privacy}","received_events_url":"https://api.github.com/users/nuagenetworks/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/nuagenetworks/monolithe","description":"generic and extendable code generator from specifications.","fork":false,"url":"https://api.github.com/repos/nuagenetworks/monolithe","forks_url":"https://api.github.com/repos/nuagenetworks/monolithe/forks","keys_url":"https://api.github.com/repos/nuagenetworks/monolithe/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nuagenetworks/monolithe/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nuagenetworks/monolithe/teams","hooks_url":"https://api.github.com/repos/nuagenetworks/monolithe/hooks","issue_events_url":"https://api.github.com/repos/nuagenetworks/monolithe/issues/events{/number}","events_url":"https://api.github.com/repos/nuagenetworks/monolithe/events","assignees_url":"https://api.github.com/repos/nuagenetworks/monolithe/assignees{/user}","branches_url":"https://api.github.com/repos/nuagenetworks/monolithe/branches{/branch}","tags_url":"https://api.github.com/repos/nuagenetworks/monolithe/tags","blobs_url":"https://api.github.com/repos/nuagenetworks/monolithe/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nuagenetworks/monolithe/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nuagenetworks/monolithe/git/refs{/sha}","trees_url":"https://api.github.com/repos/nuagenetworks/monolithe/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nuagenetworks/monolithe/statuses/{sha}","languages_url":"https://api.github.com/repos/nuagenetworks/monolithe/languages","stargazers_url":"https://api.github.com/repos/nuagenetworks/monolithe/stargazers","contributors_url":"https://api.github.com/repos/nuagenetworks/monolithe/contributors","subscribers_url":"https://api.github.com/repos/nuagenetworks/monolithe/subscribers","subscription_url":"https://api.github.com/repos/nuagenetworks/monolithe/subscription","commits_url":"https://api.github.com/repos/nuagenetworks/monolithe/commits{/sha}","git_commits_url":"https://api.github.com/repos/nuagenetworks/monolithe/git/commits{/sha}","comments_url":"https://api.github.com/repos/nuagenetworks/monolithe/comments{/number}","issue_comment_url":"https://api.github.com/repos/nuagenetworks/monolithe/issues/comments{/number}","contents_url":"https://api.github.com/repos/nuagenetworks/monolithe/contents/{+path}","compare_url":"https://api.github.com/repos/nuagenetworks/monolithe/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nuagenetworks/monolithe/merges","archive_url":"https://api.github.com/repos/nuagenetworks/monolithe/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nuagenetworks/monolithe/downloads","issues_url":"https://api.github.com/repos/nuagenetworks/monolithe/issues{/number}","pulls_url":"https://api.github.com/repos/nuagenetworks/monolithe/pulls{/number}","milestones_url":"https://api.github.com/repos/nuagenetworks/monolithe/milestones{/number}","notifications_url":"https://api.github.com/repos/nuagenetworks/monolithe/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nuagenetworks/monolithe/labels{/name}","releases_url":"https://api.github.com/repos/nuagenetworks/monolithe/releases{/id}","deployments_url":"https://api.github.com/repos/nuagenetworks/monolithe/deployments","created_at":"2015-09-25T23:35:30Z","updated_at":"2018-04-24T18:20:05Z","pushed_at":"2018-05-02T22:27:24Z","git_url":"git://github.com/nuagenetworks/monolithe.git","ssh_url":"git@github.com:nuagenetworks/monolithe.git","clone_url":"https://github.com/nuagenetworks/monolithe.git","svn_url":"https://github.com/nuagenetworks/monolithe","homepage":"","size":3663,"stargazers_count":11,"watchers_count":11,"language":"HTML","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":16,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause"},"forks":16,"open_issues":1,"watchers":11,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/nuagenetworks/monolithe/pulls/90"},"html":{"href":"https://github.com/nuagenetworks/monolithe/pull/90"},"issue":{"href":"https://api.github.com/repos/nuagenetworks/monolithe/issues/90"},"comments":{"href":"https://api.github.com/repos/nuagenetworks/monolithe/issues/90/comments"},"review_comments":{"href":"https://api.github.com/repos/nuagenetworks/monolithe/pulls/90/comments"},"review_comment":{"href":"https://api.github.com/repos/nuagenetworks/monolithe/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/nuagenetworks/monolithe/pulls/90/commits"},"statuses":{"href":"https://api.github.com/repos/nuagenetworks/monolithe/statuses/46026b4173c61d92cd19ed0d6288e704d0b7aa1f"}},"author_association":"CONTRIBUTOR","merged":true,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":{"login":"killanch","id":24920919,"avatar_url":"https://avatars2.githubusercontent.com/u/24920919?v=4","gravatar_id":"","url":"https://api.github.com/users/killanch","html_url":"https://github.com/killanch","followers_url":"https://api.github.com/users/killanch/followers","following_url":"https://api.github.com/users/killanch/following{/other_user}","gists_url":"https://api.github.com/users/killanch/gists{/gist_id}","starred_url":"https://api.github.com/users/killanch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/killanch/subscriptions","organizations_url":"https://api.github.com/users/killanch/orgs","repos_url":"https://api.github.com/users/killanch/repos","events_url":"https://api.github.com/users/killanch/events{/privacy}","received_events_url":"https://api.github.com/users/killanch/received_events","type":"User","site_admin":false},"comments":0,"review_comments":0,"maintainer_can_modify":false,"commits":1,"additions":1,"deletions":1,"changed_files":1}}
{"actor":{"display_login":"killanch"}}