cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1220695 - in /cxf/dosgi/trunk: distribution/multi-bundle/src/main/resources/ samples/greeter_rest/client/src/main/resources/OSGI-INF/remote-service/ samples/greeter_rest/impl/src/main/java/org/apache/cxf/dosgi/samples/greeter/impl/rest/ sa...
Date Mon, 19 Dec 2011 11:22:13 GMT
Author: sergeyb
Date: Mon Dec 19 11:22:13 2011
New Revision: 1220695

URL: http://svn.apache.org/viewvc?rev=1220695&view=rev
Log:
[DOSGI-105] Improve greeter_rest demo to use HttpService and JAXB

Modified:
    cxf/dosgi/trunk/distribution/multi-bundle/src/main/resources/distro_bundles.xml
    cxf/dosgi/trunk/samples/greeter_rest/client/src/main/resources/OSGI-INF/remote-service/remote-services.xml
    cxf/dosgi/trunk/samples/greeter_rest/impl/src/main/java/org/apache/cxf/dosgi/samples/greeter/impl/rest/Activator.java
    cxf/dosgi/trunk/samples/greeter_rest/interface/pom.xml
    cxf/dosgi/trunk/samples/greeter_rest/interface/src/main/java/org/apache/cxf/dosgi/samples/greeter/rest/GreeterInfo.java
    cxf/dosgi/trunk/samples/greeter_rest/interface/src/main/java/org/apache/cxf/dosgi/samples/greeter/rest/GreetingPhrase.java

Modified: cxf/dosgi/trunk/distribution/multi-bundle/src/main/resources/distro_bundles.xml
URL: http://svn.apache.org/viewvc/cxf/dosgi/trunk/distribution/multi-bundle/src/main/resources/distro_bundles.xml?rev=1220695&r1=1220694&r2=1220695&view=diff
==============================================================================
--- cxf/dosgi/trunk/distribution/multi-bundle/src/main/resources/distro_bundles.xml (original)
+++ cxf/dosgi/trunk/distribution/multi-bundle/src/main/resources/distro_bundles.xml Mon Dec
19 11:22:13 2011
@@ -41,9 +41,9 @@
   <bundle>cxf-dosgi-ri-multibundle-distribution-${project.version}-dir/apache-cxf-dosgi-ri-${project.version}/dosgi_bundles/org.apache.servicemix.bundles.joda-time-1.5.2_4.jar</bundle>
   <bundle>cxf-dosgi-ri-multibundle-distribution-${project.version}-dir/apache-cxf-dosgi-ri-${project.version}/dosgi_bundles/org.apache.servicemix.bundles.opensaml-2.4.1_1.jar</bundle>
   <bundle>cxf-dosgi-ri-multibundle-distribution-${project.version}-dir/apache-cxf-dosgi-ri-${project.version}/dosgi_bundles/cxf-bundle-minimal-${cxf.version}.jar</bundle>
-
   <bundle>cxf-dosgi-ri-multibundle-distribution-${project.version}-dir/apache-cxf-dosgi-ri-${project.version}/dosgi_bundles/cxf-dosgi-ri-discovery-local-${project.version}.jar</bundle>
+  <bundle>cxf-dosgi-ri-multibundle-distribution-${project.version}-dir/apache-cxf-dosgi-ri-${project.version}/dosgi_bundles/org.osgi.enterprise-${osgi.version}.jar</bundle>
   <bundle>cxf-dosgi-ri-multibundle-distribution-${project.version}-dir/apache-cxf-dosgi-ri-${project.version}/dosgi_bundles/cxf-dosgi-ri-dsw-cxf-${project.version}.jar</bundle>
   <bundle>cxf-dosgi-ri-multibundle-distribution-${project.version}-dir/apache-cxf-dosgi-ri-${project.version}/dosgi_bundles/cxf-dosgi-ri-topology-manager-${project.version}.jar</bundle>
-  <bundle>cxf-dosgi-ri-multibundle-distribution-${project.version}-dir/apache-cxf-dosgi-ri-${project.version}/dosgi_bundles/org.osgi.enterprise-${osgi.version}.jar</bundle>
+  
 </bundles>

Modified: cxf/dosgi/trunk/samples/greeter_rest/client/src/main/resources/OSGI-INF/remote-service/remote-services.xml
URL: http://svn.apache.org/viewvc/cxf/dosgi/trunk/samples/greeter_rest/client/src/main/resources/OSGI-INF/remote-service/remote-services.xml?rev=1220695&r1=1220694&r2=1220695&view=diff
==============================================================================
--- cxf/dosgi/trunk/samples/greeter_rest/client/src/main/resources/OSGI-INF/remote-service/remote-services.xml
(original)
+++ cxf/dosgi/trunk/samples/greeter_rest/client/src/main/resources/OSGI-INF/remote-service/remote-services.xml
Mon Dec 19 11:22:13 2011
@@ -19,15 +19,13 @@
     <property name="service.exported.interfaces">*</property>
     <property name="service.exported.configs">org.apache.cxf.rs</property>
     <property name="service.exported.intents">HTTP</property>
-    <property name="org.apache.cxf.rs.address">http://localhost:9090/greeter</property>
-    <property name="org.apache.cxf.rs.databinding">aegis</property> 
+    <property name="org.apache.cxf.rs.address">http://localhost:8080/greeter</property>
   </service-description>
   <service-description>
     <provide interface="org.apache.cxf.dosgi.samples.greeter.rest.GreeterService2" />
     <property name="service.exported.interfaces">*</property>
     <property name="service.exported.configs">org.apache.cxf.rs</property>
     <property name="service.exported.intents">HTTP</property>
