You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by "BlueRui (via GitHub)" <gi...@apache.org> on 2024/01/10 20:08:41 UTC

[I] DateTime type in ScimAttribute [directory-scimple]

BlueRui opened a new issue, #490:
URL: https://github.com/apache/directory-scimple/issues/490

   Hi,
   I tried to create an extension with an attribute of DateTime type. The example on the readme.md file shows it can be set using "type" in ScimAttribute as follows:
   ```java
     @ScimAttribute(
       description="A Boolean value indicating the User's administrative status.",
       type=Type.BOOLEAN
       )
   ```
   But ScimAttribute does not seem to support "type". I tried using java.util.Date for DateTime without setting the type in ScimAttribute. But in response, the DateTime value is displayed as the fastTime value as shown below rather than in xsd:dateTime format.
   ```json
       "urn:mem:params:scim:schemas:extension:DateExtension": {
           "dateModified": 1704302059063,
           "dateCreated": 1704302059063
       }
   ```
   What's the right way to add a DateTime attribute? Thanks
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@directory.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@directory.apache.org
For additional commands, e-mail: dev-help@directory.apache.org


Re: [I] DateTime type in ScimAttribute [directory-scimple]

Posted by "BlueRui (via GitHub)" <gi...@apache.org>.
BlueRui commented on issue #490:
URL: https://github.com/apache/directory-scimple/issues/490#issuecomment-1885739860

   I figured it out by using @XmlJavaTypeAdapter(Iso8601DateTimeAdapter.class). The readme could be updated.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@directory.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@directory.apache.org
For additional commands, e-mail: dev-help@directory.apache.org


Re: [I] DateTime type in ScimAttribute [directory-scimple]

Posted by "bdemers (via GitHub)" <gi...@apache.org>.
bdemers commented on issue #490:
URL: https://github.com/apache/directory-scimple/issues/490#issuecomment-1885833395

   Agreed!
   There are two things at play here:
   - Currently there is a little bit of duplication between the need for the `ScimAttribute` annotation and the JAXB annotations, The former is used to define the SCIM Schema and the latter for serialization. (there was talk on another issue about potentially reusing the `ScimAttribute` annotation for some serialization.
   - A missing README example for a date.
   
   Can you send us a PR for the README based on your example?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@directory.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@directory.apache.org
For additional commands, e-mail: dev-help@directory.apache.org