You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Andrei Pozolotin (Created) (JIRA)" <ji...@apache.org> on 2011/10/17 17:22:10 UTC

[jira] [Created] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

scr-maven-plugin : incremental build mode for eclipse development?
------------------------------------------------------------------

                 Key: FELIX-3170
                 URL: https://issues.apache.org/jira/browse/FELIX-3170
             Project: Felix
          Issue Type: New Feature
          Components: Maven SCR Plugin
            Reporter: Andrei Pozolotin


Hello;

SITUATION:

I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
project has some 1000 java files and 100 scr components;

on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;

as project progressed, the responsiveness of eclipse continued to dwindle down,
now to 3...5 seconds delay on each java file edit;

QUESTIONS:

1) is it feasible to support incremental build in scr plugin?
for this, plugin would have to:
a) keep scr components parse/build cache
b) support a new goal, when only a single file with scr annotations is requested for processing
but still produces complete scr xml;

2) has anyone devised a better solution to this?

thank you;

Andrei.


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Carsten Ziegeler (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13129580#comment-13129580 ] 

Carsten Ziegeler commented on FELIX-3170:
-----------------------------------------

Interesting stuff!

I always had the idea to implement an annotation processor for the scr stuff, so this would basically level up with the bnd support I guess then
                
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Carsten Ziegeler (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Carsten Ziegeler resolved FELIX-3170.
-------------------------------------

    Resolution: Duplicate

Closing this as a duplicate of FELIX-3358 where we have started working on this
                
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Konrad Windszus (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13187784#comment-13187784 ] 

Konrad Windszus commented on FELIX-3170:
----------------------------------------

I guess FELIX-3305 might be a duplicate. 

I think maven-scr-plugin is still superior to what is defined in the draft, not only for the inheritance feature but also on how it is possible to define Properties and finally it is generating the metatype.xml as well. So personally I would love to see the necessary plugins for the Felix SCR Plugin, equally to what is already provided by the maven-bundle-plugin 2.4.0 SNAPSHOT and the Tycho m2e plugin (as described in comment 1).

This is especially usefull for us JRebel users, so that there is no need for redeployment in case of OSGi components.
                
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Stuart McCulloch (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13129252#comment-13129252 ] 

Stuart McCulloch commented on FELIX-3170:
-----------------------------------------

You could consider switching over to Java annotations, rather than javadoc annotations. For example, bndlib 1.43.0 has some (non-standard) component annotations:

   http://www.aqute.biz/Blog/20091020
   http://www.aqute.biz/Bnd/Components

   http://search.maven.org/#artifactdetails%7Cbiz.aQute%7Cbndlib%7C1.43.0%7Cjar

And the draft of forthcoming updates to the OSGi spec http://www.osgi.org/download/osgi-early-draft-2011-09.pdf contains a proposal for standard Java annotations for Declarative Services (RFC 0172). A preview of these annotations will soon be available in a new bndlib, which will be included in the next maven-bundle-plugin release.

The benefit of using runtime Java annotations is that you can then get incremental compilation by virtue of the Eclipse compiler. To see this in action, try updating to the latest 2.4.0-SNAPSHOT of the maven-bundle-plugin and import your project into Eclipse using the latest version of m2e (came bundled with 3.7, but also available on the Eclipse Marketplace). Make sure you have the latest Tycho configurators installed... go to About Eclipse->Installation Details->Installed Software, you should see:

   Tycho Project Configurators	0.6.0.201110151902	org.sonatype.tycho.m2e.feature.feature.group	Sonatype, Inc.

If you don't have this installed, go to Preferences->Maven->Discovery->Open Catalog and find the Tycho entry, select the checkbox and press the Finish button.

With the latest m2e + tycho and the latest maven-bundle-plugin snapshot you can do some cool stuff. For example you can add "<unpackBundle>true</unpackBundle>" to your maven-bundle-plugin configuration to get it to automatically unpack any extra files generated by bnd. That way as you edit the class file and add Java annotations, such as @Component, m2e will trigger a refresh of the manifest and unpack the updated component XML.
                
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Closed] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Carsten Ziegeler (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Carsten Ziegeler closed FELIX-3170.
-----------------------------------

    
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Andrei Pozolotin (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13129268#comment-13129268 ] 

Andrei Pozolotin commented on FELIX-3170:
-----------------------------------------

Stuart:

your comments are extremely valuable!

I was using java annotations (felix scr, not javadoc, not bnd/osgi) from the start, 
but was under impression that I MUST run scr plugin to convert java annotations -> scr.xml;

now I will try to see how your suggested 
bnd java annotations -> maven-bundle-plugin -> bnd -> src.xml 
path works and report back;

thank you!

Andrei.
                
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Issue Comment Edited] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Andrei Pozolotin (Issue Comment Edited) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13129775#comment-13129775 ] 

Andrei Pozolotin edited comment on FELIX-3170 at 10/18/11 2:58 PM:
-------------------------------------------------------------------

per Peter:

http://groups.google.com/group/bndtools-users/browse_thread/thread/dd457cce9267456a

I filed osgi bug:

https://www.osgi.org/bugzilla/show_bug.cgi?id=124

so, felix scr annotation processor is still competing on features :-)
                
      was (Author: andrei.pozolotin):
    per Peter:

http://groups.google.com/group/bndtools-users/browse_thread/thread/dd457cce9267456a

I filed osgi bug:

https://www.osgi.org/bugzilla/show_bug.cgi?id=124

so, felix scr annotation process is still competing on features :-)
                  
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Issue Comment Edited] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Konrad Windszus (Issue Comment Edited) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13187784#comment-13187784 ] 

Konrad Windszus edited comment on FELIX-3170 at 1/17/12 4:28 PM:
-----------------------------------------------------------------

I guess FELIX-3305 might be a duplicate. 

I think maven-scr-plugin is still superior to what is defined in the draft, not only for the inheritance feature but also on how it is possible to define Properties and finally it is generating the metatype.xml as well. So personally I would love to see the necessary plugins for the Felix SCR Plugin, equally to what is already provided by the maven-bundle-plugin 2.4.0 SNAPSHOT and the Tycho m2e plugin (as described in comment 1) for the draft proposal.

This is especially usefull for us JRebel users, so that there is no need for redeployment in case of OSGi components.
                
      was (Author: kwin):
    I guess FELIX-3305 might be a duplicate. 

I think maven-scr-plugin is still superior to what is defined in the draft, not only for the inheritance feature but also on how it is possible to define Properties and finally it is generating the metatype.xml as well. So personally I would love to see the necessary plugins for the Felix SCR Plugin, equally to what is already provided by the maven-bundle-plugin 2.4.0 SNAPSHOT and the Tycho m2e plugin (as described in comment 1).

This is especially usefull for us JRebel users, so that there is no need for redeployment in case of OSGi components.
                  
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Issue Comment Edited] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Stuart McCulloch (Issue Comment Edited) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13129252#comment-13129252 ] 

