cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From conflue...@apache.org
Subject [CONF] Apache CXF > DOSGi Multi Bundle Distribution
Date Mon, 07 Jan 2013 14:44:00 GMT
<html>
<head>
    <base href="https://cwiki.apache.org/confluence">
            <link rel="stylesheet" href="/confluence/s/2042/9/15/_/styles/combined.css?spaceKey=CXF&amp;forWysiwyg=true"
type="text/css">
    </head>
<body style="background: white;" bgcolor="white" class="email-body">
<div id="pageContent">
<div id="notificationFormat">
<div class="wiki-content">
<div class="email">
    <h2><a href="https://cwiki.apache.org/confluence/display/CXF/DOSGi+Multi+Bundle+Distribution">DOSGi
Multi Bundle Distribution</a></h2>
    <h4>Page <b>edited</b> by             <a href="https://cwiki.apache.org/confluence/display/~christian%2Bschneider">Christian
Schneider</a>
    </h4>
        <br/>
                         <h4>Changes (19)</h4>
                                 
    
<div id="page-diffs">
                    <table class="diff" cellpadding="0" cellspacing="0">
    
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" >The multi-bundle distribution of CXF/DOSGi
contains all the DOSGi bundles plus their dependencies as individual bundles. While the single-bundle
distribution is certainly easier to get started with, the multi-bundle distro is more flexible
wrt to sharing bundles and updating dependencies. To obtain a multi bundle distribution see
the [DOSGi Releases] page. <br> <br></td></tr>
            <tr><td class="diff-changed-lines" >h2. Setting up Felix <span
class="diff-added-words"style="background-color: #dfd;">(verified with 4.0.3)</span>
<br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">_Verified
with: Felix 4.0.2_ <br></td></tr>
            <tr><td class="diff-unchanged" > <br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">In
the distribution you will find a file called: {{.../conf/felix.config.properties.append}}.
This file contains auto-start instructions for every bundle in the distribution. <br>#
Simply copy the content of the whole file and append it to the {{conf/config.properties}}
file of the Felix distribution.  <br># Fix the {{file:apache-cxf-dosgi-ri}} URLs in
the file to point to where you have unzipped the distribution. <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">Change
directory to the felix framework main dir. Unpack the cxf dosgi distro there. Append the felix
config from the distro to the felix config.properties. Start felix. <br></td></tr>
            <tr><td class="diff-unchanged" > <br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">At
the end the {{conf/config.properties}} file looks like this: <br>{code}... existing
lines ... <br>org.ops4j.pax.web.session.timeout=30 <br>org.osgi.framework.startlevel.beginning=95
<br> <br>felix.auto.start.51=file:///c:/apache-cxf-dosgi-ri-1.3/dosgi_bundles/geronimo-annotation_1.0_spec-1.1.1.jar
<br>felix.auto.start.52=file:///c:/apache-cxf-dosgi-ri-1.3/dosgi_bundles/geronimo-activation_1.1_spec-1.1.0.jar
<br>... and so on ... <br> <br>You may need to update the &#39;org.osgi.framework.system.packages.extra&#39;
to reference the org.w3c.dom.traversal package. <br>Also a felix.startlevel.bundle may
need to be uncommented and set to 95; that may be needed to make sure the custom bundles importing
annotations will always be started after the spec bundles have been loaded. <br></td></tr>
            <tr><td class="diff-unchanged" >{code} <br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">Now
start Felix: <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">tar
-xzvf cxf-dosgi-ri-multibundle-distribution-1.4-SNAPSHOT-dir.tar.gz <br>cat apache-cxf-dosgi-ri-1.4-SNAPSHOT/conf/felix.config.properties.append
&gt;&gt; conf/config.properties <br></td></tr>
            <tr><td class="diff-changed-lines" ><span class="diff-deleted-words"style="color:#999;background-color:#fdd;text-decoration:line-through;">{code}.../felix-4.0.2&gt;</span>
