Yes, I copied the scan-bundle lines into our composite files keeping the
startlevel. The only difference is that the cxf (cxf.dosgi.multibundle)
does not call spring.dm directly via scan-composite but that this is
done via central composite.
 
Our composite structure is like
 
configuration.composite:
# --------------- Jetty -----------------------------------
scan-composite:mvn:com.lhsystems.gsp.core.configuration/jetty/1.0.0/comp
osite
 
# --------------- Common Dependencies ---------------------
scan-bundle:mvn:javax.jws/com.springsource.javax.jws/2.0.0
 
# --------------- Spring Framework ------------------
scan-composite:mvn:com.lhsystems.gsp.core.configuration/spring/1.0.0/com
posite
 
# --------------- Spring DM -------------------------------
scan-composite:mvn:com.lhsystems.gsp.core.configuration/spring-dm/1.0.0/
composite
 
# --------------- Log -------------------------------------
scan-composite:mvn:com.lhsystems.gsp.core.configuration/pax-log/1.0.0/co
mposite
 
# --------------- Pax Web (required by CXF) ---------------
scan-composite:mvn:com.lhsystems.gsp.core.configuration/pax-web/1.0.0/co
mposite
 
# --------------- CXF Integration -------------------------------------
scan-composite:mvn:com.lhsystems.gsp.core.configuration/cxf-integration/
1.0.0/composite
 
# --------------- CXF -------------------------------------
scan-composite:mvn:com.lhsystems.gsp.core.configuration/cxf/1.0.0/compos
ite
 
but does not assign startlevel to Spring DM composite file. Inside
Spring DM the content is identical to spring.dm profile composite file.
 
Michael

________________________________

Von: [email protected]
[mailto:[email protected]] Im Auftrag von Alin Dreghiciu
Gesendet: Mittwoch, 2. September 2009 13:57
An: General OPS4J
Betreff: Re: CXF issue with Pax Runner using own composites


I recall that cxf ro spring dm had some problems related to start level.
That is why you see all the @ appended at the end of the bundles (in
profile). Did you use them also?


On Wed, Sep 2, 2009 at 2:31 PM, <[email protected]> wrote:


        Hi,
         
        my goal is to provide an enriched OSGi container with spring,
spring-dm and webservice support (using cxf.dosgi.multibundle). The
result will be a common platform for a number of applications we want to
build running in a server environment.
         
        We used Pax-Construct to create the platform structure and
initially added the profiles (spring.dm, cxf.dosgi.multibundle, ...).
With this environment a test webservice app runs correctly. Since we
need stability in our environment we analysed the composites used within
the profiles and rebuild the structure within our environment using 
         
        
<param>scan-composite:mvn:com.lhsystems.gsp.core/configuration/1.0.0/com
posite</param> for pax runner. Unfortunately now the container throws
the following exception upon start (mvn pax:provision) and the
webservice app cannot be run, because application context cannot be
initialized.
         
        The exception is:
        osgi>
[org.springframework.osgi.context.support.OsgiBundleXmlApplicationContex
t] : Refresh error
        
org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException:
Line 33 in XML document from OSGi
resource[classpath:/OSGI-INF/cxf/intents/intent-map.xml|bnd.id=39|bnd.sy
m=cxf-dosgi-ri-dsw-cxf]
         is invalid; nested exception is org.xml.sax.SAXParseException:
cvc-elt.1: Cannot find the declaration of element 'beans'.
                at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBean
Definitions(XmlBeanDefinitionReader.java:404)
                at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDe
finitions(XmlBeanDefinitionReader.java:342)
                at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDe
finitions(XmlBeanDefinitionReader.java:310)
                at
org.springframework.beans.factory.support.AbstractBeanDefinitionReader.l
oadBeanDefinitions(AbstractBeanDefinitionReader.java:143)
                at
org.springframework.beans.factory.support.AbstractBeanDefinitionReader.l
oadBeanDefinitions(AbstractBeanDefinitionReader.java:178)
                at
org.springframework.beans.factory.support.AbstractBeanDefinitionReader.l
oadBeanDefinitions(AbstractBeanDefinitionReader.java:149)
                at
org.springframework.osgi.context.support.OsgiBundleXmlApplicationContext
.loadBeanDefinitions(OsgiBundleXmlApplicationContext.java:176)
                at
org.springframework.osgi.context.support.OsgiBundleXmlApplicationContext
.loadBeanDefinitions(OsgiBundleXmlApplicationContext.java:142)
                at
org.springframework.context.support.AbstractRefreshableApplicationContex
t.refreshBeanFactory(AbstractRefreshableApplicationContext.java:123)
                at
org.springframework.context.support.AbstractApplicationContext.obtainFre
shBeanFactory(AbstractApplicationContext.java:422)
                at