Stuart McCulloch edited comment on FELIX-3170 at 10/17/11 10:14 PM:
--------------------------------------------------------------------

You could consider switching over to Java annotations, rather than javadoc annotations. For example, bndlib 1.43.0 has some (non-standard) component annotations:

   http://www.aqute.biz/Blog/20091020
   http://www.aqute.biz/Bnd/Components

   http://search.maven.org/#artifactdetails%7Cbiz.aQute%7Cbndlib%7C1.43.0%7Cjar

And the draft of forthcoming updates to the OSGi spec http://www.osgi.org/download/osgi-early-draft-2011-09.pdf contains a proposal for standard Java annotations for Declarative Services (RFC 0172). A preview of these annotations will soon be available in a new bndlib, which will be included in the next maven-bundle-plugin release.

The benefit of using Java annotations is that you can then get incremental compilation by virtue of the Eclipse compiler. To see this in action, try updating to the latest 2.4.0-SNAPSHOT of the maven-bundle-plugin and import your project into Eclipse using the latest version of m2e (came bundled with 3.7, but also available on the Eclipse Marketplace). Make sure you have the latest Tycho configurators installed... go to About Eclipse->Installation Details->Installed Software, you should see:

   Tycho Project Configurators	0.6.0.201110151902	org.sonatype.tycho.m2e.feature.feature.group	Sonatype, Inc.

