tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lrese...@apache.org
Subject svn commit: r1527418 - in /tuscany/sca-java-2.x/branches/2.0: modules/binding-rest-runtime/src/main/java/org/apache/tuscany/sca/binding/rest/wireformat/json/provider/ modules/binding-rest-runtime/src/test/java/org/apache/tuscany/sca/binding/rest/wirefo...
Date Sun, 29 Sep 2013 22:54:34 GMT
Author: lresende
Date: Sun Sep 29 22:54:33 2013
New Revision: 1527418

URL: http://svn.apache.org/r1527418
Log:
Remove hard coded location of distribution

Modified:
    tuscany/sca-java-2.x/branches/2.0/modules/binding-rest-runtime/src/main/java/org/apache/tuscany/sca/binding/rest/wireformat/json/provider/JSONWireFormatInterceptor.java
    tuscany/sca-java-2.x/branches/2.0/modules/binding-rest-runtime/src/test/java/org/apache/tuscany/sca/binding/rest/wireformat/json/CatalogServiceTestCase.java
    tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/pom.xml
    tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/JSONDataBinding.java
    tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/JSONHelper.java
    tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JSON2OutputStream.java
    tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JacksonHelper.java
    tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/test/java/org/apache/tuscany/sca/databinding/json/JSONTransformerTestCase.java
    tuscany/sca-java-2.x/branches/2.0/testing/itest/distribution/legal-checks/pom.xml

Modified: tuscany/sca-java-2.x/branches/2.0/modules/binding-rest-runtime/src/main/java/org/apache/tuscany/sca/binding/rest/wireformat/json/provider/JSONWireFormatInterceptor.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/branches/2.0/modules/binding-rest-runtime/src/main/java/org/apache/tuscany/sca/binding/rest/wireformat/json/provider/JSONWireFormatInterceptor.java?rev=1527418&r1=1527417&r2=1527418&view=diff
==============================================================================
--- tuscany/sca-java-2.x/branches/2.0/modules/binding-rest-runtime/src/main/java/org/apache/tuscany/sca/binding/rest/wireformat/json/provider/JSONWireFormatInterceptor.java
(original)
+++ tuscany/sca-java-2.x/branches/2.0/modules/binding-rest-runtime/src/main/java/org/apache/tuscany/sca/binding/rest/wireformat/json/provider/JSONWireFormatInterceptor.java
Sun Sep 29 22:54:33 2013
@@ -33,7 +33,7 @@ import org.apache.tuscany.sca.invocation
 import org.apache.tuscany.sca.invocation.Invoker;
 import org.apache.tuscany.sca.invocation.Message;
 import org.apache.tuscany.sca.runtime.RuntimeEndpoint;
