karaf-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Leangen <apa...@leangen.net>
Subject Re: Problem using drop-in deploy feature
Date Mon, 03 Jul 2017 20:08:46 GMT

Hi JB,

I tried prefixing with “xml:”, but that did not help.

Could it be that the “user:pass@“ part of the URL is being ignored?

Today, I will try to step through the code to see what is happening.


Cheers,
=David


> On Jul 3, 2017, at 8:35 PM, Jean-Baptiste Onofré <jb@nanthrax.net> wrote:
> 
> The resource repository has to be prefixed by json or xml in the URL.
> 
> Let me find an example.
> 
> Regards
> JB
> 
> On 07/03/2017 12:14 PM, David Leangen wrote:
>> Hi!
>> I am trying to follow Guillaume’s advice from this thread:
>>     http://karaf.922171.n3.nabble.com/Karaf-Feature-vs-OBR-tp4050720p4050762.html
>> I added a file to the deploy directory with this format:
>> <features xmlns="http://karaf.apache.org/xmlns/features/v1.4.0">
>>     <resource-repository>[url to the OBR repo]</resource-repository>
>>     <feature name="[feature name]" install="auto">
>>         <requirement>[the requirement]</requirement>
>>     </feature>
>> </features>
>> However, I keep getting a 401 from the repository server for the resource-repository.
>> When I curl using exactly the same URL, I get the contents of the OBR index file
with no problem whatsoever.
>> Any idea what this may be so? I see nothing in the logs other than this (URL edited):
>>> 2017-07-03T04:56:09,062 | ERROR | FelixDispatchQueue | FeatureDeploymentListener
       | 24 - org.apache.karaf.deployer.features - 4.1.1 | Unable to install features
>>> java.lang.RuntimeException: java.io.IOException: Unexpected http response loading
https://user:pass@example.com/obr/index.xml : 401 Unauthorized
>>> 	at org.apache.karaf.features.internal.repository.UrlLoader.checkAndLoadCache(UrlLoader.java:101)
~[?:?]
>>> 	at org.apache.karaf.features.internal.repository.XmlRepository.checkAndLoadReferrals(XmlRepository.java:156)
~[?:?]
>>> 	at org.apache.karaf.features.internal.repository.XmlRepository.checkAndLoadCache(XmlRepository.java:118)
~[?:?]
>>> 	at org.apache.karaf.features.internal.repository.XmlRepository.getResources(XmlRepository.java:62)
~[?:?]
>>> 	at org.apache.karaf.features.internal.region.Subsystem.downloadBundles(Subsystem.java:482)
~[?:?]
>>> 	at org.apache.karaf.features.internal.region.Subsystem.downloadBundles(Subsystem.java:372)
~[?:?]
>>> 	at org.apache.karaf.features.internal.region.SubsystemResolver.resolve(SubsystemResolver.java:187)
~[?:?]
>>> 	at org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:285)
~[?:?]
>>> 	at org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1170)
~[?:?]
>>> 	at org.apache.karaf.features.internal.service.FeaturesServiceImpl.lambda$doProvisionInThread$0(FeaturesServiceImpl.java:1069)
~[?:?]
>>> 	at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:?]
>>> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
[?:?]
>>> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
[?:?]
>>> 	at java.lang.Thread.run(Thread.java:748) [?:?]
>>> Caused by: java.io.IOException: Unexpected http response loading https://user:pass@example.com/obr/index.xml
: 401 Unauthorized
>>> 	at org.apache.karaf.features.internal.repository.UrlLoader.checkAndLoadCache(UrlLoader.java:71)
~[?:?]
>>> 	... 13 more
>> Cheers,
>> =David
> 
> -- 
> Jean-Baptiste Onofré
> jbonofre@apache.org
> http://blog.nanthrax.net
> Talend - http://www.talend.com


Mime
View raw message