You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Bertrand Delacretaz (JIRA)" <ji...@apache.org> on 2018/08/22 14:06:00 UTC

[jira] [Comment Edited] (SLING-7844) Format change in JSON date format due to SLING-7670

    [ https://issues.apache.org/jira/browse/SLING-7844?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16588895#comment-16588895 ] 

Bertrand Delacretaz edited comment on SLING-7844 at 8/22/18 2:05 PM:
---------------------------------------------------------------------

Earlier, Jason said:
{quote}There is a configuration option in place right now, so if there is a need to change the default, it's a simple change
{quote}
So I think changing the default value of that configuration to "legacy mode" should fulfill our backward compatibility requirements? And maybe log an INFO message if that legacy mode is active, and document it at [https://sling.apache.org/documentation/bundles/rendering-content-default-get-servlets.html] to give new users a good chance of finding that setting?

IIUC that configuration is the DefaultGetServlet's "ecmaSupport" parameter, if that's correct I think a better label would be "Legacy ECMA date format" and description "Enable legacy Sling ECMA format for dates" to make things clearer.

_Update: I see Stefan's comment in the meantime, great idea! But my proposal for more precise configuration parameter names stands._

[1] [https://github.com/apache/sling-org-apache-sling-servlets-get/blob/master/src/main/java/org/apache/sling/servlets/get/impl/DefaultGetServlet.java#L132]


was (Author: bdelacretaz):
Earlier, Jason said:
{quote}There is a configuration option in place right now, so if there is a need to change the default, it's a simple change
{quote}
So I think changing the default value of that configuration to "legacy mode" should fulfill our backward compatibility requirements? And maybe log an INFO message if that legacy mode is active, and document it at [https://sling.apache.org/documentation/bundles/rendering-content-default-get-servlets.html] to give new users a good chance of finding that setting?

IIUC that configuration is the DefaultGetServlet's "ecmaSupport" parameter, if that's correct I think a better label would be "Legacy ECMA date format" and description "Enable legacy Sling ECMA format for dates" to make things clearer.

[1] https://github.com/apache/sling-org-apache-sling-servlets-get/blob/master/src/main/java/org/apache/sling/servlets/get/impl/DefaultGetServlet.java#L132

> Format change in JSON date format due to SLING-7670
> ---------------------------------------------------
>
>                 Key: SLING-7844
>                 URL: https://issues.apache.org/jira/browse/SLING-7844
>             Project: Sling
>          Issue Type: Bug
>          Components: Servlets
>    Affects Versions: Servlets Get 2.1.32
>            Reporter: Carsten Ziegeler
>            Assignee: Robert Munteanu
>            Priority: Major
>             Fix For: Servlets Get 2.1.34
>
>
> SLING-7670 changes the default rendering of a date in JSON by default which is an incompatible change and potentially breaks clients.
> The default of the servlet should generate the old format, the new format must require a config change.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)