[GitHub] felix pull request: Felix-5073: dependency-reduced pom

2015-10-09 Thread bimargulies
GitHub user bimargulies opened a pull request:

https://github.com/apache/felix/pull/37

Felix-5073: dependency-reduced pom

Add an option to the maven bundle plugin to remove embedded dependencies 
from the pom.


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/bimargulies/felix felix-5073-dep-red-pom

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/felix/pull/37.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #37


commit a23aafcff13f066e69e04cae677116f30f2db418
Author: Benson Margulies 
Date:   2015-10-09T17:34:03Z

FELIX-5073: dependency-reduced-pom support; remove embedded items from pom.

commit 348480fed2cb2f03c41301c1914cee538f3f9d95
Author: Benson Margulies 
Date:   2015-10-09T18:04:23Z

FELIX-5073: integration test.

commit 5642e897da50816c42dad736c212f3a7a1698422
Author: Benson Margulies 
Date:   2015-10-09T18:20:46Z

FELIX-5073: fill in integration test.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


Re: Future of maven-scr-plugin

2015-10-09 Thread Robert Munteanu
Hi Konrad,


>> Am 09.10.15 um 18:14 schrieb Konrad Windszus:
>>> I experimented a bit and using something like this in my pom.xml works 
>>> pretty well.
>>>
>>> 
>>>  org.apache.felix
>>>  maven-bundle-plugin
>>>  3.0.0
>>>  true
>>>  
>>>
>>>  
>>>  <_dsannotations>*
>>>  
>>>  <_dsannotations-inherit>true
>>>  
>>>  <_metatypeannotations>*
>>>  
>>>  
>>> <_plugin>org.apache.felix.scrplugin.bnd.SCRDescriptorBndPlugin;destdir=target/classes
>>>
>>> 
>>> 
>>>   
>>>   
>>>  org.apache.felix
>>>  org.apache.felix.scr.bnd
>>>  1.4.0
>>>
>>>  
>>> 
>>>

Out of curiosity, have you checked whether the m2e integration with
Eclipse works? I'm interested in the generation of the manifest but
also in the generation of the SCR descriptors.

Thanks,

Robert


[jira] [Commented] (FELIX-5074) Using org.apache.felix.scr.bnd together with maven-bundle-plugin leads to using the wrong bnd version

2015-10-09 Thread Konrad Windszus (JIRA)

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

Konrad Windszus commented on FELIX-5074:


The fix from FELIX-4567 is not working, as this is not a problem with embedding 
bnd in the resulting JAR. It rather is a problem with the pom.xml which defines 
bnd as transitive dependency with scope compile!

