...
Like in Jetty, all Cipango jars are packaged with file manifests that include appropriate OSGi bundle information. This means that you can import the Cipango jars into an OSGi framework.
The module extra/cipango-clientosgi/osgi-osgisipservice
expose the an OSGi SIP service for demonstration purpose:
...
package org.cipango.client.osgi;
public interface SipService
{
public void register(int expires) throws java.io.IOException;
}
API :
Compilation
By default, the cipango-client-osgi module is modules are not compiled.
No Format |
---|
cd extra/cipango-client-osgi mvn install |
Installation in felix
...
- sip-api-1.1.jar
- servlet-api-2.5.jar
- cipango-clientdar-2.1.jar
- cipango-jmx-2.1.jar
- cipango-server-2.1-SNAPSHOT.jar
- jetty-continuation-7.25.20.v20101205v20110901.jar
- jetty-http-7.25.20.v20101205v20110901.jar
- jetty-io-7.25.20.v20101205v20110901.jar
- jetty-jmx-7.25.20.v20101205v20110901.jar
- jetty-security-7.25.20.v20101205v20110901.jar
- jetty-server-7.25.20.v20101205v20110901.jar
- jetty-servlet-7.25.20.v20101205v20110901.jar
- jetty-util-7.25.20.v20101205v20110901.jar
- jetty-webapp-7.25.20.v20101205v20110901.jar
- jetty-xml-7.25.20.v20101205v20110901.jar
Demonstration
The module extracipango-osgi/test-cipango-client-osgi-test
show a basic use of the SIP OSGi service. When this service is available, it uses it to registerregister 4 servlets (similar as the ones in extra/load-sipapp
module.
This module can be compiled and installed with the following commands:
Code Block |
---|
cd extracipango-osgi/test-cipango-client-osgi-test mvn install cp target/*test-cipango-osgi-2.1-SNAPSHOT.jar ${felix.home}/bundles cd ${felix.home} java -jar bin/felix.jar |
Then is could be tested with SIPp scripts in extra/load-sipapp/src/test/sipp
Note: The cipango-osgi/test-cipango-osgi
module is also used for integration tests.