Shindig
  1. Shindig
  2. SHINDIG-1424

endless loop while encoding POJOs to JSON

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 2.0.0
    • Fix Version/s: None
    • Component/s: Java
    • Labels:
      None

      Description

      my POJO includes a getter named "getSingleton" which return an instance of the same class, due to the way org.apache.shindig.common.JsonUtil.getGetters is buit this is causing an endless loop when trying to serialize the POJO into JSON. unfortunately the "getSingleton" getter is required by another interface, thus, i cannot simply rename it to overcome the naming convention issue.

      my proposed solution would be to introduce a way to hint JsonUtil.getGetters to ignore the getter, perhaps a new annotation or a magic phrase in JsonProperty annotation.

        Activity

        tomer doron created issue -
        tomer doron made changes -
        Field Original Value New Value
        Description my POJO includes a getter named "getSinglton" which return an instance of the same same class, due to the way org.apache.shindig.common.JsonUtil.getGetters is buit this is causing an endless loop when trying to serialize the POJO into JSON. unfortunately the "getSinglton" getter is required by another interface, thus,, i cannot simply rename it to overcome the naming convention issue.

        my proposed solution would be to introduce a way to hint JsonUtil.getGetters to ignore the getter, perhaps a new annotation or a magic phrase in JsonProperty annotation.
        my POJO includes a getter named "getSinglton" which return an instance of the same class, due to the way org.apache.shindig.common.JsonUtil.getGetters is buit this is causing an endless loop when trying to serialize the POJO into JSON. unfortunately the "getSinglton" getter is required by another interface, thus,, i cannot simply rename it to overcome the naming convention issue.

        my proposed solution would be to introduce a way to hint JsonUtil.getGetters to ignore the getter, perhaps a new annotation or a magic phrase in JsonProperty annotation.
        tomer doron made changes -
        Description my POJO includes a getter named "getSinglton" which return an instance of the same class, due to the way org.apache.shindig.common.JsonUtil.getGetters is buit this is causing an endless loop when trying to serialize the POJO into JSON. unfortunately the "getSinglton" getter is required by another interface, thus,, i cannot simply rename it to overcome the naming convention issue.

        my proposed solution would be to introduce a way to hint JsonUtil.getGetters to ignore the getter, perhaps a new annotation or a magic phrase in JsonProperty annotation.
        my POJO includes a getter named "getSingleton" which return an instance of the same class, due to the way org.apache.shindig.common.JsonUtil.getGetters is buit this is causing an endless loop when trying to serialize the POJO into JSON. unfortunately the "getSingleton" getter is required by another interface, thus,, i cannot simply rename it to overcome the naming convention issue.

        my proposed solution would be to introduce a way to hint JsonUtil.getGetters to ignore the getter, perhaps a new annotation or a magic phrase in JsonProperty annotation.
        tomer doron made changes -
        Description my POJO includes a getter named "getSingleton" which return an instance of the same class, due to the way org.apache.shindig.common.JsonUtil.getGetters is buit this is causing an endless loop when trying to serialize the POJO into JSON. unfortunately the "getSingleton" getter is required by another interface, thus,, i cannot simply rename it to overcome the naming convention issue.

        my proposed solution would be to introduce a way to hint JsonUtil.getGetters to ignore the getter, perhaps a new annotation or a magic phrase in JsonProperty annotation.
        my POJO includes a getter named "getSingleton" which return an instance of the same class, due to the way org.apache.shindig.common.JsonUtil.getGetters is buit this is causing an endless loop when trying to serialize the POJO into JSON. unfortunately the "getSingleton" getter is required by another interface, thus, i cannot simply rename it to overcome the naming convention issue.

        my proposed solution would be to introduce a way to hint JsonUtil.getGetters to ignore the getter, perhaps a new annotation or a magic phrase in JsonProperty annotation.
        Gavin made changes -
        Workflow jira [ 12520021 ] patch-available, re-open possible [ 12629740 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            tomer doron
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:

              Development