If you don't have this installed, go to Preferences->Maven->Discovery->Open Catalog and find the Tycho entry, select the checkbox and press the Finish button.

With the latest m2e + tycho and the latest maven-bundle-plugin snapshot you can do some cool stuff. For example you can add "<unpackBundle>true</unpackBundle>" to your maven-bundle-plugin configuration to get it to automatically unpack any extra files generated by bnd. That way as you edit the class file and add Java annotations, such as @Component, m2e will trigger a refresh of the manifest and unpack the updated component XML. You shouldn't then need to use the maven-scr-plugin, since bnd (via the maven-bundle-plugin) would be transforming your component annotations into XML.
                
      was (Author: mcculls):
    You could consider switching over to Java annotations, rather than javadoc annotations. For example, bndlib 1.43.0 has some (non-standard) component annotations:

   http://www.aqute.biz/Blog/20091020
   http://www.aqute.biz/Bnd/Components

   http://search.maven.org/#artifactdetails%7Cbiz.aQute%7Cbndlib%7C1.43.0%7Cjar

And the draft of forthcoming updates to the OSGi spec http://www.osgi.org/download/osgi-early-draft-2011-09.pdf contains a proposal for standard Java annotations for Declarative Services (RFC 0172). A preview of these annotations will soon be available in a new bndlib, which will be included in the next maven-bundle-plugin release.

The benefit of using runtime Java annotations is that you can then get incremental compilation by virtue of the Eclipse compiler. To see this in action, try updating to the latest 2.4.0-SNAPSHOT of the maven-bundle-plugin and import your project into Eclipse using the latest version of m2e (came bundled with 3.7, but also available on the Eclipse Marketplace). Make sure you have the latest Tycho configurators installed... go to About Eclipse->Installation Details->Installed Software, you should see:

   Tycho Project Configurators	0.6.0.201110151902	org.sonatype.tycho.m2e.feature.feature.group	Sonatype, Inc.

If you don't have this installed, go to Preferences->Maven->Discovery->Open Catalog and find the Tycho entry, select the checkbox and press the Finish button.

With the latest m2e + tycho and the latest maven-bundle-plugin snapshot you can do some cool stuff. For example you can add "<unpackBundle>true</unpackBundle>" to your maven-bundle-plugin configuration to get it to automatically unpack any extra files generated by bnd. That way as you edit the class file and add Java annotations, such as @Component, m2e will trigger a refresh of the manifest and unpack the updated component XML. You shouldn't then need to use the maven-scr-plugin, since bnd (via the maven-bundle-plugin) would be transforming your component annotations into XML.
                  
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Issue Comment Edited] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Stuart McCulloch (Issue Comment Edited) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13129252#comment-13129252 ] 

Stuart McCulloch edited comment on FELIX-3170 at 10/17/11 10:10 PM:
--------------------------------------------------------------------

You could consider switching over to Java annotations, rather than javadoc annotations. For example, bndlib 1.43.0 has some (non-standard) component annotations:

   http://www.aqute.biz/Blog/20091020
   http://www.aqute.biz/Bnd/Components

   http://search.maven.org/#artifactdetails%7Cbiz.aQute%7Cbndlib%7C1.43.0%7Cjar

And the draft of forthcoming updates to the OSGi spec http://www.osgi.org/download/osgi-early-draft-2011-09.pdf contains a proposal for standard Java annotations for Declarative Services (RFC 0172). A preview of these annotations will soon be available in a new bndlib, which will be included in the next maven-bundle-plugin release.

The benefit of using runtime Java annotations is that you can then get incremental compilation by virtue of the Eclipse compiler. To see this in action, try updating to the latest 2.4.0-SNAPSHOT of the maven-bundle-plugin and import your project into Eclipse using the latest version of m2e (came bundled with 3.7, but also available on the Eclipse Marketplace). Make sure you have the latest Tycho configurators installed... go to About Eclipse->Installation Details->Installed Software, you should see:

   Tycho Project Configurators	0.6.0.201110151902	org.sonatype.tycho.m2e.feature.feature.group	Sonatype, Inc.