org.springframework.context.support.AbstractApplicationContext.refresh(A
bstractApplicationContext.java:352)
                at
org.springframework.osgi.context.support.AbstractDelegatedExecutionAppli
cationContext.access$301(AbstractDelegatedExecutionApplicationContext.ja
va:69)
                at
org.springframework.osgi.context.support.AbstractDelegatedExecutionAppli
cationContext$1.run(AbstractDelegatedExecutionApplicationContext.java:18
6)
                at
org.springframework.osgi.util.internal.PrivilegedUtils.executeWithCustom
TCCL(PrivilegedUtils.java:85)
                at
org.springframework.osgi.context.support.AbstractDelegatedExecutionAppli
cationContext.normalRefresh(AbstractDelegatedExecutionApplicationContext
.java:182)
                at
org.springframework.osgi.context.support.AbstractDelegatedExecutionAppli
cationContext$NoDependenciesWaitRefreshExecutor.refresh(AbstractDelegate
dExecutionApplicationContext.java:89)
                at
org.springframework.osgi.context.support.AbstractDelegatedExecutionAppli
cationContext.refresh(AbstractDelegatedExecutionApplicationContext.java:
175)
                at
org.apache.cxf.dosgi.dsw.OsgiUtils.readIntentMap(OsgiUtils.java:420)
                at
org.apache.cxf.dosgi.dsw.OsgiUtils.getIntentMap(OsgiUtils.java:395)
                at
org.apache.cxf.dosgi.dsw.Activator.getIntentMap(Activator.java:109)
                at
org.apache.cxf.dosgi.dsw.Activator.registerDistributionProviderService(A
ctivator.java:92)
                at
org.apache.cxf.dosgi.dsw.Activator.start(Activator.java:74)
                at
org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleC
ontextImpl.java:782)
                at java.security.AccessController.doPrivileged(Native
Method)
                at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivato
r(BundleContextImpl.java:773)
                at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleC
ontextImpl.java:754)
                at
org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHo
st.java:352)
                at
org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractB
undle.java:370)
                at
org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framewor
k.java:1068)
                at
org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles
(StartLevelManager.java:557)
                at
org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(Start
LevelManager.java:464)
                at
org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLev
el(StartLevelManager.java:248)
                at
org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent
(StartLevelManager.java:445)
                at
org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventMana
ger.java:220)
                at
org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventMa
nager.java:330)
        Caused by: org.xml.sax.SAXParseException: cvc-elt.1: Cannot find
the declaration of element 'beans'.
                at
com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXPar
seException(ErrorHandlerWrapper.java:236)
                at
com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error(ErrorH
andlerWrapper.java:172)
                at
com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XML
ErrorReporter.java:382)
                at
com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XML
ErrorReporter.java:316)
                at
com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.handleStar
tElement(XMLSchemaValidator.java:1944)
                at
com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.startEleme
nt(XMLSchemaValidator.java:705)
                at
com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanSta
rtElement(XMLNSDocumentScannerImpl.java:330)
                at
com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl$NSConte
ntDispatcher.scanRootElementHook(XMLNSDocumentScannerImpl.java:779)
                at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$F
ragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:17
94)
                at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.s
canDocument(XMLDocumentFragmentScannerImpl.java:368)
                at
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML1
1Configuration.java:834)
                at
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML1
1Configuration.java:764)
                at
com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.jav
a:148)
                at
com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.jav
a:250)
                at
com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(Docume
ntBuilderImpl.java:292)
                at
org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument
(DefaultDocumentLoader.java:75)26.08.2009 16:09:56
org.apache.cxf.dosgi.dsw.OsgiUtils readIntentMap
        
         
        This are the bundles started with profile, where the example is
running:
         
        Framework is launched.
         
        id      State       Bundle
        0       ACTIVE      org.eclipse.osgi_3.5.0.v20090520
        1       ACTIVE      org.eclipse.osgi.util_3.2.0.v20090520-1800
        2       ACTIVE
org.eclipse.osgi.services_3.2.0.v20090520-1800
        3       ACTIVE      com.springsource.javax.jws_2.0.0
        4       ACTIVE      org.springframework.web_2.5.6
        5       ACTIVE      org.springframework.osgi.web_1.2.0
        6       ACTIVE      org.springframework.osgi.web.extender_1.2.0
                            Fragments=9
        7       ACTIVE
org.springframework.osgi.servlet-api.osgi_2.5.0.SNAPSHOT
        8       ACTIVE
org.springframework.osgi.jetty.start.osgi_1.0.0
                            Fragments=11
        9       RESOLVED
org.springframework.osgi.jetty.web.extender.fragment.osgi_1.0.1
                            Master=6
        10      ACTIVE