java -jar bin/felix.jar <br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">
<br>Welcome to Felix. <br>================= <br>... some log messages may
appear ... <br>-&gt; bundles <br>    ID   State         Level  Name <br>
   0|Active     |    0|org.apache.felix.framework (4.0.2) <br>    1|Active     |   
1|org.apache.felix.bundlerepository (1.6.6) <br>    2|Active     |    1|org.apache.felix.gogo.command
(0.12.0) <br>    3|Active     |    1|org.apache.felix.gogo.runtime (0.10.0) <br>
   4|Active     |    1|org.apache.felix.gogo.shell (0.10.0) <br>    5|Active     | 
 85|org.apache.servicemix.specs.stax-api-1.0 (1.9.0) <br>    6|Active     |   53|org.apache.geronimo.specs.geronimo-javamail_1.4_spec
(1.2.0) <br>    7|Active     |   84|org.apache.servicemix.specs.saaj-api-1.3 (1.9.0)
<br>    8|Active     |   52|org.apache.geronimo.specs.geronimo-activation_1.1_spec (1.1.0)
<br>    9|Active     |   83|org.apache.servicemix.bundles.commons-pool (1.5.4.1) <br>
  10|Active     |   51|org.apache.geronimo.specs.geronimo-annotation_1.0_spec (1.1.1) <br>
  11|Active     |   82|woodstox-core-asl (4.1.1) <br>   12|Active     |   81|stax2-api
(3.1.1) <br>   13|Active     |   80|org.apache.neethi (3.0.1) <br>   14|Active
    |   79|org.apache.servicemix.bundles.xmlresolver (1.2.0.4) <br>   15|Active    
|   78|org.apache.servicemix.bundles.asm (3.3.0.2) <br>   16|Active     |   77|org.apache.ws.xmlschema.core
(2.0.1) <br>   17|Active     |   76|org.apache.servicemix.bundles.xmlsec (1.4.5.1) <br>
  18|Active     |   75|org.apache.servicemix.bundles.wsdl4j (1.6.2.5) <br>   19|Active
    |   74|org.apache.servicemix.bundles.jaxb-impl (2.1.13.2) <br>   20|Active     |
  73|org.ops4j.pax.web.pax-web-jetty (1.0.3) <br>   21|Active     |   72|org.ops4j.pax.web.pax-web-runtime
(1.0.3) <br>   22|Active     |   71|org.ops4j.pax.web.pax-web-spi (1.0.3) <br>
  23|Active     |   70|org.eclipse.jetty.aggregate.jetty-all-server (7.4.2.v20110526) <br>
  24|Active     |   69|org.springframework.osgi.extender (1.2.1) <br>   25|Active  
  |   68|org.springframework.osgi.core (1.2.1) <br>   26|Active     |   67|org.springframework.osgi.io
(1.2.1) <br>   27|Active     |   66|org.springframework.expression (3.0.6.RELEASE) <br>
  28|Active     |   65|org.springframework.asm (3.0.6.RELEASE) <br>   29|Active    
|   64|org.springframework.aop (3.0.6.RELEASE) <br>   30|Active     |   95|cxf-dosgi-ri-topology-manager
(1.3.0.SNAPSHOT) <br>   31|Resolved   |   63|com.springsource.slf4j.jcl (1.5.10) <br>
  32|Active     |   94|cxf-dosgi-ri-dsw-cxf (1.3.0.SNAPSHOT) <br>   33|Active     |
  62|com.springsource.slf4j.api (1.5.10) <br>   34|Active     |   93|osgi.enterprise
(4.2.0.201003190513) <br>   35|Active     |   61|com.springsource.org.aopalliance (1.0.0)
<br>   36|Active     |   92|cxf-dosgi-ri-discovery-local (1.3.0.SNAPSHOT) <br>
  37|Active     |   60|org.springframework.context (3.0.6.RELEASE) <br>   38|Active
    |   91|org.apache.cxf.bundle-minimal (2.5.2) <br>   39|Active     |   90|org.apache.servicemix.bundles.opensaml
