You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@felix.apache.org by tm...@apache.org on 2011/03/04 02:56:25 UTC
svn commit: r1076920 - in /felix/trunk/http: ./ api/
api/src/main/java/org/apache/felix/http/api/ bundle/
bundle/src/main/java/org/apache/felix/http/bundle/internal/ cometd/
cometd/src/ cometd/src/main/ cometd/src/main/java/
cometd/src/main/java/org/ c...
Author: tmoloney
Date: Fri Mar 4 01:56:24 2011
New Revision: 1076920
URL: http://svn.apache.org/viewvc?rev=1076920&view=rev
Log:
FELIX-1796 Added cometd support to HTTP service.
Added:
felix/trunk/http/api/src/main/java/org/apache/felix/http/api/CometdService.java
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/api/src/main/java/org/apache/felix/http/api/CometdService.java
felix/trunk/http/cometd/ (props changed)
- copied from r1074406, felix/sandbox/tmoloney/http/cometd/
felix/trunk/http/cometd/DEPENDENCIES
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/cometd/DEPENDENCIES
felix/trunk/http/cometd/LICENSE
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/cometd/LICENSE
felix/trunk/http/cometd/NOTICE
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/cometd/NOTICE
felix/trunk/http/cometd/pom.xml
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/cometd/pom.xml
felix/trunk/http/cometd/src/
- copied from r1074406, felix/sandbox/tmoloney/http/cometd/src/
felix/trunk/http/cometd/src/main/
- copied from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/
felix/trunk/http/cometd/src/main/java/
- copied from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/java/
felix/trunk/http/cometd/src/main/java/org/
- copied from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/java/org/
felix/trunk/http/cometd/src/main/java/org/apache/
- copied from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/java/org/apache/
felix/trunk/http/cometd/src/main/java/org/apache/felix/
- copied from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/java/org/apache/felix/
felix/trunk/http/cometd/src/main/java/org/apache/felix/http/
- copied from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/java/org/apache/felix/http/
felix/trunk/http/cometd/src/main/java/org/apache/felix/http/cometd/
- copied from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/java/org/apache/felix/http/cometd/
felix/trunk/http/cometd/src/main/java/org/apache/felix/http/cometd/internal/
- copied from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/java/org/apache/felix/http/cometd/internal/
felix/trunk/http/cometd/src/main/java/org/apache/felix/http/cometd/internal/CometdActivator.java
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/java/org/apache/felix/http/cometd/internal/CometdActivator.java
felix/trunk/http/cometd/src/main/java/org/apache/felix/http/cometd/internal/CometdConfig.java
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/java/org/apache/felix/http/cometd/internal/CometdConfig.java
felix/trunk/http/cometd/src/main/java/org/apache/felix/http/cometd/internal/CometdServiceImpl.java
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/cometd/src/main/java/org/apache/felix/http/cometd/internal/CometdServiceImpl.java
felix/trunk/http/samples/cometd/ (props changed)
- copied from r1074406, felix/sandbox/tmoloney/http/samples/cometd/
felix/trunk/http/samples/cometd/DEPENDENCIES
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/samples/cometd/DEPENDENCIES
felix/trunk/http/samples/cometd/LICENSE
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/samples/cometd/LICENSE
felix/trunk/http/samples/cometd/NOTICE
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/samples/cometd/NOTICE
felix/trunk/http/samples/cometd/pom.xml
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/samples/cometd/pom.xml
felix/trunk/http/samples/cometd/src/
- copied from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/
felix/trunk/http/samples/cometd/src/main/
- copied from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/main/
felix/trunk/http/samples/cometd/src/main/java/
- copied from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/main/java/
felix/trunk/http/samples/cometd/src/main/java/org/
- copied from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/main/java/org/
felix/trunk/http/samples/cometd/src/main/java/org/apache/
- copied from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/main/java/org/apache/
felix/trunk/http/samples/cometd/src/main/java/org/apache/felix/
- copied from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/main/java/org/apache/felix/
felix/trunk/http/samples/cometd/src/main/java/org/apache/felix/http/
- copied from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/main/java/org/apache/felix/http/
felix/trunk/http/samples/cometd/src/main/java/org/apache/felix/http/samples/
- copied from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/main/java/org/apache/felix/http/samples/
felix/trunk/http/samples/cometd/src/main/java/org/apache/felix/http/samples/cometd/
- copied from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/main/java/org/apache/felix/http/samples/cometd/
felix/trunk/http/samples/cometd/src/main/java/org/apache/felix/http/samples/cometd/Activator.java
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/main/java/org/apache/felix/http/samples/cometd/Activator.java
felix/trunk/http/samples/cometd/src/main/java/org/apache/felix/http/samples/cometd/TimeServlet.java
- copied unchanged from r1074406, felix/sandbox/tmoloney/http/samples/cometd/src/main/java/org/apache/felix/http/samples/cometd/TimeServlet.java
Modified:
felix/trunk/http/ (props changed)
felix/trunk/http/api/pom.xml
felix/trunk/http/bundle/pom.xml
felix/trunk/http/bundle/src/main/java/org/apache/felix/http/bundle/internal/CombinedActivator.java
felix/trunk/http/pom.xml
Propchange: felix/trunk/http/
------------------------------------------------------------------------------
svn:mergeinfo = /felix/sandbox/tmoloney/http:1074406
Modified: felix/trunk/http/api/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/http/api/pom.xml?rev=1076920&r1=1076919&r2=1076920&view=diff
==============================================================================
--- felix/trunk/http/api/pom.xml (original)
+++ felix/trunk/http/api/pom.xml Fri Mar 4 01:56:24 2011
@@ -53,6 +53,12 @@
<scope>provided</scope>
</dependency>
<dependency>
+ <groupId>org.cometd.java</groupId>
+ <artifactId>cometd-api</artifactId>
+ <version>1.0.beta7</version>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.compendium</artifactId>
<scope>provided</scope>
Modified: felix/trunk/http/bundle/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/http/bundle/pom.xml?rev=1076920&r1=1076919&r2=1076920&view=diff
==============================================================================
--- felix/trunk/http/bundle/pom.xml (original)
+++ felix/trunk/http/bundle/pom.xml Fri Mar 4 01:56:24 2011
@@ -43,18 +43,21 @@
<Export-Package>
org.apache.felix.http.api;version=2.0.4;-split-package:=merge-first,
org.osgi.service.http;version=1.2.0;-split-package:=merge-first,
+ org.cometd;version=1.0.beta7,
javax.servlet.*;version=2.5;-split-package:=merge-first
</Export-Package>
<Private-Package>
org.apache.felix.http.base.*;-split-package:=merge-first,
org.apache.felix.http.bridge.*,
org.apache.felix.http.bundle.*,
+ org.apache.felix.http.cometd.*,
org.apache.felix.http.jetty.*,
org.apache.felix.http.whiteboard.*,
org.mortbay.*;-split-package:=merge-first
</Private-Package>
<Import-Package>
javax.servlet.*,
+ org.cometd,
*;resolution:=optional
</Import-Package>
</instructions>
@@ -86,6 +89,11 @@
</dependency>
<dependency>
<groupId>${pom.groupId}</groupId>
+ <artifactId>org.apache.felix.http.cometd</artifactId>
+ <version>${pom.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>${pom.groupId}</groupId>
<artifactId>org.apache.felix.http.jetty</artifactId>
<version>${pom.version}</version>
</dependency>
Modified: felix/trunk/http/bundle/src/main/java/org/apache/felix/http/bundle/internal/CombinedActivator.java
URL: http://svn.apache.org/viewvc/felix/trunk/http/bundle/src/main/java/org/apache/felix/http/bundle/internal/CombinedActivator.java?rev=1076920&r1=1076919&r2=1076920&view=diff
==============================================================================
--- felix/trunk/http/bundle/src/main/java/org/apache/felix/http/bundle/internal/CombinedActivator.java (original)
+++ felix/trunk/http/bundle/src/main/java/org/apache/felix/http/bundle/internal/CombinedActivator.java Fri Mar 4 01:56:24 2011
@@ -20,6 +20,7 @@ import org.osgi.framework.BundleActivato
import org.osgi.framework.BundleContext;
import org.apache.felix.http.bridge.internal.BridgeActivator;
import org.apache.felix.http.whiteboard.internal.WhiteboardActivator;
+import org.apache.felix.http.cometd.internal.CometdActivator;
import org.apache.felix.http.jetty.internal.JettyActivator;
public final class CombinedActivator
@@ -27,10 +28,12 @@ public final class CombinedActivator
{
private final static String JETTY_ENABLED_PROP = "org.apache.felix.http.jettyEnabled";
private final static String WHITEBOARD_ENABLED_PROP = "org.apache.felix.http.whiteboardEnabled";
+ private final static String COMETD_ENABLED_PROP = "org.apache.felix.http.cometdEnabled";
private BundleActivator jettyActivator;
private BundleActivator bridgeActivator;
private BundleActivator whiteboardActivator;
+ private BundleActivator cometdActivator;
public void start(BundleContext context)
throws Exception
@@ -45,6 +48,10 @@ public final class CombinedActivator
this.whiteboardActivator = new WhiteboardActivator();
}
+ if ("true".equals(context.getProperty(COMETD_ENABLED_PROP))) {
+ this.cometdActivator = new CometdActivator();
+ }
+
if (this.jettyActivator != null) {
this.jettyActivator.start(context);
}
@@ -56,11 +63,19 @@ public final class CombinedActivator
if (this.whiteboardActivator != null) {
this.whiteboardActivator.start(context);
}
+
+ if (this.cometdActivator != null) {
+ this.cometdActivator.start(context);
+ }
}
public void stop(BundleContext context)
throws Exception
{
+ if (this.cometdActivator != null) {
+ this.cometdActivator.stop(context);
+ }
+
if (this.whiteboardActivator != null) {
this.whiteboardActivator.stop(context);
}
Propchange: felix/trunk/http/cometd/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Fri Mar 4 01:56:24 2011
@@ -0,0 +1,4 @@
+target
+.settings
+.classpath
+.project
Modified: felix/trunk/http/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/http/pom.xml?rev=1076920&r1=1076919&r2=1076920&view=diff
==============================================================================
--- felix/trunk/http/pom.xml (original)
+++ felix/trunk/http/pom.xml Fri Mar 4 01:56:24 2011
@@ -99,10 +99,12 @@
<module>jetty</module>
<module>proxy</module>
<module>whiteboard</module>
+ <module>cometd</module>
<module>bundle</module>
<module>samples/filter</module>
<module>samples/bridge</module>
<module>samples/whiteboard</module>
+ <module>samples/cometd</module>
</modules>
<dependencies>
Propchange: felix/trunk/http/samples/cometd/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Fri Mar 4 01:56:24 2011
@@ -0,0 +1,4 @@
+target
+.settings
+.classpath
+.project