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

[jira] [Comment Edited] (SLING-7927) JSON Content Loading errors out import on malformed json

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

Eric Norman edited comment on SLING-7927 at 8/6/19 6:06 PM:
------------------------------------------------------------

[~jebailey] How would you anticipate dealing with dependencies between the JSON files?  If loading a JSON file fails for some reason, how can you be sure the other JSON files do not depend on something loaded by the one that failed?

For example, the failing file creates some users and then the other files try to assign permissions for those users?

In other words, failing fast (and stopping the loading attempt) may be the safer approach for certain scenarios and attempting to load the other files could potentially be harmful and obscure the root reason for subsequent failures.


was (Author: edn):
[~jebailey] How would you anticipate dealing with dependencies between the JSON files?  If loading a JSON file fails for some reason, how can you be sure the other JSON files do not depend on something loaded by the one that failed?

For example, the failing file creates some users and then the other files try to assign permissions for those users?

In other words, failing fast may be the safer approach for certain scenarios and attempting to load the other files could potentially be harmful and obscure the root reason for subsequent failures.

> JSON Content Loading errors out import on malformed json
> --------------------------------------------------------
>
>                 Key: SLING-7927
>                 URL: https://issues.apache.org/jira/browse/SLING-7927
>             Project: Sling
>          Issue Type: Bug
>            Reporter: Jason E Bailey
>            Assignee: Jason E Bailey
>            Priority: Major
>             Fix For: JCR ContentLoader 2.3.2
>
>
> Current Behaviour:
> During the importing of json content from a bundle. If one of the files contains malformed json the load process is discontinued and exits. This stops the loading of any other, correctly formatted, data.
>  
> Expected Behaviour:
> If a single file contains malformed content, that specific file should discontinue, the error logged and then the process continues to import the rest of the provided content.
> As it is right now, it's possible to load the bundle and have the application in an unworkable state. preventing the ability to trouble shoot and investigate the root cause.
>  



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)