-    <property name="org.apache.cxf.rs.address">http://localhost:9091/greeter2</property>
-    <property name="org.apache.cxf.rs.databinding">aegis</property> 
+    <property name="org.apache.cxf.rs.address">http://localhost:8080/greeter2</property>
   </service-description>
 </service-descriptions>

Modified: cxf/dosgi/trunk/samples/greeter_rest/impl/src/main/java/org/apache/cxf/dosgi/samples/greeter/impl/rest/Activator.java
URL: http://svn.apache.org/viewvc/cxf/dosgi/trunk/samples/greeter_rest/impl/src/main/java/org/apache/cxf/dosgi/samples/greeter/impl/rest/Activator.java?rev=1220695&r1=1220694&r2=1220695&view=diff
==============================================================================
--- cxf/dosgi/trunk/samples/greeter_rest/impl/src/main/java/org/apache/cxf/dosgi/samples/greeter/impl/rest/Activator.java
(original)
+++ cxf/dosgi/trunk/samples/greeter_rest/impl/src/main/java/org/apache/cxf/dosgi/samples/greeter/impl/rest/Activator.java
Mon Dec 19 11:22:13 2011
@@ -33,11 +33,11 @@ public class Activator implements Bundle
     private ServiceRegistration registration2;
 
     public void start(BundleContext bc) throws Exception {
-        Dictionary props = getProperties("http://localhost:9090/greeter");
+        Dictionary props = getProperties("/greeter");
         registration = bc.registerService(GreeterService.class.getName(), 
                                           new GreeterServiceImpl(), props);
         
-        props = getProperties("http://localhost:9091/greeter2");
+        props = getProperties("/greeter2");
         registration2 = bc.registerService(GreeterService2.class.getName(), 
                                           new GreeterServiceImpl2(), props);
         
@@ -50,8 +50,7 @@ public class Activator implements Bundle
         props.put("service.exported.interfaces", "*");
         props.put("service.exported.configs", "org.apache.cxf.rs");
         props.put("service.exported.intents", "HTTP");
-        props.put("org.apache.cxf.rs.address", address);
-        props.put("org.apache.cxf.rs.databinding", "aegis");
+        props.put("org.apache.cxf.rs.httpservice.context", address);
         return props;
     }
     

Modified: cxf/dosgi/trunk/samples/greeter_rest/interface/pom.xml
URL: http://svn.apache.org/viewvc/cxf/dosgi/trunk/samples/greeter_rest/interface/pom.xml?rev=1220695&r1=1220694&r2=1220695&view=diff
==============================================================================
--- cxf/dosgi/trunk/samples/greeter_rest/interface/pom.xml (original)
+++ cxf/dosgi/trunk/samples/greeter_rest/interface/pom.xml Mon Dec 19 11:22:13 2011
@@ -33,7 +33,7 @@
     </parent>
 
     <properties>
-        <bundle.import.package>javax.ws.rs,*</bundle.import.package>
+        <bundle.import.package>javax.ws.rs,javax.xml.bind.annotation,*</bundle.import.package>
         <bundle.export.package>org.apache.cxf.dosgi.samples.greeter.rest</bundle.export.package>
     </properties>
     

Modified: cxf/dosgi/trunk/samples/greeter_rest/interface/src/main/java/org/apache/cxf/dosgi/samples/greeter/rest/GreeterInfo.java
URL: http://svn.apache.org/viewvc/cxf/dosgi/trunk/samples/greeter_rest/interface/src/main/java/org/apache/cxf/dosgi/samples/greeter/rest/GreeterInfo.java?rev=1220695&r1=1220694&r2=1220695&view=diff
==============================================================================
--- cxf/dosgi/trunk/samples/greeter_rest/interface/src/main/java/org/apache/cxf/dosgi/samples/greeter/rest/GreeterInfo.java
(original)
+++ cxf/dosgi/trunk/samples/greeter_rest/interface/src/main/java/org/apache/cxf/dosgi/samples/greeter/rest/GreeterInfo.java
Mon Dec 19 11:22:13 2011
@@ -21,6 +21,8 @@ package org.apache.cxf.dosgi.samples.gre
 import java.util.ArrayList;
 import java.util.List;
 
+import javax.xml.bind.annotation.XmlRootElement;
+@XmlRootElement
 public class GreeterInfo {
     private List<GreetingPhrase> greetings = new ArrayList<GreetingPhrase>();
     

Modified: cxf/dosgi/trunk/samples/greeter_rest/interface/src/main/java/org/apache/cxf/dosgi/samples/greeter/rest/GreetingPhrase.java
URL: http://svn.apache.org/viewvc/cxf/dosgi/trunk/samples/greeter_rest/interface/src/main/java/org/apache/cxf/dosgi/samples/greeter/rest/GreetingPhrase.java?rev=1220695&r1=1220694&r2=1220695&view=diff
==============================================================================
--- cxf/dosgi/trunk/samples/greeter_rest/interface/src/main/java/org/apache/cxf/dosgi/samples/greeter/rest/GreetingPhrase.java
(original)
+++ cxf/dosgi/trunk/samples/greeter_rest/interface/src/main/java/org/apache/cxf/dosgi/samples/greeter/rest/GreetingPhrase.java
Mon Dec 19 11:22:13 2011
@@ -18,6 +18,9 @@
   */
 package org.apache.cxf.dosgi.samples.greeter.rest;
 
+import javax.xml.bind.annotation.XmlRootElement;
+
+@XmlRootElement
 public class GreetingPhrase {
     private String phrase;
     private String name;



Mime
View raw message