org.springframework.osgi.cglib-nodep.osgi_2.1.3.SNAPSHOT
        11      RESOLVED    jetty-config_1.0.0
                            Master=8
        12      ACTIVE
org.apache.geronimo.specs.geronimo-annotation_1.0_spec_1.1.1
        13      ACTIVE
org.apache.geronimo.specs.geronimo-activation_1.1_spec_1.0.2
        14      ACTIVE
org.apache.geronimo.specs.geronimo-javamail_1.4_spec_1.2.0
        15      ACTIVE
org.apache.geronimo.specs.geronimo-ws-metadata_2.0_spec_1.1.2
        16      ACTIVE      com.springsource.org.jdom_1.0.0
        17      ACTIVE      org.ops4j.pax.logging.pax-logging-api_1.4.0
        18      ACTIVE
org.ops4j.pax.logging.pax-logging-service_1.4.0
        19      ACTIVE      org.ops4j.pax.web.pax-web-service_0.6.0
        20      ACTIVE      com.springsource.org.aopalliance_1.0.0
        21      ACTIVE      org.springframework.aop_2.5.6
        22      ACTIVE      org.springframework.beans_2.5.6
        23      ACTIVE      org.springframework.context_2.5.6
        24      ACTIVE      org.springframework.context.support_2.5.6
        25      ACTIVE      org.springframework.core_2.5.6
        26      ACTIVE      com.springsource.org.objectweb.asm_2.2.3
        27      ACTIVE
com.springsource.edu.emory.mathcs.backport_3.1.0
        28      ACTIVE      com.springsource.net.sf.cglib_2.1.3
        29      ACTIVE
org.springframework.osgi.extensions.annotations_1.2.0
        30      ACTIVE      org.springframework.osgi.core_1.2.0
        31      ACTIVE      org.springframework.osgi.extender_1.2.0
        32      ACTIVE      org.springframework.osgi.io_1.2.0
        33      ACTIVE
org.apache.servicemix.bundles.jaxb-impl_2.1.6.1
        34      ACTIVE      org.apache.servicemix.bundles.wsdl4j_1.6.1.1
        35      ACTIVE      org.apache.servicemix.bundles.xmlsec_1.3.0.1
        36      ACTIVE      org.apache.servicemix.bundles.wss4j_1.5.4.1
        37      ACTIVE      org.apache.ws.commons.schema.XmlSchema_1.4.5
        38      ACTIVE      org.apache.servicemix.bundles.asm_2.2.3.1
        39      ACTIVE
org.apache.servicemix.bundles.xmlresolver_1.2.0.1
        40      ACTIVE      org.apache.servicemix.bundles.neethi_2.0.4.1
        41      ACTIVE
org.apache.servicemix.bundles.woodstox_3.2.7.1
        42      ACTIVE
org.apache.servicemix.specs.saaj-api-1.3_1.1.1
        43      ACTIVE
org.apache.servicemix.specs.stax-api-1.0_1.1.1
        44      ACTIVE
org.apache.servicemix.specs.jaxb-api-2.1_1.1.1
        45      ACTIVE
org.apache.servicemix.specs.jaxws-api-2.1_1.1.1
        46      ACTIVE      org.apache.cxf.bundle-minimal_2.3.0.SNAPSHOT
        47      ACTIVE      cxf-dosgi-ri-discovery-local_1.1.0.SNAPSHOT
        48      ACTIVE      cxf-dosgi-ri-dsw-cxf_1.1.0.SNAPSHOT
         
        This are the bundles, using own composites derived from profile
cxf.dosgi.multibundle
         
        Framework is launched.
         
        id      State       Bundle
        0       ACTIVE      org.eclipse.osgi_3.5.0.v20090520
        1       ACTIVE      org.eclipse.osgi.util_3.2.0.v20090520-1800
        2       ACTIVE
org.eclipse.osgi.services_3.2.0.v20090520-1800
        3       ACTIVE      com.springsource.javax.jws_2.0.0
        4       ACTIVE      com.springsource.org.aopalliance_1.0.0
        5       ACTIVE      org.springframework.aop_2.5.6.SEC01
        6       ACTIVE      org.springframework.beans_2.5.6.SEC01
        7       ACTIVE      org.springframework.context_2.5.6.SEC01
        8       ACTIVE
org.springframework.context.support_2.5.6.SEC01
        9       ACTIVE      org.springframework.core_2.5.6.SEC01
        10      ACTIVE      com.springsource.org.objectweb.asm_2.2.3
        11      ACTIVE
com.springsource.edu.emory.mathcs.backport_3.1.0
        12      ACTIVE      com.springsource.net.sf.cglib_2.1.3
        13      ACTIVE
