You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@karaf.apache.org by "Donnie McMahan (Jira)" <ji...@apache.org> on 2020/01/06 16:47:00 UTC

[jira] [Comment Edited] (KARAF-6536) StackOverflowError in karaf-maven-plugin:verify when referencing feature which uses version ranges

    [ https://issues.apache.org/jira/browse/KARAF-6536?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17008982#comment-17008982 ] 

Donnie McMahan edited comment on KARAF-6536 at 1/6/20 4:46 PM:
---------------------------------------------------------------

Interestingly, this does seem to work in WSL (Ubuntu). I've tried to match my Windows environment as closely as possible (JDK 11.0.5, Maven 3.6.0, empty Maven local repo) without any luck.

I'll keep trying to work out any differences between the environments.

Edit: [~jbonofre] sorry, I just now saw your comment. I had been using Windows but just tried WSL on a whim.


was (Author: mcmahan):
Interestingly, this does seem to work in WSL (Ubuntu). I've tried to match my Windows environment as closely as possible (JDK 11.0.5, Maven 3.6.0, empty Maven local repo) without any luck.

I'll keep trying to work out any differences between the environments.

> StackOverflowError in karaf-maven-plugin:verify when referencing feature which uses version ranges
> --------------------------------------------------------------------------------------------------
>
>                 Key: KARAF-6536
>                 URL: https://issues.apache.org/jira/browse/KARAF-6536
>             Project: Karaf
>          Issue Type: Bug
>          Components: karaf
>    Affects Versions: 4.2.7
>            Reporter: Donnie McMahan
>            Assignee: Jean-Baptiste Onofré
>            Priority: Major
>             Fix For: 4.3.0, 4.2.8
>
>         Attachments: test-features.zip
>
>
> When running karaf-maven-plugin:verify on a feature which references the aries-jax-rs feature, I'm getting a StackOverflowException:
> {code:java}
> Exception in thread "main" java.lang.StackOverflowError
> 	at org.osgi.framework.Version.toString(Version.java:308)
> 	at org.apache.felix.utils.resource.SimpleFilter.convert(SimpleFilter.java:532)
> 	at org.apache.felix.utils.resource.RequirementImpl.getFilter(RequirementImpl.java:133)
> 	at org.apache.felix.utils.resource.RequirementImpl.<init>(RequirementImpl.java:77)
> 	at org.apache.felix.utils.resource.RequirementImpl.<init>(RequirementImpl.java:44)
> 	at org.apache.karaf.features.internal.resolver.ResourceUtils.addIdentityRequirement(ResourceUtils.java:127)
> 	at org.apache.karaf.features.internal.resolver.ResourceUtils.addIdentityRequirement(ResourceUtils.java:107)
> 	at org.apache.karaf.features.internal.resolver.ResourceUtils.addIdentityRequirement(ResourceUtils.java:99)
> 	at org.apache.karaf.features.internal.region.Subsystem.requireFeature(Subsystem.java:284)
> 	at org.apache.karaf.features.internal.region.Subsystem.doBuild(Subsystem.java:350)
> 	at org.apache.karaf.features.internal.region.Subsystem.build(Subsystem.java:332)
> 	at org.apache.karaf.features.internal.region.Subsystem.doBuild(Subsystem.java:390)
> 	at org.apache.karaf.features.internal.region.Subsystem.build(Subsystem.java:332)
> 	at org.apache.karaf.features.internal.region.Subsystem.doBuild(Subsystem.java:390)
> 	at org.apache.karaf.features.internal.region.Subsystem.build(Subsystem.java:332)
> ...
> {code}
> The issue seems to be related to the use of version ranges in the aries-jax-rs feature:
> {code:xml|title=https://github.com/apache/aries-jax-rs-whiteboard/blob/org.apache.aries.jax.rs-1.0.6/jax-rs.features/src/main/feature/feature.xml}
> ...
> <repository>mvn:org.apache.karaf.features/standard/[4,5)/xml/features</repository>
> ...
> {code}
> I've attached a simple project which illustrates the issue. The verify goal completes successfully using the "norange" profile but fails when using the "range" profile.
> Is there a workaround for this?
> Thanks in advance!



--
This message was sent by Atlassian Jira
(v8.3.4#803005)