> Using org.apache.felix.scr.bnd together with maven-bundle-plugin leads to 
> using the wrong bnd version
> -
>
> Key: FELIX-5074
> URL: https://issues.apache.org/jira/browse/FELIX-5074
> Project: Felix
>  Issue Type: Bug
>  Components: SCR Tooling
>Affects Versions: scr bnd plugin 1.4.0
>Reporter: Konrad Windszus
> Attachments: pom.xml
>
>
> If I have a POM with a plugin configuration like this
> {code}
> 
>   org.apache.felix
>   maven-bundle-plugin
>   3.0.0
>   true
>   
> 
> 
> 
> <_plugin>org.apache.felix.scrplugin.bnd.SCRDescriptorBndPlugin;destdir=target/classes
> 
>   
>   
>   
>
>  org.apache.felix
>  org.apache.felix.scr.bnd
>  1.4.0
>
>  
>  
> {code}
> Unfortunately {{org.apache.felix.scr.bnd}} depends on 
> {{biz.aQute.bnd:bndlib:jar:2.1.0}}. Therefore the classpath of 
> maven-bundle-plugin looks like this:
> {code}
> [DEBUG] Populating class realm 
> plugin>org.apache.felix:maven-bundle-plugin:3.0.0
> [DEBUG]   Included: org.apache.felix:maven-bundle-plugin:jar:3.0.0
> [DEBUG]   Included: org.apache.felix:org.apache.felix.scr.bnd:jar:1.4.0
> [DEBUG]   Included: biz.aQute.bnd:bndlib:jar:2.1.0
> [DEBUG]   Included: org.osgi:org.osgi.core:jar:4.3.1
> [DEBUG]   Included: biz.aQute.bnd:biz.aQute.bndlib:jar:3.0.0
> [DEBUG]   Included: 
> org.apache.felix:org.apache.felix.bundlerepository:jar:1.6.6
> [DEBUG]   Included: org.easymock:easymock:jar:2.5.2
> [DEBUG]   Included: org.apache.felix:org.apache.felix.utils:jar:1.6.0
> [DEBUG]   Included: org.osgi:org.osgi.compendium:jar:4.2.0
> [DEBUG]   Included: org.slf4j:slf4j-jdk14:jar:1.5.6
> [DEBUG]   Included: org.slf4j:slf4j-api:jar:1.5.6
> [DEBUG]   Included: org.slf4j:jcl-over-slf4j:jar:1.5.6
> [DEBUG]   Included: org.apache.maven.reporting:maven-reporting-api:jar:2.2.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-logging-api:jar:1.1
> [DEBUG]   Included: junit:junit:jar:4.11
> [DEBUG]   Included: org.hamcrest:hamcrest-core:jar:1.3
> [DEBUG]   Included: commons-cli:commons-cli:jar:1.2
> [DEBUG]   Included: 
> org.codehaus.plexus:plexus-interactivity-api:jar:1.0-alpha-4
> [DEBUG]   Included: backport-util-concurrent:backport-util-concurrent:jar:3.1
> [DEBUG]   Included: org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3
> [DEBUG]   Included: org.sonatype.plexus:plexus-cipher:jar:1.4
> [DEBUG]   Included: org.apache.maven:maven-archiver:jar:2.5
> [DEBUG]   Included: org.codehaus.plexus:plexus-archiver:jar:2.1
> [DEBUG]   Included: org.codehaus.plexus:plexus-io:jar:2.0.2
> [DEBUG]   Included: org.codehaus.plexus:plexus-interpolation:jar:1.15
> [DEBUG]   Included: org.apache.maven.shared:maven-dependency-tree:jar:2.1
> [DEBUG]   Included: org.codehaus.plexus:plexus-component-annotations:jar:1.5.5
> [DEBUG]   Included: org.eclipse.aether:aether-util:jar:0.9.0.M2
> [DEBUG]   Included: org.codehaus.plexus:plexus-utils:jar:3.0.10
> [DEBUG]   Included: org.sonatype.plexus:plexus-build-api:jar:0.0.7
> [DEBUG]   Included: org.apache.maven.doxia:doxia-sink-api:jar:1.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-site-renderer:jar:1.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-core:jar:1.0
> [DEBUG]   Included: org.codehaus.plexus:plexus-i18n:jar:1.0-beta-7
> [DEBUG]   Included: org.codehaus.plexus:plexus-velocity:jar:1.1.7
> [DEBUG]   Included: org.apache.velocity:velocity:jar:1.5
> [DEBUG]   Included: commons-lang:commons-lang:jar:2.1
> [DEBUG]   Included: oro:oro:jar:2.0.8
> [DEBUG]   Included: org.apache.maven.doxia:doxia-decoration-model:jar:1.0
> [DEBUG]   Included: commons-collections:commons-collections:jar:3.2
> [DEBUG]   Included: org.apache.maven.doxia:doxia-module-apt:jar:1.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-module-fml:jar:1.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-module-xdoc:jar:1.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-module-xhtml:jar:1.0
> [DEBUG]   Excluded: org.apache.maven:maven-core:jar:2.2.0
> [DEBUG]   Excluded: org.apache.maven:maven-settings:jar:2.2.0
> [DEBUG]   Excluded: 
> org.apache.maven:maven-plugin-parameter-documenter:jar:2.2.0
> [DEBUG]   Excluded: org.apache.maven:maven-profile:jar:2.2.0
> [DEBUG]   Excluded: org.apache.maven:maven-model:jar:2.2.0
> [DEBUG]   Excluded: org.apache.maven:maven-artifact:jar:2.2.0
> [DEBUG]   Excluded: 
> org.codehaus.plexus:plexus-container-default:jar:1.0-

[jira] [Commented] (FELIX-5073) Option to create dependency-reduced-pom exists

2015-10-09 Thread Benson Margulies (JIRA)

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

Benson Margulies commented on FELIX-5073:
-

https://github.com/apache/felix/pull/37

I have added 'createDependencyReducedPom' to the plugin. If this is true, the 
pom that gets deployed has the embedded dependencies removed. This is desirable 
since their contents are already included.


> Option to create dependency-reduced-pom exists
> --
>
> Key: FELIX-5073
> URL: https://issues.apache.org/jira/browse/FELIX-5073
> Project: Felix
>  Issue Type: Improvement
>  Components: Maven Bundle Plugin
>Affects Versions: maven-bundle-plugin-3.0.0
>Reporter: Benson Margulies
>
> It would be convenient to have an option, like the dependency-reduced-pom 
> option of the maven-shade-plugin, that removes any inlined/embedded 
> dependencies from the pom of a bundle.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


Re: Future of maven-scr-plugin

2015-10-09 Thread Konrad Windszus
It turned out to be a wrong class path due to a transitive dependency from 
felix.scr.bnd. I opened https://issues.apache.org/jira/browse/FELIX-5074 
 about that!