-import org.json.JSONObject;
+import org.apache.wink.json4j.JSONObject;
 
 /**
  * JSON wire format Interceptor.

Modified: tuscany/sca-java-2.x/branches/2.0/modules/binding-rest-runtime/src/test/java/org/apache/tuscany/sca/binding/rest/wireformat/json/CatalogServiceTestCase.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/branches/2.0/modules/binding-rest-runtime/src/test/java/org/apache/tuscany/sca/binding/rest/wireformat/json/CatalogServiceTestCase.java?rev=1527418&r1=1527417&r2=1527418&view=diff
==============================================================================
--- tuscany/sca-java-2.x/branches/2.0/modules/binding-rest-runtime/src/test/java/org/apache/tuscany/sca/binding/rest/wireformat/json/CatalogServiceTestCase.java
(original)
+++ tuscany/sca-java-2.x/branches/2.0/modules/binding-rest-runtime/src/test/java/org/apache/tuscany/sca/binding/rest/wireformat/json/CatalogServiceTestCase.java
Sun Sep 29 22:54:33 2013
@@ -26,8 +26,8 @@ import org.apache.tuscany.sca.node.Contr
 import org.apache.tuscany.sca.node.ContributionLocationHelper;
 import org.apache.tuscany.sca.node.Node;
 import org.apache.tuscany.sca.node.NodeFactory;
-import org.json.JSONException;
-import org.json.JSONObject;
+import org.apache.wink.json4j.JSONException;
+import org.apache.wink.json4j.JSONObject;
 import org.junit.AfterClass;
 import org.junit.Assert;
 import org.junit.BeforeClass;

Modified: tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/pom.xml
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/pom.xml?rev=1527418&r1=1527417&r2=1527418&view=diff
==============================================================================
--- tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/pom.xml (original)
+++ tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/pom.xml Sun Sep 29 22:54:33
2013
@@ -52,25 +52,13 @@
             <artifactId>jackson-xc</artifactId>
             <version>1.9.4</version>
         </dependency>
-        
-        <dependency>
-            <groupId>com.fasterxml</groupId>
-            <artifactId>jackson-module-json-org</artifactId>
-            <version>0.9.1</version>
-            <exclusions>
-                <exclusion>
-                    <groupId>junit</groupId>
-                    <artifactId>junit</artifactId>
-                </exclusion>
-            </exclusions>
-        </dependency>
-        
+         
         <dependency>
-            <groupId>org.json</groupId>
-            <artifactId>json</artifactId>
-            <version>20090211</version>
+            <groupId>org.apache.wink</groupId>
+            <artifactId>wink-json4j</artifactId>
+            <version>1.2.0-incubating</version>
         </dependency>
-        
+         
         <dependency>
             <groupId>org.slf4j</groupId>
             <artifactId>slf4j-api</artifactId>
@@ -94,6 +82,10 @@
                     <groupId>stax</groupId>
                     <artifactId>stax-api</artifactId>
                 </exclusion>
+                <exclusion>
+                    <groupId>stax</groupId>
+                    <artifactId>jsr173</artifactId>
+                </exclusion>
             </exclusions>
         </dependency>
 

Modified: tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/JSONDataBinding.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/JSONDataBinding.java?rev=1527418&r1=1527417&r2=1527418&view=diff
==============================================================================
--- tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/JSONDataBinding.java
(original)
+++ tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/JSONDataBinding.java
Sun Sep 29 22:54:33 2013
@@ -40,14 +40,14 @@ public class JSONDataBinding extends Bas
     public static final QName ROOT_ELEMENT = new QName(ROOT_NAMESPACE, "root");
 
     public JSONDataBinding() {
-        super(NAME, org.json.JSONObject.class);
+        super(NAME, org.apache.wink.json4j.JSONObject.class);
     }
 
     @Override
     public boolean introspect(DataType type, Operation operation) {
         assert type != null;
         Class cls = type.getPhysical();
-        if (JSONObject.class.isAssignableFrom(cls) || org.json.JSONObject.class.isAssignableFrom(cls))
{
+        if (JSONObject.class.isAssignableFrom(cls) || org.apache.wink.json4j.JSONObject.class.isAssignableFrom(cls))
{
             type.setDataBinding(getName());
             if (type.getLogical() == null) {
                 type.setLogical(XMLType.UNKNOWN);

Modified: tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/JSONHelper.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/JSONHelper.java?rev=1527418&r1=1527417&r2=1527418&view=diff
==============================================================================
--- tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/JSONHelper.java
(original)
+++ tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/JSONHelper.java
Sun Sep 29 22:54:33 2013
@@ -26,7 +26,7 @@ import org.codehaus.jackson.JsonNode;
 import org.codehaus.jackson.JsonParser;
 import org.codehaus.jettison.json.JSONException;
 import org.codehaus.jettison.json.JSONObject;
-import org.json.JSONArray;
+import org.apache.wink.json4j.JSONArray;
 
 /**
  * @version $Rev$ $Date$
@@ -45,7 +45,7 @@ public class JSONHelper {
         JSONObject json = null;
         if (source instanceof JSONObject) {
             json = (JSONObject)source;
-        } else if (source instanceof org.json.JSONObject || source instanceof String) {
+        } else if (source instanceof org.apache.wink.json4j.JSONObject || source instanceof
String) {
             json = stringToJettision(source.toString());
         } else if (source instanceof JsonNode) {
             json = stringToJettision(JacksonHelper.toString((JsonNode)source));
@@ -64,20 +64,20 @@ public class JSONHelper {
     }
 
     /**
-     * Convert to org.json.JSONObject
+     * Convert to org.apache.wink.json4j.JSONObject
      * @param source
      * @return
      */