(2.4.1.1) <br>   40|Active     |   59|org.springframework.beans (3.0.6.RELEASE) <br>
  41|Active     |   58|org.springframework.core (3.0.6.RELEASE) <br>   42|Active   
 |   89|org.apache.servicemix.bundles.joda-time (1.5.2.4) <br>   43|Active     |   57|com.springsource.org.jdom
(1.1.0) <br>   44|Active     |   88|org.apache.servicemix.specs.jsr311-api-1.1.1 (1.9.0)
<br>   45|Active     |   56|com.springsource.org.apache.commons.logging (1.1.1) <br>
  46|Active     |   87|org.apache.servicemix.specs.jaxws-api-2.1 (1.9.0) <br>   47|Active
    |   55|org.apache.geronimo.specs.geronimo-ws-metadata_2.0_spec (1.1.3) <br>   48|Active
    |   86|org.apache.servicemix.specs.jaxb-api-2.1 (1.9.0) <br>   49|Active     | 
 54|org.apache.geronimo.specs.geronimo-servlet_3.0_spec (1.0.0) <br> <br></td></tr>
            <tr><td class="diff-unchanged" >{code} <br> <br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">h2.
Setting up Equinox <br>_Verified with: Eclipse/Equinox 3.6.2_ <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">Verify
that all bundles are in state Active. There should be no exceptions in the logs. <br></td></tr>
            <tr><td class="diff-unchanged" > <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">h2.
Setting up Eclipse Equinox (verified with  Equinox 3.6.2) <br> <br></td></tr>
            <tr><td class="diff-unchanged" >In the distribution you will find
a file called: {{.../conf/equinox.config.ini.append}}. This file contains auto-start instructions
for every bundle in the distribution. <br># Create a directory in the Equinox installation,
e.g. {{dosgi_conf}} and create a file called {{config.ini}} in this directory with the content
of the {{equinox.config.ini.append}} file. <br></td></tr>
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" >c:/apache-cxf-dosgi-ri-1.3/dosgi_bundles/geronimo-annotation_1.0_spec-1.1.1.jar@start,
c:/apache-cxf-dosgi-ri-1.3/dosgi_bundles/geronimo-activation_1.1_spec-1.0.2.jar@start,  <br>...
and so on ...{code} <br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">Now
start Equinox: <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">Now
start Equinox and verify that all bundles are in state Active <br>{code} <br></td></tr>
            <tr><td class="diff-changed-lines" ><span class="diff-deleted-words"style="color:#999;background-color:#fdd;text-decoration:line-through;">{code}.../eclipse&gt;</span>
java -jar plugins/org.eclipse.osgi_3.6.2.R36x_v20110210.jar -console -configuration dosgi_conf
<br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">...
some log messages may appear ... <br></td></tr>
            <tr><td class="diff-unchanged" >osgi&gt; ss <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">{code]
<br></td></tr>
            <tr><td class="diff-unchanged" > <br></td></tr>
            <tr><td class="diff-deleted-lines" style="color:#999;background-color:#fdd;text-decoration:line-through;">Framework
is launched. <br> <br>id      State       Bundle <br>0	ACTIVE      org.eclipse.osgi_3.6.2.R36x_v20110210
<br>1	ACTIVE      org.apache.geronimo.specs.geronimo-annotation_1.0_spec_1.1.1 <br>2
ACTIVE      org.apache.geronimo.specs.geronimo-activation_1.1_spec_1.1.0 <br>3	ACTIVE
     org.apache.geronimo.specs.geronimo-javamail_1.4_spec_1.2.0 <br>4	ACTIVE      org.apache.geronimo.specs.geronimo-servlet_3.0_spec_1.0.0
