You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "Marcus Lagemann (JIRA)" <ji...@apache.org> on 2016/06/10 17:30:21 UTC

[jira] [Created] (GROOVY-7858) Make JsonBuilder configurable to not write entries with null values

Marcus Lagemann created GROOVY-7858:
---------------------------------------

             Summary: Make JsonBuilder configurable to not write entries with null values
                 Key: GROOVY-7858
                 URL: https://issues.apache.org/jira/browse/GROOVY-7858
             Project: Groovy
          Issue Type: Improvement
          Components: JSON
    Affects Versions: 2.4.5
            Reporter: Marcus Lagemann
            Priority: Trivial


{{JsonBuilder}} (and underlying {{JsonOutput}} ) is writing entries with null values when serializing to Json String:
{code:javascript}
 {"key1": "value",
  "key2": null}
{code}

There should be a flag or configuration value to change this behaviour and skip writing entries where the values are null.

{code:javascript}
 {"key1": "value"}
{code}




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)