If you don't have this installed, go to Preferences->Maven->Discovery->Open Catalog and find the Tycho entry, select the checkbox and press the Finish button.

With the latest m2e + tycho and the latest maven-bundle-plugin snapshot you can do some cool stuff. For example you can add "<unpackBundle>true</unpackBundle>" to your maven-bundle-plugin configuration to get it to automatically unpack any extra files generated by bnd. That way as you edit the class file and add Java annotations, such as @Component, m2e will trigger a refresh of the manifest and unpack the updated component XML. You shouldn't then need to use the maven-scr-plugin, since bnd (via the maven-bundle-plugin) would be transforming your component annotations into XML.
                
      was (Author: mcculls):
    You could consider switching over to Java annotations, rather than javadoc annotations. For example, bndlib 1.43.0 has some (non-standard) component annotations:

   http://www.aqute.biz/Blog/20091020
   http://www.aqute.biz/Bnd/Components

   http://search.maven.org/#artifactdetails%7Cbiz.aQute%7Cbndlib%7C1.43.0%7Cjar

And the draft of forthcoming updates to the OSGi spec http://www.osgi.org/download/osgi-early-draft-2011-09.pdf contains a proposal for standard Java annotations for Declarative Services (RFC 0172). A preview of these annotations will soon be available in a new bndlib, which will be included in the next maven-bundle-plugin release.

The benefit of using runtime Java annotations is that you can then get incremental compilation by virtue of the Eclipse compiler. To see this in action, try updating to the latest 2.4.0-SNAPSHOT of the maven-bundle-plugin and import your project into Eclipse using the latest version of m2e (came bundled with 3.7, but also available on the Eclipse Marketplace). Make sure you have the latest Tycho configurators installed... go to About Eclipse->Installation Details->Installed Software, you should see:

   Tycho Project Configurators	0.6.0.201110151902	org.sonatype.tycho.m2e.feature.feature.group	Sonatype, Inc.

If you don't have this installed, go to Preferences->Maven->Discovery->Open Catalog and find the Tycho entry, select the checkbox and press the Finish button.

With the latest m2e + tycho and the latest maven-bundle-plugin snapshot you can do some cool stuff. For example you can add "<unpackBundle>true</unpackBundle>" to your maven-bundle-plugin configuration to get it to automatically unpack any extra files generated by bnd. That way as you edit the class file and add Java annotations, such as @Component, m2e will trigger a refresh of the manifest and unpack the updated component XML.
                  
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (FELIX-3170) scr-maven-plugin : incremental build mode for eclipse development?

Posted by "Andrei Pozolotin (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13129775#comment-13129775 ] 

Andrei Pozolotin commented on FELIX-3170:
-----------------------------------------

per Peter:

http://groups.google.com/group/bndtools-users/browse_thread/thread/dd457cce9267456a

I filed osgi bug:

https://www.osgi.org/bugzilla/show_bug.cgi?id=124

so, felix scr annotation process is still competing on features :-)
                
> scr-maven-plugin : incremental build mode for eclipse development?
> ------------------------------------------------------------------
>
>                 Key: FELIX-3170
>                 URL: https://issues.apache.org/jira/browse/FELIX-3170
>             Project: Felix
>          Issue Type: New Feature
>          Components: Maven SCR Plugin
>            Reporter: Andrei Pozolotin
>
> Hello;
> SITUATION:
> I am using scr-maven-plugin in eclipse 3.7 with m2e incremental mode;
> project has some 1000 java files and 100 scr components;
> on every java file save, eclipse runs JDT builder and then maven invokes SRC plugin;
> as project progressed, the responsiveness of eclipse continued to dwindle down,
> now to 3...5 seconds delay on each java file edit;
> QUESTIONS:
> 1) is it feasible to support incremental build in scr plugin?
> for this, plugin would have to:
> a) keep scr components parse/build cache
> b) support a new goal, when only a single file with scr annotations is requested for processing
> but still produces complete scr xml;
> 2) has anyone devised a better solution to this?
> thank you;
> Andrei.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira