I am trying to build a custom distribution using Karaf 4.6.6 .  The "Minimal 
Distribution Example" described in 
https://karaf.apache.org/manual/latest/#_maven_assembly successfully builds, 
but adding a CXF feature dependency to pom.xml cause the build to fail due to a 
dependency resolution error.

Starting with a clean install of Karaf 4.4.6, I can add the cxf v3.6.2 
repository successfully. Installing the feature cxf-sts.

Why is the build failing?

***
* Build error
***
[WARNING] The POM for org.glassfish.jaxb:jaxb-runtime:jar:2.2.10-b140310.1920 
is invalid, transitive dependencies (if any) will not be available, enable 
debug logging for more details
[WARNING] The POM for org.glassfish.jaxb:jaxb-runtime:jar:2.2.10-b140802.1033 
is invalid, transitive dependencies (if any) will not be available, enable 
debug logging for more details
[WARNING] The POM for org.glassfish.jaxb:jaxb-runtime:jar:2.2.10 is invalid, 
transitive dependencies (if any) will not be available, enable debug logging 
for more details
[WARNING] The POM for org.glassfish.jaxb:jaxb-runtime:jar:2.2.11 is invalid, 
transitive dependencies (if any) will not be available, enable debug logging 
for more details
Downloading from netbeans: 
http://bits.netbeans.org/nexus/content/groups/netbeans/javax/xml/bind/jaxb-api/2.3.0-b161121.1438/jaxb-api-2.3.0-b161121.1438.pom
[WARNING] The POM for javax.xml.bind:jaxb-api:jar:2.3.0 is invalid, transitive 
dependencies (if any) will not be available, enable debug logging for more 
details
[WARNING] The POM for javax.xml.bind:jaxb-api:jar:2.3.1 is invalid, transitive 
dependencies (if any) will not be available, enable debug logging for more 
details
[WARNING] The POM for javax.xml.bind:jaxb-api:jar:2.4.0-b180725.0427 is 
invalid, transitive dependencies (if any) will not be available, enable debug 
logging for more details
Downloading from netbeans: 
http://bits.netbeans.org/nexus/content/groups/netbeans/com/sun/istack/istack-commons-runtime/3.0.6/istack-commons-runtime-3.0.6.pom
Downloading from netbeans: 
http://bits.netbeans.org/nexus/content/groups/netbeans/com/sun/xml/fastinfoset/FastInfoset/1.2.14/FastInfoset-1.2.14.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  2.434 s
[INFO] Finished at: 2024-07-19T14:09:01-04:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project ewm-karaf-base: Could not resolve 
dependencies for project 
com.intekon.customer.kc.ewm:ewm-karaf-base:karaf-assembly:3.0-SNAPSHOT: Failed 
to collect dependencies at org.apache.cxf.karaf:apache-cxf:xml:features:3.6.2 
-> org.apache.cxf.services.sts:cxf-services-sts-core:jar:3.6.2 -> 
org.apache.cxf:cxf-rt-ws-security:jar:3.6.2 -> org.ehcache:ehcache:jar:3.10.8 
-> org.glassfish.jaxb:jaxb-runtime:jar:2.3.0-b170127.1453 -> 
org.glassfish.jaxb:jaxb-core:jar:2.3.0-b170127.1453 -> 
javax.xml.bind:jaxb-api:jar:2.3.0-b161121.1438: Failed to read artifact 
descriptor for javax.xml.bind:jaxb-api:jar:2.3.0-b161121.1438: Could not 
transfer artifact javax.xml.bind:jaxb-api:pom:2.3.0-b161121.1438 from/to 
netbeans (http://bits.netbeans.org/nexus/content/groups/netbeans): 
authentication failed for 
http://bits.netbeans.org/nexus/content/groups/netbeans/javax/xml/bind/jaxb-api/2.3.0-b161121.1438/jaxb-api-2.3.0-b161121.1438.pom,
 status: 401 Repository decommissioned. Please refer to 
https://netbeans.apache.org/about/oracle-transition.html for more information. 
-> [Help 1]

***
* CXF Dependency
***
<dependency>
        <groupId>org.apache.cxf.karaf</groupId>
        <artifactId>apache-cxf</artifactId>
        <version>3.6.2</version>
        <type>xml</type>
        <classifier>features</classifier>
        <scope>runtime</scope>
</dependency>

***
* Log adding CXF repository and installing cxf-sts feature
***
paul@sparrow apache-karaf-4.4.6 % bin/karaf clean
        __ __                  ____      
       / //_/____ __________ _/ __/      
      / ,<  / __ `/ ___/ __ `/ /_        
     / /| |/ /_/ / /  / /_/ / __/        
    /_/ |_|\__,_/_/   \__,_/_/         

  Apache Karaf (4.4.6)

Hit '<tab>' for a list of available commands
and '[cmd] --help' for help on a specific command.
Hit '<ctrl-d>' or type 'system:shutdown' or 'logout' to shutdown Karaf.

karaf@root()> feature:repo-add 
mvn:org.apache.cxf.karaf/apache-cxf/3.6.2/xml/features
Adding feature url mvn:org.apache.cxf.karaf/apache-cxf/3.6.2/xml/features
karaf@root()> feature:install cxf-sts
karaf@root()> list
START LEVEL 100 , List Threshold: 50
ID │ State  │ Lvl │ Version │ Name
───┼────────┼─────┼─────────┼───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
33 │ Active │  80 │ 4.4.6   │ Apache Karaf :: OSGi Services :: Event
82 │ Active │  80 │ 3.6.2   │ Apache CXF STS Core
karaf@root()> list -t 0 -s | grep -i cxf                                        
                                                                                
                                                             
 67 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-core
 68 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-rt-bindings-soap
 69 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-rt-bindings-xml
 70 │ Active   │  40 │ 3.6.2              │ 
org.apache.cxf.cxf-rt-databinding-jaxb
 71 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-rt-management
 72 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-rt-rs-json-basic
 73 │ Active   │  40 │ 3.6.2              │ 
org.apache.cxf.cxf-rt-rs-security-jose
 74 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-rt-security
 75 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-rt-security-saml
 76 │ Active   │  40 │ 3.6.2              │ 
org.apache.cxf.cxf-rt-transports-http
 77 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-rt-ws-addr
 78 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-rt-ws-policy
 79 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-rt-ws-security
 80 │ Active   │  40 │ 3.6.2              │ org.apache.cxf.cxf-rt-wsdl
 81 │ Active   │  40 │ 3.6.2              │ 
org.apache.cxf.karaf.cxf-karaf-commands
 82 │ Active   │  80 │ 3.6.2              │ org.apache.cxf.services.sts.core
karaf@root()> list -t 0 -s | grep -i glass
karaf@root()> list -t 0 -s | grep -i jaxb
 70 │ Active   │  40 │ 3.6.2              │ 
org.apache.cxf.cxf-rt-databinding-jaxb
 90 │ Active   │  20 │ 2.3.2.1            │ 
org.apache.servicemix.bundles.jaxb-runtime
 91 │ Active   │  20 │ 2.3.2.1            │ 
org.apache.servicemix.bundles.jaxb-xjc
karaf@root()> 


Paul Spencer                                                                    
                                                                                
                                                              

Reply via email to