[
https://issues.apache.org/jira/browse/SYNCOPE-1274?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16362552#comment-16362552
]
ASF subversion and git services commented on SYNCOPE-1274:
----------------------------------------------------------
Commit 0e93bec6c37c9d8a2d0b1d69613e8173cd49726e in syncope's branch
refs/heads/master from [~ilgrosso]
[ https://git-wip-us.apache.org/repos/asf?p=syncope.git;h=0e93bec ]
[SYNCOPE-1274] Using Swagger annotations for TO hierarchies
> Report required and read-only payload properties in OpenApi spec
> ----------------------------------------------------------------
>
> Key: SYNCOPE-1274
> URL: https://issues.apache.org/jira/browse/SYNCOPE-1274
> Project: Syncope
> Issue Type: Improvement
> Components: common
> Affects Versions: 2.0.7
> Reporter: Francesco Chicchiriccò
> Assignee: Francesco Chicchiriccò
> Priority: Major
> Labels: openapi, swagger
> Fix For: 2.0.8, 2.1.0
>
> Attachments: model-after.png, model-before.png
>
>
> The OpenApi spec is currently missing any required and read-only information
> about payload properties.
> For example, the {{POST /users}} endpoint reports the following sample value:
> {code:java}
> {
> "creator": "string",
> "creationDate": "2018-02-11T14:19:38.905Z",
> "lastModifier": "string",
> "lastChangeDate": "2018-02-11T14:19:38.905Z",
> "key": "string",
> "type": "string",
> "realm": "string",
> "status": "string",
> "password": "string",
> "token": "string",
> "tokenExpireTime": "2018-02-11T14:19:38.905Z",
> "username": "string",
> "lastLoginDate": "2018-02-11T14:19:38.905Z",
> "changePwdDate": "2018-02-11T14:19:38.905Z",
> "failedLogins": 0,
> "securityQuestion": "string",
> "securityAnswer": "string",
> "suspended": true,
> "mustChangePassword": true
> }
> {code}
> which should be better instead
> {code:java}
> {
> "realm": "string",
> "@class": "org.apache.syncope.common.lib.to.UserTO",
> "password": "string",
> "username": "string",
> "securityQuestion": "string",
> "securityAnswer": "string"
> }
> {code}
> (also note the Jackson's {{@class}} management).
> Similar for models (see attachments as samples).
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)