<br>5	ACTIVE      org.apache.geronimo.specs.geronimo-ws-metadata_2.0_spec_1.1.3 <br>6
ACTIVE      com.springsource.org.apache.commons.logging_1.1.1 <br>7	ACTIVE      com.springsource.org.jdom_1.1.0
<br>8	ACTIVE      org.springframework.core_3.0.6.RELEASE <br>9	ACTIVE      org.springframework.beans_3.0.6.RELEASE
<br>10	ACTIVE      org.springframework.context_3.0.6.RELEASE <br>12	ACTIVE   
  com.springsource.org.aopalliance_1.0.0 <br>13	ACTIVE      com.springsource.slf4j.api_1.5.10
<br>	            Fragments=14 <br>14	RESOLVED    com.springsource.slf4j.jcl_1.5.10
<br>	            Master=13 <br>15	ACTIVE      org.springframework.aop_3.0.6.RELEASE
<br>16	ACTIVE      org.springframework.asm_3.0.6.RELEASE <br>17	ACTIVE      org.springframework.expression_3.0.6.RELEASE
<br>18	ACTIVE      org.springframework.osgi.io_1.2.1 <br>19	ACTIVE      org.springframework.osgi.core_1.2.1
<br>20	ACTIVE      org.springframework.osgi.extender_1.2.1 <br>21	ACTIVE     
org.eclipse.jetty.aggregate.jetty-all-server_7.4.2.v20110526 <br>22	ACTIVE      org.ops4j.pax.web.pax-web-spi_1.0.8
<br>23	ACTIVE      org.ops4j.pax.web.pax-web-runtime_1.0.8 <br>24	ACTIVE     
org.ops4j.pax.web.pax-web-jetty_1.0.8 <br>25	ACTIVE      org.apache.servicemix.bundles.jaxb-impl_2.1.13.2
<br>26	ACTIVE      org.apache.servicemix.bundles.wsdl4j_1.6.2.5 <br>27	ACTIVE
     org.apache.servicemix.bundles.xmlsec_1.4.5.1 <br>28	ACTIVE      org.apache.ws.xmlschema.core_2.0.1
<br>29	ACTIVE      org.apache.servicemix.bundles.asm_3.3.0.2 <br>30	ACTIVE   
  org.apache.servicemix.bundles.xmlresolver_1.2.0.4 <br>31	ACTIVE      org.apache.neethi_3.0.1
<br>32	ACTIVE      stax2-api_3.1.1 <br>33	ACTIVE      woodstox-core-asl_4.1.1
<br>34	ACTIVE      org.apache.servicemix.bundles.commons-pool_1.5.4.1 <br>35	ACTIVE
     org.apache.servicemix.specs.saaj-api-1.3_1.9.0 <br>36	ACTIVE      org.apache.servicemix.specs.stax-api-1.0_1.9.0
<br>37	ACTIVE      org.apache.servicemix.specs.jaxb-api-2.1_1.9.0 <br>38	ACTIVE
     org.apache.servicemix.specs.jaxws-api-2.1_1.9.0 <br>39	ACTIVE      org.apache.servicemix.specs.jsr311-api-1.1.1_1.9.0
<br>40	ACTIVE      org.apache.servicemix.bundles.joda-time_1.5.2.4 <br>41	ACTIVE
     org.apache.servicemix.bundles.opensaml_2.4.1.1 <br>42	ACTIVE      org.apache.cxf.bundle-minimal_2.5.0
<br>43	ACTIVE      cxf-dosgi-ri-discovery-local_1.3.0.SNAPSHOT <br>44	ACTIVE 
    osgi.enterprise_4.2.0.201003190513 <br>45	ACTIVE      cxf-dosgi-ri-dsw-cxf_1.3.0.SNAPSHOT
<br>46	ACTIVE      cxf-dosgi-ri-topology-manager_1.3.0.SNAPSHOT <br>{code} <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">h2.
In both cases install the greeter demo to check if services are exported correctly <br></td></tr>
    
            </table>
    </div>                            <h4>Full Content</h4>
                    <div class="notificationGreySide">
        <h1><a name="DOSGiMultiBundleDistribution-SettinguptheMultiBundleDistributionofCXFDistributedOSGi"></a>Setting
