Re: Help interpreting error in "feature:install"

2017-09-28 Thread Guillaume Nodet
When I see
file:C:/Users//frameworks/apache-karaf-3.0.1/data/kar
@multihttp:///nexus/content/groups/digitalexp/http://<
nexushostport>/nexus/content/groups/digitalexp/
that makes me think you have some missing commas in your maven
configuration.
Could you check your etc/org.ops4j.pax.url.mvn.cfg file ?

2017-09-28 21:15 GMT+02:00 KARR, DAVID :

> After I determined that I have to run karaf 3.0.1 with Java 7, I'm now
> blocked trying to install a feature.  I'm having trouble fully
> understanding exactly what is wrong.
>
> I added the following lines to "bin/setenv.bat":
> ---
> set KARAF_OPTS=-Dhttp.useProxy=true -Dhttp.proxyHost=
> -Dhttp.proxyPort=8080
> set JAVA_MAX_MEM=3572M
> 
>
> After starting karaf, the instructions I have say to enter the following
> approximate commands:
> ---
> config:property-append -p  org.ops4j.pax.url.mvn 
> org.ops4j.pax.url.mvn.repositories
> http:///nexus/content/groups//
> feature:repo-add mvn://1.4.1-SNAPSHOT/xml/features
> feature:install -v -c -service
> -
>
> I've elided some of this with "<>" placeholders.
>
> When I run this, the last command fails with this:
> --
> Error executing command: Error resolving artifact
> :common-features:xml:features:1.1.0-SNAPSHOT: Could not transfer
> artifact :common-features:xml:features:1.1.0-SNAPSHOT from/to
> kar.repository (file:C:/Users//frameworks/apache-karaf-3.0.1/
> data/kar@multihttp:///nexus/content/
> groups/digitalexp/http:///nexus/content/groups/digitalexp/):
> Repository path C:\Users\\frameworks\apache-karaf-3.0.1\
> data\kar@multihttp:\\nexus\content\
> groups\\http:\\nexus\content\groups\does
> not exist, and cannot be created.
> --
>
> Now, I note that when I run my local build, it builds version
> "1.1.20-SNAPSHOT of the "common-features" artifact.  I looked on our nexus
> host, and the group does exist, and that artifact and version
> (1.1.0-SNAPSHOT) does appear to be present.
>
> I'm trying to understand at least what this error is actually complaining
> about, and perhaps that will lead to a solution.
>
>


-- 

Guillaume Nodet


Help interpreting error in "feature:install"

2017-09-28 Thread KARR, DAVID
After I determined that I have to run karaf 3.0.1 with Java 7, I'm now blocked 
trying to install a feature.  I'm having trouble fully understanding exactly 
what is wrong.

I added the following lines to "bin/setenv.bat":
---
set KARAF_OPTS=-Dhttp.useProxy=true -Dhttp.proxyHost= 
-Dhttp.proxyPort=8080
set JAVA_MAX_MEM=3572M


After starting karaf, the instructions I have say to enter the following 
approximate commands:
---
config:property-append -p  org.ops4j.pax.url.mvn 
org.ops4j.pax.url.mvn.repositories 
http:///nexus/content/groups//
feature:repo-add mvn://1.4.1-SNAPSHOT/xml/features
feature:install -v -c -service
-

I've elided some of this with "<>" placeholders.

When I run this, the last command fails with this:
--
Error executing command: Error resolving artifact 
:common-features:xml:features:1.1.0-SNAPSHOT: Could not transfer 
artifact :common-features:xml:features:1.1.0-SNAPSHOT from/to 
kar.repository 
(file:C:/Users//frameworks/apache-karaf-3.0.1/data/kar@multihttp:///nexus/content/groups/digitalexp/http:///nexus/content/groups/digitalexp/):
 Repository path 
C:\Users\\frameworks\apache-karaf-3.0.1\data\kar@multihttp:\\nexus\content\groups\\http:\\nexus\content\groups\does
 not exist, and cannot be created.
--

Now, I note that when I run my local build, it builds version "1.1.20-SNAPSHOT 
of the "common-features" artifact.  I looked on our nexus host, and the group 
does exist, and that artifact and version (1.1.0-SNAPSHOT) does appear to be 
present.

I'm trying to understand at least what this error is actually complaining 
about, and perhaps that will lead to a solution.



RE: karaf 3.0.1 just prints NullPointerException trying to append a property

2017-09-28 Thread KARR, DAVID
> -Original Message-
> From: Jean-Baptiste Onofré [mailto:j...@nanthrax.net]
> Sent: Wednesday, September 27, 2017 11:42 PM
> To: user@karaf.apache.org
> Subject: Re: karaf 3.0.1 just prints NullPointerException trying to
> append a property
> 
> Karaf 3.x works with Java8. Even Karaf 2.4.x also works with Java8.
> However, we fixed issues with Java8 starting from Karaf 3.0.4.
> 
> I just tested 3.0.7 on Java8 without problem.

Ok, well, I just tried making karaf use 1.7.0_131, and the problem no longer 
occurs.  I guess I'm going to move forward with that.

> Regards
> JB
> 
> On 09/28/2017 08:37 AM, Achim Nierbeck wrote:
> > Hi,
> >
> > afair 3.0.x was never "designed" to work with Java8.
> > The reason might have been the ASM stuff, so I wouldn't rely on that.
> >
> > If you want to use Karaf 3.0.x you'll need to stick to Java 7 I fear.
> >
> > regards, Achim
> >
> >
> > 2017-09-28 7:22 GMT+02:00 Jean-Baptiste Onofré  > >:
> >
> > Hi David,
> >
> > Something is wrong on 3.0.1 (at least with Java 8): all commands
> throw a
> > NullPointerException (even a simple bundle:list).
> >
> > After a quick look, it seems to be related to blueprint and aries
> proxy (and
> > asm).
> >
> > I'm checking and I will fix that.
> >
> > Regards
> > JB
> >
> >
> > On 09/28/2017 12:45 AM, KARR, DAVID wrote:
> >
> > I'm unfortunately forced to use Karaf 3.0.1 for some
> maintenance changes
> > I need to make, and I don't even regularly use karaf.
> >
> > The setup process requires entering some commands into karaf
> after it
> > starts up.  First there's a call to "config:property-append"
> with
> > certain parameters.  When I do this, or even just
> > "config:property-append --help", it just says "Error executing
> command:
> > java.lang.NullPointerException", with no other information.
> >
> > What might be wrong here, and what can I do to get more
> information?
> >
> > Assuming I get this working, is it practical to pipe a set of
> commands
> > into karaf, so it will enter them after it presents the
> command prompt?
> >
> >
> > --
> > Jean-Baptiste Onofré
> > jbono...@apache.org 
> > https://urldefense.proofpoint.com/v2/url?u=http-
> 3A__blog.nanthrax.net=DwIDaQ=LFYZ-o9_HUMeMTSQicvjIg=OsTemSXEn-
> xy2uk0vYF_EA=ieXUMpCKPGqdTfC74NxVMiUDjH9jViR7qlfHbpHE6ho=ZPDfCesGP6N
> emwU9Cfa65tyki0-793TbpiJBChW7U1I=
> > Talend -
> > https://urldefense.proofpoint.com/v2/url?u=http-3A__www.talend.com=D
> > wIDaQ=LFYZ-o9_HUMeMTSQicvjIg=OsTemSXEn-xy2uk0vYF_EA=ieXUMpCKPGqd
> > TfC74NxVMiUDjH9jViR7qlfHbpHE6ho=u4d95VbGZN8EtDp7zKNBs-4Sl-kZSNb8zdCb
> > nTM7i1I=
> >
> >
> >
> >
> > --
> >
> > Apache Member
> > Apache Karaf
> >  > =DwIDaQ=LFYZ-o9_HUMeMTSQicvjIg=OsTemSXEn-xy2uk0vYF_EA=ieXUMpCK
> > PGqdTfC74NxVMiUDjH9jViR7qlfHbpHE6ho=_sxjMqQX23TPC66IvJIRdcVDr-qShQzh
> > -LVXKELe1-w= > Committer & PMC OPS4J Pax Web
> >  > splay_paxweb_Pax-2BWeb_=DwIDaQ=LFYZ-o9_HUMeMTSQicvjIg=OsTemSXEn-
> > xy2uk0vYF_EA=ieXUMpCKPGqdTfC74NxVMiUDjH9jViR7qlfHbpHE6ho=vnWVVqyS9
> > IILoEJlkpmqDOtgjwgB_h1Bi8iWWZitiGY= > Committer & Project Lead blog
> >  > k.de_=DwIDaQ=LFYZ-o9_HUMeMTSQicvjIg=OsTemSXEn-xy2uk0vYF_EA=ieX
> > UMpCKPGqdTfC74NxVMiUDjH9jViR7qlfHbpHE6ho=-LJoQVoz-mB8Sdcw4KM-9IL3Nl0
> > GXywagNK3733Z7ow= > Co-Author of Apache Karaf Cookbook
> >  > DwIDaQ=LFYZ-o9_HUMeMTSQicvjIg=OsTemSXEn-xy2uk0vYF_EA=ieXUMpCKPGq
> > dTfC74NxVMiUDjH9jViR7qlfHbpHE6ho=BqTDlbhLQvFhq0xwyLHSM1fjio5niwfU0yc
> > -nhIX7xc= >
> >
> > Software Architect / Project Manager / Scrum Master
> >
> 
> --
> Jean-Baptiste Onofré
> jbono...@apache.org
> https://urldefense.proofpoint.com/v2/url?u=http-
> 3A__blog.nanthrax.net=DwIDaQ=LFYZ-o9_HUMeMTSQicvjIg=OsTemSXEn-
> xy2uk0vYF_EA=ieXUMpCKPGqdTfC74NxVMiUDjH9jViR7qlfHbpHE6ho=ZPDfCesGP6N
> emwU9Cfa65tyki0-793TbpiJBChW7U1I=
> Talend - https://urldefense.proofpoint.com/v2/url?u=http-
> 3A__www.talend.com=DwIDaQ=LFYZ-o9_HUMeMTSQicvjIg=OsTemSXEn-
> xy2uk0vYF_EA=ieXUMpCKPGqdTfC74NxVMiUDjH9jViR7qlfHbpHE6ho=u4d95VbGZN8
> EtDp7zKNBs-4Sl-kZSNb8zdCbnTM7i1I=


Get "Too may authentication failures" connecting to local karaf 3.0.1 instance

2017-09-28 Thread KARR, DAVID
I have to make some changes to some old legacy code, which uses Karaf 3.0.1.  I 
have some issues configuring it, which I'm covering in other threads, but I'm 
also having trouble connecting to the local instance using ssh.

When I start it with just "bin/karaf" from a Windows cmd shell, and then "ssh 
-p8101 karaf@localhost" (after configuring ~/.ssh/config with some obsolete ssh 
algorithms that karaf 3.0.1 is using), I get this output:


Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Authenticated with partial success.
Received disconnect from 127.0.0.1 port 8101:2: Too may authentication failures
Connection to localhost closed by remote host.
Connection to localhost closed.
--

Yes, the "may" in the title was not a typo (not mine, at least).  Any idea what 
might be going on here?


RE: karaf 3.0.1 just prints NullPointerException trying to append a property

2017-09-28 Thread KARR, DAVID


> -Original Message-
> From: KARR, DAVID
> Sent: Wednesday, September 27, 2017 3:46 PM
> To: user@karaf.apache.org
> Subject: karaf 3.0.1 just prints NullPointerException trying to append a
> property
> 
> I'm unfortunately forced to use Karaf 3.0.1 for some maintenance changes
> I need to make, and I don't even regularly use karaf.
> 
> The setup process requires entering some commands into karaf after it
> starts up.  First there's a call to "config:property-append" with
> certain parameters.  When I do this, or even just "config:property-
> append --help", it just says "Error executing command:
> java.lang.NullPointerException", with no other information.
> 
> What might be wrong here, and what can I do to get more information?
> 
> Assuming I get this working, is it practical to pipe a set of commands
> into karaf, so it will enter them after it presents the command prompt?

I realized that although the console doesn't tell me much, the log file would 
tell me more.

I found the NPE in the log, and there was also another exception before it.  
Here's an excerpt that includes both:
--
java.lang.IllegalArgumentException
at org.objectweb.asm.ClassReader.(Unknown Source)
at org.objectweb.asm.ClassReader.(Unknown Source)
at org.objectweb.asm.ClassReader.(Unknown Source)
at 
org.apache.aries.proxy.impl.gen.ProxySubclassAdapter.visit(ProxySubclassAdapter.java:274)
at org.objectweb.asm.ClassReader.accept(Unknown Source)
at org.objectweb.asm.ClassReader.accept(Unknown Source)
at 
org.apache.aries.proxy.impl.gen.ProxySubclassGenerator.processClass(ProxySubclassGenerator.java:245)
at 
org.apache.aries.proxy.impl.gen.ProxySubclassGenerator.generateAndLoadSubclass(ProxySubclassGenerator.java:224)
at 
org.apache.aries.proxy.impl.gen.ProxySubclassGenerator.getProxySubclass(ProxySubclassGenerator.java:126)
at 
org.apache.aries.proxy.impl.gen.ProxySubclassGenerator.newProxySubclassInstance(ProxySubclassGenerator.java:161)
at 
org.apache.aries.proxy.impl.AsmProxyManager.createNewProxy(AsmProxyManager.java:103)
at 
org.apache.aries.proxy.impl.AbstractProxyManager.createDelegatingInterceptingProxy(AbstractProxyManager.java:75)
at 
org.apache.aries.proxy.impl.AbstractProxyManager.createInterceptingProxy(AbstractProxyManager.java:53)
at 
org.apache.aries.blueprint.container.ServiceRecipe$TriggerServiceFactory.getService(ServiceRecipe.java:535)
at 
org.apache.felix.framework.ServiceRegistrationImpl.getFactoryUnchecked(ServiceRegistrationImpl.java:308)
at 
org.apache.felix.framework.ServiceRegistrationImpl.getService(ServiceRegistrationImpl.java:219)
at 
org.apache.felix.framework.ServiceRegistry.getService(ServiceRegistry.java:320)
at org.apache.felix.framework.Felix.getService(Felix.java:3568)
at 
org.apache.felix.framework.BundleContextImpl.getService(BundleContextImpl.java:468)
at 
org.apache.karaf.service.guard.impl.GuardProxyCatalog$ProxyServiceFactory.getService(GuardProxyCatalog.java:424)
at 
org.apache.felix.framework.ServiceRegistrationImpl.getFactoryUnchecked(ServiceRegistrationImpl.java:308)
at 
org.apache.felix.framework.ServiceRegistrationImpl.getService(ServiceRegistrationImpl.java:219)
at 
org.apache.felix.framework.ServiceRegistry.getService(ServiceRegistry.java:320)
at org.apache.felix.framework.Felix.getService(Felix.java:3568)
at 
org.apache.felix.framework.BundleContextImpl.getService(BundleContextImpl.java:468)
at 
org.apache.karaf.shell.console.completer.CommandsCompleter.unProxy(CommandsCompleter.java:298)
at 
org.apache.karaf.shell.console.completer.CommandsCompleter.checkData(CommandsCompleter.java:234)
at 
org.apache.karaf.shell.console.completer.CommandsCompleter.complete(CommandsCompleter.java:86)
at 
org.apache.karaf.shell.console.impl.jline.CompleterAsCompletor.complete(CompleterAsCompletor.java:32)
at 
jline.console.ConsoleReader.complete(ConsoleReader.java:3077)[26:jline:2.11.0]
at 
jline.console.ConsoleReader.readLine(ConsoleReader.java:2501)[26:jline:2.11.0]
at 
jline.console.ConsoleReader.readLine(ConsoleReader.java:2162)[26:jline:2.11.0]
at 
org.apache.karaf.shell.console.impl.jline.ConsoleImpl.readAndParseCommand(ConsoleImpl.java:280)[37:org.apache.karaf.shell.console:3.0.1]
at 
org.apache.karaf.shell.console.impl.jline.ConsoleImpl.run(ConsoleImpl.java:207)[37:org.apache.karaf.shell.console:3.0.1]
at java.lang.Thread.run(Thread.java:745)[:1.8.0_102]
at 
org.apache.karaf.shell.console.impl.jline.ConsoleFactoryService$3.doRun(ConsoleFactoryService.java:126)[37:org.apache.karaf.shell.console:3.0.1]
at 
org.apache.karaf.shell.console.impl.jline.ConsoleFactoryService$3$1.run(ConsoleFactoryService.java:117)
at java.security.AccessController.doPrivileged(Native 

Re: karaf 3.0.1 just prints NullPointerException trying to append a property

2017-09-28 Thread Jean-Baptiste Onofré
Karaf 3.x works with Java8. Even Karaf 2.4.x also works with Java8. However, we 
fixed issues with Java8 starting from Karaf 3.0.4.


I just tested 3.0.7 on Java8 without problem.

Regards
JB

On 09/28/2017 08:37 AM, Achim Nierbeck wrote:

Hi,

afair 3.0.x was never "designed" to work with Java8.
The reason might have been the ASM stuff, so I wouldn't rely on that.

If you want to use Karaf 3.0.x you'll need to stick to Java 7 I fear.

regards, Achim


2017-09-28 7:22 GMT+02:00 Jean-Baptiste Onofré >:


Hi David,

Something is wrong on 3.0.1 (at least with Java 8): all commands throw a
NullPointerException (even a simple bundle:list).

After a quick look, it seems to be related to blueprint and aries proxy (and
asm).

I'm checking and I will fix that.

Regards
JB


On 09/28/2017 12:45 AM, KARR, DAVID wrote:

I'm unfortunately forced to use Karaf 3.0.1 for some maintenance changes
I need to make, and I don't even regularly use karaf.

The setup process requires entering some commands into karaf after it
starts up.  First there's a call to "config:property-append" with
certain parameters.  When I do this, or even just
"config:property-append --help", it just says "Error executing command:
java.lang.NullPointerException", with no other information.

What might be wrong here, and what can I do to get more information?

Assuming I get this working, is it practical to pipe a set of commands
into karaf, so it will enter them after it presents the command prompt?


-- 
Jean-Baptiste Onofré

jbono...@apache.org 
http://blog.nanthrax.net
Talend - http://www.talend.com




--

Apache Member
Apache Karaf  Committer & PMC
OPS4J Pax Web  Committer & 
Project Lead

blog 
Co-Author of Apache Karaf Cookbook 

Software Architect / Project Manager / Scrum Master



--
Jean-Baptiste Onofré
jbono...@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com


Re: karaf 3.0.1 just prints NullPointerException trying to append a property

2017-09-28 Thread Achim Nierbeck
Hi,

afair 3.0.x was never "designed" to work with Java8.
The reason might have been the ASM stuff, so I wouldn't rely on that.

If you want to use Karaf 3.0.x you'll need to stick to Java 7 I fear.

regards, Achim


2017-09-28 7:22 GMT+02:00 Jean-Baptiste Onofré :

> Hi David,
>
> Something is wrong on 3.0.1 (at least with Java 8): all commands throw a
> NullPointerException (even a simple bundle:list).
>
> After a quick look, it seems to be related to blueprint and aries proxy
> (and asm).
>
> I'm checking and I will fix that.
>
> Regards
> JB
>
>
> On 09/28/2017 12:45 AM, KARR, DAVID wrote:
>
>> I'm unfortunately forced to use Karaf 3.0.1 for some maintenance changes
>> I need to make, and I don't even regularly use karaf.
>>
>> The setup process requires entering some commands into karaf after it
>> starts up.  First there's a call to "config:property-append" with certain
>> parameters.  When I do this, or even just "config:property-append --help",
>> it just says "Error executing command: java.lang.NullPointerException",
>> with no other information.
>>
>> What might be wrong here, and what can I do to get more information?
>>
>> Assuming I get this working, is it practical to pipe a set of commands
>> into karaf, so it will enter them after it presents the command prompt?
>>
>>
> --
> Jean-Baptiste Onofré
> jbono...@apache.org
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>



-- 

Apache Member
Apache Karaf  Committer & PMC
OPS4J Pax Web  Committer &
Project Lead
blog 
Co-Author of Apache Karaf Cookbook 

Software Architect / Project Manager / Scrum Master