> On 09 Oct 2015, at 18:40, Carsten Ziegeler  wrote:
> 
> Am 09.10.15 um 18:14 schrieb Konrad Windszus:
>> I experimented a bit and using something like this in my pom.xml works 
>> pretty well.
>> 
>> 
>>  org.apache.felix
>>  maven-bundle-plugin
>>  3.0.0
>>  true
>>  
>>
>>  
>>  <_dsannotations>*
>>  
>>  <_dsannotations-inherit>true
>>  
>>  <_metatypeannotations>*
>>  
>>  
>> <_plugin>org.apache.felix.scrplugin.bnd.SCRDescriptorBndPlugin;destdir=target/classes
>>
>> 
>> 
>>   
>>   
>>  org.apache.felix
>>  org.apache.felix.scr.bnd
>>  1.4.0
>>
>>  
>> 
>> 
>> But while migrating from Felix SCR annotations to official OSGi annotations 
>> I just came across another issue: 
>> Bnd in contrast to maven-scr-plugin will not generate bind methods for 
>> fields annotated with @Reference (although @Reference is being allowed in 
>> fields since OSGi DS 1.3). I opened a bug on that at 
>> https://github.com/bndtools/bnd/issues/1148. Maybe someone can comment on 
>> whether that is a bug in Bnd or the DS Plugin in Bnd was never supposed to 
>> modify existing class files (to add the bind method). That is not clear from 
>> the spec (at least to me).
>> This feature would be an important difference to the maven-scr-plugin as 
>> writing those bind methods manually is a lot more verbose…
> 
> This is not a bug, the new DS version directly manipulates the field and
> does not rely an bind methods. The maven.scr.plugin needed to go this
> way to be compatible with the previous DS spec.
> 
> Regards
> Carsten
> -- 
> Carsten Ziegeler
> Adobe Research Switzerland
> cziege...@apache.org



[jira] [Updated] (FELIX-5074) Using org.apache.felix.scr.bnd together with maven-bundle-plugin leads to using the wrong bnd version