org.springframework.osgi.extensions.annotations_1.2.0
        14      ACTIVE      org.springframework.osgi.core_1.2.0
        15      ACTIVE      org.springframework.osgi.extender_1.2.0
        16      ACTIVE      org.springframework.osgi.io_1.2.0
        17      ACTIVE
org.springframework.osgi.jetty.start.osgi_1.0.0
                            Fragments=48
        18      RESOLVED
org.springframework.osgi.jetty.web.extender.fragment.osgi_1.0.1
                            Master=25
        19      ACTIVE
org.springframework.osgi.cglib-nodep.osgi_2.1.3.SNAPSHOT
        20      ACTIVE      org.ops4j.pax.logging.pax-logging-api_1.3.0
        21      ACTIVE
org.ops4j.pax.logging.pax-logging-service_1.3.0
        22      ACTIVE      org.ops4j.pax.web.pax-web-service_0.6.0
        23      ACTIVE      org.springframework.web_2.5.6
        24      ACTIVE      org.springframework.osgi.web_1.2.0
        25      ACTIVE      org.springframework.osgi.web.extender_1.2.0
                            Fragments=18
        26      ACTIVE
org.springframework.osgi.servlet-api.osgi_2.5.0.SNAPSHOT
        27      ACTIVE
org.apache.geronimo.specs.geronimo-annotation_1.0_spec_1.1.1
        28      ACTIVE
org.apache.geronimo.specs.geronimo-activation_1.1_spec_1.0.2
        29      ACTIVE
org.apache.geronimo.specs.geronimo-javamail_1.4_spec_1.2.0
        30      ACTIVE
org.apache.geronimo.specs.geronimo-ws-metadata_2.0_spec_1.1.2
        31      ACTIVE      com.springsource.org.jdom_1.0.0
        32      ACTIVE
org.apache.servicemix.bundles.jaxb-impl_2.1.6.1
        33      ACTIVE      org.apache.servicemix.bundles.wsdl4j_1.6.1.1
        34      ACTIVE      org.apache.servicemix.bundles.xmlsec_1.3.0.1
        35      ACTIVE      org.apache.servicemix.bundles.wss4j_1.5.4.1
        36      ACTIVE      org.apache.ws.commons.schema.XmlSchema_1.4.5
        37      ACTIVE      org.apache.servicemix.bundles.asm_2.2.3.1
        38      ACTIVE
org.apache.servicemix.bundles.xmlresolver_1.2.0.1
        39      ACTIVE      org.apache.servicemix.bundles.neethi_2.0.4.1
        40      ACTIVE
org.apache.servicemix.bundles.woodstox_3.2.7.1
        41      ACTIVE
org.apache.servicemix.specs.saaj-api-1.3_1.1.1
        42      ACTIVE
org.apache.servicemix.specs.stax-api-1.0_1.1.1
        43      ACTIVE
org.apache.servicemix.specs.jaxb-api-2.1_1.1.1
        44      ACTIVE
org.apache.servicemix.specs.jaxws-api-2.1_1.1.1
        45      ACTIVE      org.apache.cxf.bundle-minimal_2.3.0.SNAPSHOT
        46      ACTIVE      cxf-dosgi-ri-discovery-local_1.1.0.SNAPSHOT
        47      ACTIVE      cxf-dosgi-ri-dsw-cxf_1.1.0.SNAPSHOT
        48      RESOLVED    jetty-config_1.0.0
                            Master=17
         
        This seems to be a timing issue and I can't seem to find the
difference, having played around with the scan-bundle entries in our
composite.
         
        Any help would be very appreciated.
         
        Thanks,
        Michael
         
         
         
         

        

        

        Sitz der Gesellschaft / Corporate Headquarters: Lufthansa
Systems Passenger Services GmbH, Kelsterbach, Registereintragung /
Registration: Amtsgericht Darmstadt 83854
        Geschaeftsfuehrung / Management Board: Dr. Anselm Eggert
         

        

        


        _______________________________________________
        general mailing list
        [email protected]
        http://lists.ops4j.org/mailman/listinfo/general
        
        




-- 
Alin Dreghiciu
Software Developer
My profile: http://www.linkedin.com/in/alindreghiciu
My blog: http://adreghiciu.blogspot.com
http://www.ops4j.org - New Energy for OSS Communities - Open
Participation Software.
http://www.qi4j.org - New Energy for Java - Domain Driven Development.


 
Sitz der Gesellschaft / Corporate Headquarters: Lufthansa Systems Passenger 
Services GmbH, Kelsterbach, Registereintragung / Registration: Amtsgericht 
Darmstadt 83854
Geschaeftsfuehrung / Management Board: Dr. Anselm Eggert
 

_______________________________________________
general mailing list
[email protected]
http://lists.ops4j.org/mailman/listinfo/general

Reply via email to