[
https://issues.apache.org/jira/browse/GEODE-629?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15805820#comment-15805820
]
Anthony Baker commented on GEODE-629:
-------------------------------------
These changes have been made since the above patch was posted:
{code}
commit 1b8a35734a7808623f0247ad5f82de92aea70c14
Author: Jens Deppe <[email protected]>
Date: Fri Nov 6 08:53:25 2015 -0800
GEODE-533: GFSH query swaps row values when they are null
diff --git a/gemfire-json/src/main/java/org/json/JSONObject.java
b/gemfire-json/src/main/java/org/json/JSONObject.java
index 63676cc..6c478db 100755
--- a/gemfire-json/src/main/java/org/json/JSONObject.java
+++ b/gemfire-json/src/main/java/org/json/JSONObject.java
@@ -999,6 +999,8 @@ public class JSONObject {
Object result = method.invoke(bean, (Object[])null);
if (result != null) {
this.map.put(key, wrap(result));
+ } else if (!method.getReturnType().isArray()) {
+ this.map.put(key, JSONObject.NULL);
}
}
}
{code}
{code}
commit 90e00bf97d4287f5462cf73eab2b5810c69c7077
Author: Jinmei Liao <[email protected]>
Date: Thu Jul 28 09:11:56 2016 -0700
GEODE-1569: post process for serialized domain objects
* for client/server retreival, post process the value before it was put
into the message
* for gfsh commands, post process the value before it was put into the
command result json
diff --git a/geode-json/src/main/java/org/json/JSONObject.java
b/geode-json/src/main/java/org/json/JSONObject.java
index 24f5cc7..a2c67a9 100755
--- a/geode-json/src/main/java/org/json/JSONObject.java
+++ b/geode-json/src/main/java/org/json/JSONObject.java
@@ -32,7 +32,6 @@ import java.lang.reflect.Method;
import java.lang.reflect.Modifier;
import java.util.Collection;
import java.util.Enumeration;
-import java.util.HashSet;
import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.Locale;
@@ -95,7 +94,6 @@ import java.util.Set;
* @version 2012-05-29
*/
public class JSONObject {
-
/**
* JSONObject.NULL is equivalent to the value that JavaScript calls null,
* whilst Java's null is equivalent to the value that JavaScript calls
@@ -1481,9 +1479,8 @@ public class JSONObject {
return object.toString();
}
- if(cyclicDepChkEnabled.get() != null){
- if (cyclicDepChkEnabled.get()
- && cyclicDependencySet.get().contains(object)) {
+ if(cyclicDepChkEnabled.get()!=null &&
cyclicDependencySet.get()!=null){
+ if (cyclicDepChkEnabled.get() &&
cyclicDependencySet.get().contains(object)) {
//break cyclic reference
return object.getClass().getCanonicalName();
}else {
{code}
> Replace use of org.json with Jackson JSON library
> -------------------------------------------------
>
> Key: GEODE-629
> URL: https://issues.apache.org/jira/browse/GEODE-629
> Project: Geode
> Issue Type: Improvement
> Components: serialization
> Reporter: Jens Deppe
> Attachments: json.patch
>
>
> Currently we're using two different JSON libraries; org.json and jackson. We
> have customized org.json in the module gemfire-json.
> We should try and consolidate on a single JSON library - namely jackson as it
> is much more capable than org.json.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)