2015-10-09 Thread Konrad Windszus (JIRA)

 [ 
https://issues.apache.org/jira/browse/FELIX-5074?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Konrad Windszus updated FELIX-5074:
---
Attachment: pom.xml

Attached is a demo project. Just execute with {{mvn package -X}} to observe the 
wrong classpath with two times bnd in it.

> Using org.apache.felix.scr.bnd together with maven-bundle-plugin leads to 
> using the wrong bnd version
> -
>
> Key: FELIX-5074
> URL: https://issues.apache.org/jira/browse/FELIX-5074
> Project: Felix
>  Issue Type: Bug
>  Components: SCR Tooling
>Affects Versions: scr bnd plugin 1.4.0
>Reporter: Konrad Windszus
> Attachments: pom.xml
>
>
> If I have a POM with a plugin configuration like this
> {code}
> 
>   org.apache.felix
>   maven-bundle-plugin
>   3.0.0
>   true
>   
> 
> 
> 
> <_plugin>org.apache.felix.scrplugin.bnd.SCRDescriptorBndPlugin;destdir=target/classes
> 
>   
>   
>   
>
>  org.apache.felix
>  org.apache.felix.scr.bnd
>  1.4.0
>
>  
>  
> {code}
> Unfortunately {{org.apache.felix.scr.bnd}} depends on 
> {{biz.aQute.bnd:bndlib:jar:2.1.0}}. Therefore the classpath of 
> maven-bundle-plugin looks like this:
> {code}
> [DEBUG] Populating class realm 
> plugin>org.apache.felix:maven-bundle-plugin:3.0.0
> [DEBUG]   Included: org.apache.felix:maven-bundle-plugin:jar:3.0.0
> [DEBUG]   Included: org.apache.felix:org.apache.felix.scr.bnd:jar:1.4.0
> [DEBUG]   Included: biz.aQute.bnd:bndlib:jar:2.1.0
> [DEBUG]   Included: org.osgi:org.osgi.core:jar:4.3.1
> [DEBUG]   Included: biz.aQute.bnd:biz.aQute.bndlib:jar:3.0.0
> [DEBUG]   Included: 
> org.apache.felix:org.apache.felix.bundlerepository:jar:1.6.6
> [DEBUG]   Included: org.easymock:easymock:jar:2.5.2
> [DEBUG]   Included: org.apache.felix:org.apache.felix.utils:jar:1.6.0
> [DEBUG]   Included: org.osgi:org.osgi.compendium:jar:4.2.0
> [DEBUG]   Included: org.slf4j:slf4j-jdk14:jar:1.5.6
> [DEBUG]   Included: org.slf4j:slf4j-api:jar:1.5.6
> [DEBUG]   Included: org.slf4j:jcl-over-slf4j:jar:1.5.6
> [DEBUG]   Included: org.apache.maven.reporting:maven-reporting-api:jar:2.2.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-logging-api:jar:1.1
> [DEBUG]   Included: junit:junit:jar:4.11
> [DEBUG]   Included: org.hamcrest:hamcrest-core:jar:1.3
> [DEBUG]   Included: commons-cli:commons-cli:jar:1.2
> [DEBUG]   Included: 
> org.codehaus.plexus:plexus-interactivity-api:jar:1.0-alpha-4
> [DEBUG]   Included: backport-util-concurrent:backport-util-concurrent:jar:3.1
> [DEBUG]   Included: org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3
> [DEBUG]   Included: org.sonatype.plexus:plexus-cipher:jar:1.4
> [DEBUG]   Included: org.apache.maven:maven-archiver:jar:2.5
> [DEBUG]   Included: org.codehaus.plexus:plexus-archiver:jar:2.1
> [DEBUG]   Included: org.codehaus.plexus:plexus-io:jar:2.0.2
> [DEBUG]   Included: org.codehaus.plexus:plexus-interpolation:jar:1.15
> [DEBUG]   Included: org.apache.maven.shared:maven-dependency-tree:jar:2.1
> [DEBUG]   Included: org.codehaus.plexus:plexus-component-annotations:jar:1.5.5
> [DEBUG]   Included: org.eclipse.aether:aether-util:jar:0.9.0.M2
> [DEBUG]   Included: org.codehaus.plexus:plexus-utils:jar:3.0.10
> [DEBUG]   Included: org.sonatype.plexus:plexus-build-api:jar:0.0.7
> [DEBUG]   Included: org.apache.maven.doxia:doxia-sink-api:jar:1.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-site-renderer:jar:1.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-core:jar:1.0
> [DEBUG]   Included: org.codehaus.plexus:plexus-i18n:jar:1.0-beta-7
> [DEBUG]   Included: org.codehaus.plexus:plexus-velocity:jar:1.1.7
> [DEBUG]   Included: org.apache.velocity:velocity:jar:1.5
> [DEBUG]   Included: commons-lang:commons-lang:jar:2.1
> [DEBUG]   Included: oro:oro:jar:2.0.8
> [DEBUG]   Included: org.apache.maven.doxia:doxia-decoration-model:jar:1.0
> [DEBUG]   Included: commons-collections:commons-collections:jar:3.2
> [DEBUG]   Included: org.apache.maven.doxia:doxia-module-apt:jar:1.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-module-fml:jar:1.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-module-xdoc:jar:1.0
> [DEBUG]   Included: org.apache.maven.doxia:doxia-module-xhtml:jar:1.0
> [DEBUG]   Excluded: org.apache.maven:maven-core:jar:2.2.0
> [DEBUG]   Excluded: org.apache.maven:maven-settings:jar:2.2.0
> [DEBUG]   Excluded: 
> org.apache.maven:maven-plugin-parameter-documenter:jar:2.2.0
> [DEBUG]   Excluded: org.apache.maven:maven-profile:jar:2.2.0
> [DEBUG]   Excluded: org.apache.maven:maven-model:jar:2.2.0
> [DEBUG]   Excluded: org.apache.maven:maven-artifact:jar:2.2.0
> [DEBUG]   Excluded: 
> org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9-stable-1
> [DEBUG]   Excluded: org.apache.maven:maven-repository-metadata:jar:2.2.0
> [DEBUG]   Excluded: org.apa

[jira] [Created] (FELIX-5074) Using org.apache.felix.scr.bnd together with maven-bundle-plugin leads to using the wrong bnd version

2015-10-09 Thread Konrad Windszus (JIRA)
Konrad Windszus created FELIX-5074:
--

 Summary: Using org.apache.felix.scr.bnd together with 
maven-bundle-plugin leads to using the wrong bnd version
 Key: FELIX-5074
 URL: https://issues.apache.org/jira/browse/FELIX-5074
 Project: Felix
  Issue Type: Bug
  Components: SCR Tooling
Affects Versions: scr bnd plugin 1.4.0
Reporter: Konrad Windszus


If I have a POM with a plugin configuration like this
{code}

  org.apache.felix
  maven-bundle-plugin
  3.0.0
  true
  



<_plugin>org.apache.felix.scrplugin.bnd.SCRDescriptorBndPlugin;destdir=target/classes

  
  
  
   
 org.apache.felix
 org.apache.felix.scr.bnd
 1.4.0
   
 
 
{code}

Unfortunately {{org.apache.felix.scr.bnd}} depends on 
{{biz.aQute.bnd:bndlib:jar:2.1.0}}. Therefore the classpath of 
maven-bundle-plugin looks like this:
{code}
[DEBUG] Populating class realm plugin>org.apache.felix:maven-bundle-plugin:3.0.0
[DEBUG]   Included: org.apache.felix:maven-bundle-plugin:jar:3.0.0
[DEBUG]   Included: org.apache.felix:org.apache.felix.scr.bnd:jar:1.4.0
[DEBUG]   Included: biz.aQute.bnd:bndlib:jar:2.1.0
[DEBUG]   Included: org.osgi:org.osgi.core:jar:4.3.1
[DEBUG]   Included: biz.aQute.bnd:biz.aQute.bndlib:jar:3.0.0
[DEBUG]   Included: org.apache.felix:org.apache.felix.bundlerepository:jar:1.6.6
[DEBUG]   Included: org.easymock:easymock:jar:2.5.2
[DEBUG]   Included: org.apache.felix:org.apache.felix.utils:jar:1.6.0
[DEBUG]   Included: org.osgi:org.osgi.compendium:jar:4.2.0
[DEBUG]   Included: org.slf4j:slf4j-jdk14:jar:1.5.6
[DEBUG]   Included: org.slf4j:slf4j-api:jar:1.5.6
[DEBUG]   Included: org.slf4j:jcl-over-slf4j:jar:1.5.6
[DEBUG]   Included: org.apache.maven.reporting:maven-reporting-api:jar:2.2.0
[DEBUG]   Included: org.apache.maven.doxia:doxia-logging-api:jar:1.1
[DEBUG]   Included: junit:junit:jar:4.11
[DEBUG]   Included: org.hamcrest:hamcrest-core:jar:1.3
[DEBUG]   Included: commons-cli:commons-cli:jar:1.2
[DEBUG]   Included: org.codehaus.plexus:plexus-interactivity-api:jar:1.0-alpha-4
[DEBUG]   Included: backport-util-concurrent:backport-util-concurrent:jar:3.1
[DEBUG]   Included: org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3
[DEBUG]   Included: org.sonatype.plexus:plexus-cipher:jar:1.4
[DEBUG]   Included: org.apache.maven:maven-archiver:jar:2.5
[DEBUG]   Included: org.codehaus.plexus:plexus-archiver:jar:2.1
[DEBUG]   Included: org.codehaus.plexus:plexus-io:jar:2.0.2
[DEBUG]   Included: org.codehaus.plexus:plexus-interpolation:jar:1.15
[DEBUG]   Included: org.apache.maven.shared:maven-dependency-tree:jar:2.1
[DEBUG]   Included: org.codehaus.plexus:plexus-component-annotations:jar:1.5.5
[DEBUG]   Included: org.eclipse.aether:aether-util:jar:0.9.0.M2
[DEBUG]   Included: org.codehaus.plexus:plexus-utils:jar:3.0.10
[DEBUG]   Included: org.sonatype.plexus:plexus-build-api:jar:0.0.7
[DEBUG]   Included: org.apache.maven.doxia:doxia-sink-api:jar:1.0
[DEBUG]   Included: org.apache.maven.doxia:doxia-site-renderer:jar:1.0
[DEBUG]   Included: org.apache.maven.doxia:doxia-core:jar:1.0
[DEBUG]   Included: org.codehaus.plexus:plexus-i18n:jar:1.0-beta-7
[DEBUG]   Included: org.codehaus.plexus:plexus-velocity:jar:1.1.7
[DEBUG]   Included: org.apache.velocity:velocity:jar:1.5
[DEBUG]   Included: commons-lang:commons-lang:jar:2.1
[DEBUG]   Included: oro:oro:jar:2.0.8
[DEBUG]   Included: org.apache.maven.doxia:doxia-decoration-model:jar:1.0
[DEBUG]   Included: commons-collections:commons-collections:jar:3.2
[DEBUG]   Included: org.apache.maven.doxia:doxia-module-apt:jar:1.0
[DEBUG]   Included: org.apache.maven.doxia:doxia-module-fml:jar:1.0
[DEBUG]   Included: org.apache.maven.doxia:doxia-module-xdoc:jar:1.0
[DEBUG]   Included: org.apache.maven.doxia:doxia-module-xhtml:jar:1.0
[DEBUG]   Excluded: org.apache.maven:maven-core:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-settings:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-plugin-parameter-documenter:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-profile:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-model:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-artifact:jar:2.2.0
[DEBUG]   Excluded: 
org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9-stable-1
[DEBUG]   Excluded: org.apache.maven:maven-repository-metadata:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-error-diagnostics:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-project:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-plugin-registry:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-plugin-api:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-plugin-descriptor:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-artifact-manager:jar:2.2.0
[DEBUG]   Excluded: org.apache.maven:maven-monitor:jar:2.2.0
[DEBUG]   Excluded: classworlds:classworlds:jar:1.1
{code}

So the classpath contains both bnd 2.1 and bnd 3.0.
IMHO the {{felix.scr.bnd}}

What version of Maven is the maven-bundle-plugin minimally trying to require?

2015-10-09 Thread Benson Margulies
I'm trying to build some new functionality, and getting tangled up in
the antique dependencies, and wondering if I can just push it to the
Maven 3.x pattern altogether.


Re: [VOTE] Release Apache Felix Http Base 3.0.2, Http Bridge 3.0.2, and Http Jetty 3.1.2

2015-10-09 Thread Sten Roger Sandvik
+1
fre. 9. okt. 2015 kl. 17.43 skrev David Bosschaert <
david.bosscha...@gmail.com>:

> +1
>
> David
>
> On 9 October 2015 at 16:15, Carsten Ziegeler  wrote:
> > I would like to call a vote on the following subproject releases:
> >
> > Http Base 3.0.2 - 4 issues solved
> > https://issues.apache.org/jira/browse/FELIX/fixforversion/12333076
> >
> > Http Bridge 3.0.2 - 4 issues solved
> > https://issues.apache.org/jira/browse/FELIX/fixforversion/12333282
> >
> > Http Jetty 3.1.2 - 5 issues solved
> > https://issues.apache.org/jira/browse/FELIX/fixforversion/12333135
> >
> > Staging repositories:
> > https://repository.apache.org/content/repositories/orgapachefelix-1098/
> >
> > You can use this UNIX script to download the release and verify the
> > signatures:
> > http://svn.apache.org/repos/asf/felix/trunk/check_staged_release.sh
> >
> > Usage:
> > sh check_staged_release.sh 1098 /tmp/felix-staging
> >
> > Please vote to approve this release:
> >
> > [ ] +1 Approve the release
> > [ ] -1 Veto the release (please provide specific comments)
> >
> > Regards
> > Carsten
> > --
> > Carsten Ziegeler
> > Adobe Research Switzerland
> > cziege...@apache.org
>


Re: Future of maven-scr-plugin

2015-10-09 Thread Carsten Ziegeler
Am 09.10.15 um 18:14 schrieb Konrad Windszus:
> I experimented a bit and using something like this in my pom.xml works pretty 
> well.
> 
> 
>   org.apache.felix
>   maven-bundle-plugin
>   3.0.0
>   true
>   
> 
>   
>   <_dsannotations>*
>   
>   <_dsannotations-inherit>true
>   
>   <_metatypeannotations>*
>   
>   
> <_plugin>org.apache.felix.scrplugin.bnd.SCRDescriptorBndPlugin;destdir=target/classes
> 
>  
>  
>
>
>   org.apache.felix
>   org.apache.felix.scr.bnd
>   1.4.0
> 
>   
> 
> 
> But while migrating from Felix SCR annotations to official OSGi annotations I 
> just came across another issue: 
> Bnd in contrast to maven-scr-plugin will not generate bind methods for fields 
> annotated with @Reference (although @Reference is being allowed in fields 
> since OSGi DS 1.3). I opened a bug on that at 
> https://github.com/bndtools/bnd/issues/1148. Maybe someone can comment on 
> whether that is a bug in Bnd or the DS Plugin in Bnd was never supposed to 
> modify existing class files (to add the bind method). That is not clear from 
> the spec (at least to me).
> This feature would be an important difference to the maven-scr-plugin as 
> writing those bind methods manually is a lot more verbose…

This is not a bug, the new DS version directly manipulates the field and
does not rely an bind methods. The maven.scr.plugin needed to go this
way to be compatible with the previous DS spec.

Regards
Carsten
-- 
Carsten Ziegeler
Adobe Research Switzerland
cziege...@apache.org


Re: Future of maven-scr-plugin

2015-10-09 Thread Konrad Windszus
I experimented a bit and using something like this in my pom.xml works pretty 
well.


  org.apache.felix
  maven-bundle-plugin
  3.0.0
  true
  

  
  <_dsannotations>*
  
  <_dsannotations-inherit>true
  
  <_metatypeannotations>*
  
  
<_plugin>org.apache.felix.scrplugin.bnd.SCRDescriptorBndPlugin;destdir=target/classes

 
 
   
   
  org.apache.felix
  org.apache.felix.scr.bnd
  1.4.0

  


But while migrating from Felix SCR annotations to official OSGi annotations I 
just came across another issue: 
Bnd in contrast to maven-scr-plugin will not generate bind methods for fields 
annotated with @Reference (although @Reference is being allowed in fields since 
OSGi DS 1.3). I opened a bug on that at 
https://github.com/bndtools/bnd/issues/1148. Maybe someone can comment on 
whether that is a bug in Bnd or the DS Plugin in Bnd was never supposed to 
modify existing class files (to add the bind method). That is not clear from 
the spec (at least to me).
This feature would be an important difference to the maven-scr-plugin as 
writing those bind methods manually is a lot more verbose…
Konrad


> On 07 Oct 2015, at 18:33, Konrad Windszus  wrote:
> 
> Hi Carsten, 
> thanks for your answer. One other thing to mention here is that custom 
> plugins exist for the maven-scr-plugin 
> (http://felix.apache.org/documentation/subprojects/apache-felix-maven-scr-plugin/extending-scr-annotations.html
>  
> ).
> Could those be easily migrated to bnd plugins? Do you have any hints on how 
> to accomplish that for @SlingServlet, @SlingFilter (currently part of 
> maven-scr-plugin, but should be moved to a Sling module then) and for 
> @SlingHealthCheck 
> (https://github.com/apache/sling/blob/trunk/bundles/extensions/healthcheck/annotations/src/main/java/org/apache/sling/hc/annotations/SlingHealthCheckProcessor.java
>  
> )?
> Thanks
> Konrad
> 
>> On 07 Oct 2015, at 18:18, Carsten Ziegeler  wrote:
>> 
>> Hi
>> 
>> Am 07.10.15 um 21:07 schrieb Konrad Windszus:
>>> Hi,
>>> I am wondering about the future of the maven-scr-plugin. I think it should 
>>> be deprecated and instead the documentation should point to the 
>>> maven-bundle-plugin to be used now even for generating descriptors for 
>>> metatype and declarative services.
>>> 
>>> That can nowadays take care of generating the component descriptor [0] with 
>>> the OSGi standard annotations [1]. For the metatype generation bnd came up 
>>> with its own annotations[3], which should be a replacement for all 
>>> maven-scr-plugin annotations.
>> Actually there are standard metatype annotations as well which work
>> nicely with the new R6 DS annotations. So no need to use proprietary
>> annotations anymore
>> 
>>> Also it seems that maven-scr-plugin is not compatible with Declarative 
>>> Services 1.3 (meaning I cannot use "Configuration Property Types”) [3].
>> It only supports DS upto 1.2
>> 
>>> 
>>> The only thing which is not covered in the maven-bundle-plugin is component 
>>> inheritance (but that is deprecated anyways [4]).
>> That's why we deprecated it :)
>> 
>>> Are there any other feature of the maven-scr-plugin which are not covered 
>>> by bnd/maven-bundle-plugin?
>> Nearly none - we have default properties in the scr plugin, so you can
>> configure something like the vendor once in your parent pom and it gets
>> applied to every component.
>> 
>> The plan is to indeed phase out the maven scr plugin. It still has some
>> usage, as the bundle plugin is not a dropin replacement. You would need
>> to rewrite your components - and switching to the official annotations
>> has some subtle differences in the defaults.
>> On the other hand, we have a bnd plugin that is able to process the
>> proprietary Felix annotations.
>> 
>> Therefore, I totally agree that we should update the documentation. But
>> of course we have to support our user base for some time.
>> 
>> Carsten
>> 
>>> 
>>> My request originates from the discussion at 
>>> https://github.com/bndtools/bnd/issues/999.
>>> 
>>> WDYT?
>>> Thanks for any input,
>>> Konrad
>>> 
>>> 
>>> [0] - http://www.aqute.biz/Bnd/Components
>>> [1] - 
>>> https://osgi.org/javadoc/r6/enterprise/org/osgi/service/component/annotations/package-summary.html
>>> [2] - http://www.aqute.biz/Bnd/MetaType
>>> [3] - http://njbartlett.name/2015/08/17/osgir6-declarative-services.html
>>> [4] - https://issues.apache.org/jira/browse/FELIX-4170
>>> 
>>> 
>> 
>> 
>> -- 
>> Carsten Ziegeler
>> Adobe Research Switzerland
>> cziege...@apache.org
> 



[jira] [Created] (FELIX-5073) Option to create dependency-reduced-pom exists

2015-10-09 Thread Benson Margulies (JIRA)
Benson Margulies created FELIX-5073:
---

 Summary: Option to create dependency-reduced-pom exists
 Key: FELIX-5073
 URL: https://issues.apache.org/jira/browse/FELIX-5073
 Project: Felix
  Issue Type: Improvement
  Components: Maven Bundle Plugin
Affects Versions: maven-bundle-plugin-3.0.0
Reporter: Benson Margulies


It would be convenient to have an option, like the dependency-reduced-pom 
option of the maven-shade-plugin, that removes any inlined/embedded 
dependencies from the pom of a bundle.




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


Re: [VOTE] Release Apache Felix Http Base 3.0.2, Http Bridge 3.0.2, and Http Jetty 3.1.2

2015-10-09 Thread David Bosschaert
+1

David

On 9 October 2015 at 16:15, Carsten Ziegeler  wrote:
> I would like to call a vote on the following subproject releases:
>
> Http Base 3.0.2 - 4 issues solved
> https://issues.apache.org/jira/browse/FELIX/fixforversion/12333076
>
> Http Bridge 3.0.2 - 4 issues solved
> https://issues.apache.org/jira/browse/FELIX/fixforversion/12333282
>
> Http Jetty 3.1.2 - 5 issues solved
> https://issues.apache.org/jira/browse/FELIX/fixforversion/12333135
>
> Staging repositories:
> https://repository.apache.org/content/repositories/orgapachefelix-1098/
>
> You can use this UNIX script to download the release and verify the
> signatures:
> http://svn.apache.org/repos/asf/felix/trunk/check_staged_release.sh
>
> Usage:
> sh check_staged_release.sh 1098 /tmp/felix-staging
>
> Please vote to approve this release:
>
> [ ] +1 Approve the release
> [ ] -1 Veto the release (please provide specific comments)
>
> Regards
> Carsten
> --
> Carsten Ziegeler
> Adobe Research Switzerland
> cziege...@apache.org


Re: [VOTE] Release Apache Felix Http Base 3.0.2, Http Bridge 3.0.2, and Http Jetty 3.1.2

2015-10-09 Thread Carsten Ziegeler
+1

Carsten
-- 
Carsten Ziegeler
Adobe Research Switzerland
cziege...@apache.org


[VOTE] Release Apache Felix Http Base 3.0.2, Http Bridge 3.0.2, and Http Jetty 3.1.2

2015-10-09 Thread Carsten Ziegeler
I would like to call a vote on the following subproject releases:

Http Base 3.0.2 - 4 issues solved
https://issues.apache.org/jira/browse/FELIX/fixforversion/12333076

Http Bridge 3.0.2 - 4 issues solved
https://issues.apache.org/jira/browse/FELIX/fixforversion/12333282

Http Jetty 3.1.2 - 5 issues solved
https://issues.apache.org/jira/browse/FELIX/fixforversion/12333135

Staging repositories:
https://repository.apache.org/content/repositories/orgapachefelix-1098/

You can use this UNIX script to download the release and verify the
signatures:
http://svn.apache.org/repos/asf/felix/trunk/check_staged_release.sh

Usage:
sh check_staged_release.sh 1098 /tmp/felix-staging

Please vote to approve this release:

[ ] +1 Approve the release
[ ] -1 Veto the release (please provide specific comments)

Regards
Carsten
-- 
Carsten Ziegeler
Adobe Research Switzerland
cziege...@apache.org


[jira] [Resolved] (FELIX-5053) IllegalArgumentException when forwarding request

2015-10-09 Thread Carsten Ziegeler (JIRA)

 [ 
https://issues.apache.org/jira/browse/FELIX-5053?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Carsten Ziegeler resolved FELIX-5053.
-
Resolution: Fixed

> IllegalArgumentException when forwarding request
> 
>
> Key: FELIX-5053
> URL: https://issues.apache.org/jira/browse/FELIX-5053
> Project: Felix
>  Issue Type: Bug
>  Components: HTTP Service
>Affects Versions: http.base-3.0.0
>Reporter: Sten Roger Sandvik
>Assignee: Sten Roger Sandvik
> Fix For: http.base-3.0.2
>
>
> It seems to be a problem with forwarding requests in certain cases. I have 
> the following setup:
> * Servlet A forwards the request to Servlet 2 (using RequestDispatcher).
> * Servlet B writes to the response using an output stream 
> (HttpServletResponse.getOutputStream()).
> When this happens I get an IllegalStateException from Jetty that basically 
> saying that the Writer cannot be closed since I have already used an 
> OutputStream.
> The code that I think is wrong (or possibly not robust enough) is in 
> RequestDispatcherImp line 84. 
> {code}
> if (!request.isAsyncStarted())
> {
>   response.flushBuffer();
>   response.getWriter().close();
> }
> {code}
> The line that causes trouble is:
> {code}
> response.getWriter().close();
> {code}
> We should probably check if we can actually close this writer or just ignore 
> the potential exception.
> In my setup I have one servlet that writes to OutputStream using 
> HttpServletResponse.getOutputStream(). Then I have another servlet that 
> forwards the request to the first servlet. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (FELIX-5053) IllegalArgumentException when forwarding request

2015-10-09 Thread Sten Roger Sandvik (JIRA)

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

Sten Roger Sandvik commented on FELIX-5053:
---

Looks good. I think this will do it. Tested it agaist my setup and everything 
works perfectly.

> IllegalArgumentException when forwarding request
> 
>
> Key: FELIX-5053
> URL: https://issues.apache.org/jira/browse/FELIX-5053
> Project: Felix
>  Issue Type: Bug
>  Components: HTTP Service
>Affects Versions: http.base-3.0.0
>Reporter: Sten Roger Sandvik
>Assignee: Sten Roger Sandvik
> Fix For: http.base-3.0.2
>
>
> It seems to be a problem with forwarding requests in certain cases. I have 
> the following setup:
> * Servlet A forwards the request to Servlet 2 (using RequestDispatcher).
> * Servlet B writes to the response using an output stream 
> (HttpServletResponse.getOutputStream()).
> When this happens I get an IllegalStateException from Jetty that basically 
> saying that the Writer cannot be closed since I have already used an 
> OutputStream.
> The code that I think is wrong (or possibly not robust enough) is in 
> RequestDispatcherImp line 84. 
> {code}
> if (!request.isAsyncStarted())
> {
>   response.flushBuffer();
>   response.getWriter().close();
> }
> {code}
> The line that causes trouble is:
> {code}
> response.getWriter().close();
> {code}
> We should probably check if we can actually close this writer or just ignore 
> the potential exception.
> In my setup I have one servlet that writes to OutputStream using 
> HttpServletResponse.getOutputStream(). Then I have another servlet that 
> forwards the request to the first servlet. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)