-    public static org.json.JSONObject toJSONOrg(Object source) {
-        org.json.JSONObject json = null;
+    public static org.apache.wink.json4j.JSONObject toJSONOrg(Object source) {
+        org.apache.wink.json4j.JSONObject json = null;
         if (source instanceof JSONObject) {
             try {
-                json = new org.json.JSONObject(((JSONObject)source).toString());
-            } catch (org.json.JSONException e) {
+                json = new org.apache.wink.json4j.JSONObject(((JSONObject)source).toString());
+            } catch (org.apache.wink.json4j.JSONException e) {
                 throw new IllegalArgumentException(e);
             }
-        } else if (source instanceof org.json.JSONObject) {
-            json = (org.json.JSONObject)source;
+        } else if (source instanceof org.apache.wink.json4j.JSONObject) {
+            json = (org.apache.wink.json4j.JSONObject)source;
         }
         return json;
     }
@@ -91,13 +91,13 @@ public class JSONHelper {
             }
         } else {
             if (type == null) {
-                type = org.json.JSONObject.class;
+                type = org.apache.wink.json4j.JSONObject.class;
             }
             try {
                 if (type == JSONArray.class || type.isArray() || Collection.class.isAssignableFrom(type))
{
                     return new JSONArray(json);
                 }
-                return JacksonHelper.MAPPER.readValue(json, org.json.JSONObject.class);
+                return JacksonHelper.MAPPER.readValue(json, org.apache.wink.json4j.JSONObject.class);
             } catch (Exception e) {
                 throw new IllegalArgumentException(e);
             }

Modified: tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JSON2OutputStream.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JSON2OutputStream.java?rev=1527418&r1=1527417&r2=1527418&view=diff
==============================================================================
--- tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JSON2OutputStream.java
(original)
+++ tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JSON2OutputStream.java
Sun Sep 29 22:54:33 2013
@@ -30,8 +30,8 @@ import org.apache.tuscany.sca.databindin
 import org.codehaus.jackson.JsonNode;
 import org.codehaus.jackson.JsonParser;
 import org.codehaus.jackson.map.ObjectMapper;
-import org.json.JSONArray;
-import org.json.JSONObject;
+import org.apache.wink.json4j.JSONArray;
+import org.apache.wink.json4j.JSONObject;
 
 /**
  * 

Modified: tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JacksonHelper.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JacksonHelper.java?rev=1527418&r1=1527417&r2=1527418&view=diff
==============================================================================
--- tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JacksonHelper.java
(original)
+++ tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/main/java/org/apache/tuscany/sca/databinding/json/jackson/JacksonHelper.java
Sun Sep 29 22:54:33 2013
@@ -48,9 +48,9 @@ import org.codehaus.jackson.map.util.Std
 import org.codehaus.jackson.xc.JaxbAnnotationIntrospector;
 import org.codehaus.jackson.xc.XmlAdapterJsonDeserializer;
 import org.codehaus.jackson.xc.XmlAdapterJsonSerializer;
-import org.json.JSONObject;
+import org.apache.wink.json4j.JSONObject;
 
-import com.fasterxml.jackson.module.jsonorg.JsonOrgModule;
+//import com.fasterxml.jackson.module.jsonorg.JsonOrgModule;
 
 /**
  * 
@@ -91,7 +91,7 @@ public class JacksonHelper {
                             StdDeserializerProvider deserializerProvider =
                                 new StdDeserializerProvider(deserializerFactory);
                             mapper = new ObjectMapper();
-                            mapper.registerModule(new JsonOrgModule());
+                            //mapper.registerModule(new JsonOrgModule());
 
                             mapper.setSerializerFactory(serializerFactory);
                             mapper.setDeserializerProvider(deserializerProvider);
@@ -105,7 +105,7 @@ public class JacksonHelper {
         }
         if (mapper == null) {
             mapper = new ObjectMapper();
-            mapper.registerModule(new JsonOrgModule());
+            //mapper.registerModule(new JsonOrgModule());
         }
         // Let's honor the Jackson annotations first
         AnnotationIntrospector primary = new JacksonAnnotationIntrospector();
@@ -202,7 +202,7 @@ public class JacksonHelper {
     }
 
     /**
-     * Read from String into a org.json.JSONObject
+     * Read from String into a org.apache.wink.json4j.JSONObject
      * @param json
      * @return
      */

Modified: tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/test/java/org/apache/tuscany/sca/databinding/json/JSONTransformerTestCase.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/test/java/org/apache/tuscany/sca/databinding/json/JSONTransformerTestCase.java?rev=1527418&r1=1527417&r2=1527418&view=diff
==============================================================================
--- tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/test/java/org/apache/tuscany/sca/databinding/json/JSONTransformerTestCase.java
(original)
+++ tuscany/sca-java-2.x/branches/2.0/modules/databinding-json/src/test/java/org/apache/tuscany/sca/databinding/json/JSONTransformerTestCase.java
Sun Sep 29 22:54:33 2013
@@ -39,7 +39,7 @@ import org.apache.tuscany.sca.databindin
 import org.apache.tuscany.sca.interfacedef.DataType;
 import org.apache.tuscany.sca.interfacedef.impl.DataTypeImpl;
 import org.apache.tuscany.sca.interfacedef.util.XMLType;
-import org.json.JSONObject;
+import org.apache.wink.json4j.JSONObject;
 import org.junit.Test;
 
 public class JSONTransformerTestCase {

Modified: tuscany/sca-java-2.x/branches/2.0/testing/itest/distribution/legal-checks/pom.xml
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/branches/2.0/testing/itest/distribution/legal-checks/pom.xml?rev=1527418&r1=1527417&r2=1527418&view=diff
==============================================================================
--- tuscany/sca-java-2.x/branches/2.0/testing/itest/distribution/legal-checks/pom.xml (original)
+++ tuscany/sca-java-2.x/branches/2.0/testing/itest/distribution/legal-checks/pom.xml Sun
Sep 29 22:54:33 2013
@@ -56,7 +56,7 @@
                             </execution>
                         </executions>
                         <configuration>
-                           <basedir>../../../../distribution/all/target/apache-tuscany-sca-all-2.0.dir</basedir>
+                           <basedir>../../../../distribution/all/target/apache-tuscany-sca-all-${project.version}.dir</basedir>
                            <excludeSubProjects>false</excludeSubProjects>
                            <excludes> 
                               <exclude>tuscany-sca-2.0/CHANGES</exclude>



Mime
View raw message