up the Multi Bundle Distribution of CXF Distributed OSGi</h1>
<p>The multi-bundle distribution of CXF/DOSGi contains all the DOSGi bundles plus their
dependencies as individual bundles. While the single-bundle distribution is certainly easier
to get started with, the multi-bundle distro is more flexible wrt to sharing bundles and updating
dependencies. To obtain a multi bundle distribution see the <a href="/confluence/display/CXF/DOSGi+Releases"
title="DOSGi Releases">DOSGi Releases</a> page.</p>

<h2><a name="DOSGiMultiBundleDistribution-SettingupFelix%28verifiedwith4.0.3%29"></a>Setting
up Felix (verified with 4.0.3)</h2>

<p>Change directory to the felix framework main dir. Unpack the cxf dosgi distro there.
Append the felix config from the distro to the felix config.properties. Start felix.</p>

<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="code-java">
tar -xzvf cxf-dosgi-ri-multibundle-distribution-1.4-SNAPSHOT-dir.tar.gz
cat apache-cxf-dosgi-ri-1.4-SNAPSHOT/conf/felix.config.properties.append &gt;&gt;
conf/config.properties
java -jar bin/felix.jar
</pre>
</div></div>

<p>Verify that all bundles are in state Active. There should be no exceptions in the
logs.</p>

<h2><a name="DOSGiMultiBundleDistribution-SettingupEclipseEquinox%28verifiedwithEquinox3.6.2%29"></a>Setting
up Eclipse Equinox (verified with  Equinox 3.6.2)</h2>

<p>In the distribution you will find a file called: <tt>.../conf/equinox.config.ini.append</tt>.
This file contains auto-start instructions for every bundle in the distribution.</p>
<ol>
	<li>Create a directory in the Equinox installation, e.g. <tt>dosgi_conf</tt>
and create a file called <tt>config.ini</tt> in this directory with the content
of the <tt>equinox.config.ini.append</tt> file.</li>
	<li>Fix the <tt>../apache-cxf-dosgi-ri</tt> path locations in the file
to point to where you have unzipped the distribution.</li>
</ol>


<p>At the end the <tt>dosgi_conf/config.ini</tt> file looks like this:</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="code-java">org.ops4j.pax.web.session.timeout=30
osgi.bundles=org.eclipse.osgi.services@start, \
c:/apache-cxf-dosgi-ri-1.3/dosgi_bundles/geronimo-annotation_1.0_spec-1.1.1.jar@start, c:/apache-cxf-dosgi-ri-1.3/dosgi_bundles/geronimo-activation_1.1_spec-1.0.2.jar@start,

... and so on ...</pre>
</div></div>
<p>Now start Equinox and verify that all bundles are in state Active</p>
<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="code-java"></pre>
</div></div>
<p>java -jar plugins/org.eclipse.osgi_3.6.2.R36x_v20110210.jar -console -configuration
dosgi_conf<br/>
osgi&gt; ss<br/>
{code]</p>

<h2><a name="DOSGiMultiBundleDistribution-Inbothcasesinstallthegreeterdemotocheckifservicesareexportedcorrectly"></a>In
both cases install the greeter demo to check if services are exported correctly</h2>


    </div>
        <div id="commentsSection" class="wiki-content pageSection">
        <div style="float: right;">
            <a href="https://cwiki.apache.org/confluence/users/viewnotifications.action"
class="grey">Change Notification Preferences</a>
        </div>
        <a href="https://cwiki.apache.org/confluence/display/CXF/DOSGi+Multi+Bundle+Distribution">View
Online</a>
        |
        <a href="https://cwiki.apache.org/confluence/pages/diffpagesbyversion.action?pageId=119315&revisedVersion=15&originalVersion=14">View
Changes</a>
                |
        <a href="https://cwiki.apache.org/confluence/display/CXF/DOSGi+Multi+Bundle+Distribution?showComments=true&amp;showCommentArea=true#addcomment">Add
Comment</a>
            </div>
</div>
</div>
</div>
</div>
</body>
</html>

Mime
View raw message