You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by Christian Posta <ch...@gmail.com> on 2013/08/16 22:43:47 UTC

spi-annotations

So in camel-core, the spi-annotations dependency is marked "optional" in
the pom.

    <!-- required dependencies by camel-core -->
    <dependency>
      <groupId>org.apache.camel</groupId>
      <artifactId>spi-annotations</artifactId>
      <version>${project.version}</version>
      <optional>true</optional>
    </dependency>

But is it optional? Seems to be used in some of the core components, so
should be there, right?

-- 
*Christian Posta*
http://www.christianposta.com/blog
twitter: @christianposta

Re: spi-annotations

Posted by Willem jiang <wi...@gmail.com>.
cool, it sounds good.
I will double check the change later today.


--  
Willem Jiang

Red Hat, Inc.
Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
          http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
Twitter: willemjiang  
Weibo: 姜宁willem





On Tuesday, August 27, 2013 at 7:01 PM, Claus Ibsen wrote:

> Hi
>  
> The shading seems to work fine. I have committed a change to master.
>  
> On Tue, Aug 27, 2013 at 12:34 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
> > Hi
> >  
> > Logged a ticket
> > https://issues.apache.org/jira/browse/CAMEL-6673
> >  
> > Looks like shading works nicely. I will give it a test spin before
> > committing any changes. But the .class files get included in
> > camel-core and available for everybody now.
> >  
> > On Tue, Aug 27, 2013 at 12:26 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
> > > Hi
> > >  
> > > I wonder if we can shade spi-annotations into the camel-core module,
> > > so its included out of the box?
> > > As they are needed at runtime, for example by components extending
> > > UriEndpointComponent etc.
> > >  
> > > If not we should IMHO have it as required dependency and would need
> > > for it to be an OSGi bundle, and added to the features.xml so its
> > > installed in OSGi also.
> > >  
> > >  
> > > On Sat, Aug 17, 2013 at 8:42 PM, Christian Posta
> > > <christian.posta@gmail.com (mailto:christian.posta@gmail.com)> wrote:
> > > > Sounds good. I will give it another try with Java 7 and make sure
> > > > appropriate profiles get enabled.
> > > >  
> > > > Thanks Babak!
> > > >  
> > > > On Saturday, August 17, 2013, Babak Vahdat wrote:
> > > >  
> > > > > Aha now I see, well if you make use of Java 7 and IntelliJ can't handle
> > > > > this
> > > > > then that sounds like a IntelliJ bug to me because in that case the apt
> > > > > profile IS enabled and IntelliJ should take the apt module dependency into
> > > > > account like any other POM dependencies. There was also a user reporting
> > > > > the
> > > > > same problem with IntelliJ. Using the maven-idea-plugin instead of
> > > > > IntelliJ's own "import" functionality solved the problem for him:
> > > > >  
> > > > >  
> > > > > http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html
> > > > >  
> > > > > And that's also what we've got on the Wiki as well:
> > > > >  
> > > > > http://camel.apache.org/building.html#Building-UsinganIDE
> > > > >  
> > > > > That all said I think by making this dependency as optional, James original
> > > > > idea was to NOT bump this dependency transitively to the POM of all those
> > > > > Camel component, data format writers out there as the usage of this new
> > > > > feature should be understood as "optional" so people should not get that
> > > > > transitively but explicitly through their own POMs:
> > > > >  
> > > > > http://camel.apache.org/endpoint-annotations.html
> > > > >  
> > > > > I hope James will comment on this thread if I'm wrong :)
> > > > >  
> > > > > Babak
> > > > >  
> > > > >  
> > > > > ceposta wrote
> > > > > > Very interesting. That sounds like lots of headaches, so keeping optional
> > > > > > is fine if it solves that.
> > > > > > I was just noticing in Intellij that it couldn't compile camel-sql
> > > > >  
> > > > >  
> > > > > because
> > > > > > it didn't bring in that dependency since it was marked optional. But
> > > > > > that's
> > > > > > an easy headache to fix compared to the ones you mention :)
> > > > > >  
> > > > > >  
> > > > > > On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
> > > > > > &lt;
> > > > >  
> > > > >  
> > > > >  
> > > > > > babak.vahdat@
> > > > >  
> > > > > > &gt;wrote:
> > > > > >  
> > > > > > > Hi Christian,
> > > > > > >  
> > > > > > > I think having the optional flag set to true is indeed good as we used
> > > > > to
> > > > > > > have problems to build & run the tests using Java 6 profile on the
> > > > > > > CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
> > > > > > >  
> > > > > > > https://github.com/apache/camel/blob/master/components/pom.xml#L221
> > > > > > >  
> > > > > > > Also note that the apt module by itself brings a transitive dependency
> > > > > to
> > > > > > > spi-annotations:
> > > > > > >  
> > > > > > > https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
> > > > > > >  
> > > > > > > So I guess removing that optional flag would cause the same problems
> > > > > > > again,
> > > > > > > see also this thread:
> > > > > >  
> > > > >  
> > > > >  
> > > > > http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
> > > > > > >  
> > > > > > > There's also another ODD issue we're facing with our Jenkins builds but
> > > > > > > unfortunately it's still not resolved, causing a lot of yellow/red
> > > > > > > bubbles
> > > > > > > by our profiles as well as other Apache projects:
> > > > > > >  
> > > > > > > https://issues.apache.org/jira/browse/INFRA-6218
> > > > > > >  
> > > > > > > Which is another story...
> > > > > > >  
> > > > > > > Babak
> > > > > > >  
> > > > > > >  
> > > > > > > ceposta wrote
> > > > > > > > Apply this for the fix :)
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
> > > > > > > > index cd2f201..7409c90 100755
> > > > > > > > --- a/camel-core/pom.xml
> > > > > > > > +++ b/camel-core/pom.xml
> > > > > > > > @@ -99,7 +99,6 @@
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <groupId>
> > > > > > > > org.apache.camel
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </groupId>
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <artifactId>
> > > > > > > > spi-annotations
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </artifactId>
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <version>
> > > > > > > > ${project.version}
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </version>
> > > > > > > > -
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <optional>
> > > > > > > > true
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </optional>
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </dependency>
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <dependency>
> > > > > > > >  
> > > > > > > > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
> > > > > > > > &lt;
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > > christian.posta@
> > > > > > >  
> > > > > > > > &gt;wrote:
> > > > > > > >  
> > > > > > > > > So in camel-core, the spi-annotations dependency is marked "optional"
> > > > > > > in
> > > > > > > > > the pom.
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > > <dependency>
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <groupId>
> > > > > > > > org.apache.camel
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </groupId>
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <artifactId>
> > > > > > > > spi-annotations
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </artifactId>
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <version>
> > > > > > > > ${project.version}
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </version>
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <optional>
> > > > > > > > true
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </optional>
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </dependency>
> > > > > > > > >  
> > > > > > > > > But is it optional? Seems to be used in some of the core components,
> > > > > > > so
> > > > > > > > > should be there, right?
> > > > > > > > >  
> > > > > > > > > --
> > > > > > > > > *Christian Posta*
> > > > > > > > > http://www.christianposta.com/blog
> > > > > > > > > twitter: @christianposta
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > > --
> > > > > > > > *Christian Posta*
> > > > > > > > http://www.christianposta.com/blog
> > > > > > > > twitter: @christianposta
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > --
> > > > > > > View this message in context:View this message in context:
> > > > > >  
> > > > >  
> > > > >  
> > > > > http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
> > > > > Sent from the Camel Development mailing list archive at Nabble.com (http://Nabble.com).
> > > >  
> > > >  
> > > >  
> > > >  
> > > > --
> > > > *Christian Posta*
> > > > http://www.christianposta.com/blog
> > > > twitter: @christianposta
> > >  
> > >  
> > >  
> > >  
> > >  
> > > --
> > > Claus Ibsen
> > > -----------------
> > > Red Hat, Inc.
> > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> > > Twitter: davsclaus
> > > Blog: http://davsclaus.com
> > > Author of Camel in Action: http://www.manning.com/ibsen
> >  
> >  
> >  
> >  
> >  
> > --
> > Claus Ibsen
> > -----------------
> > Red Hat, Inc.
> > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> > Twitter: davsclaus
> > Blog: http://davsclaus.com
> > Author of Camel in Action: http://www.manning.com/ibsen
>  
>  
>  
>  
>  
> --  
> Claus Ibsen
> -----------------
> Red Hat, Inc.
> Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> Twitter: davsclaus
> Blog: http://davsclaus.com
> Author of Camel in Action: http://www.manning.com/ibsen




Re: spi-annotations

Posted by Claus Ibsen <cl...@gmail.com>.
Okay a bit weird it does that, as there is no instructions in the
pom.xml about that for it.

I would assume we should have

<scope>provided</scope>

For the spi-annotations in the pom.xml so its not on the transitive
list as its embedded and not needed.

On Wed, Aug 28, 2013 at 8:09 AM, Willem jiang <wi...@gmail.com> wrote:
> All the tests except the ones in camel-core were failed.
> We don't need to install the spi-annotations bundle as the classes are shade into camel-core by the bnd plugin.
>
>
> --
> Willem Jiang
>
> Red Hat, Inc.
> Web: http://www.redhat.com
> Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
>           http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
> Twitter: willemjiang
> Weibo: 姜宁willem
>
>
>
>
>
> On Wednesday, August 28, 2013 at 1:41 PM, Claus Ibsen wrote:
>
>> Which tests is failing? That seems odd as the .class is just added to
>> camel-core?
>>
>> We need to find a solution as the JAR must be on the classpath. And
>> for OSGi its not possible as its not an OSGi bundle.
>>
>> On Wed, Aug 28, 2013 at 3:01 AM, Willem jiang <willem.jiang@gmail.com (mailto:willem.jiang@gmail.com)> wrote:
>> > spi-annotations is already shaded into camel-core by bnd plugin, we don't need to use the shaded plugin to do this kind of job.
>> > So I just revert the change for camel-2.12.0 release.
>> >
>> >
>> > --
>> > Willem Jiang
>> >
>> > Red Hat, Inc.
>> > Web: http://www.redhat.com
>> > Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
>> > http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
>> > Twitter: willemjiang
>> > Weibo: 姜宁willem
>> >
>> >
>> >
>> >
>> >
>> > On Wednesday, August 28, 2013 at 8:22 AM, Willem jiang wrote:
>> >
>> > > Lots of tests failed with this change, I'm trying to figure a solution for it now.
>> > > BTW, it is not the good practice to shade the jars with the same package.
>> > >
>> > >
>> > > --
>> > > Willem Jiang
>> > >
>> > > Red Hat, Inc.
>> > > Web: http://www.redhat.com
>> > > Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
>> > > http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
>> > > Twitter: willemjiang
>> > > Weibo: 姜宁willem
>> > >
>> > >
>> > >
>> > >
>> > >
>> > > On Tuesday, August 27, 2013 at 7:01 PM, Claus Ibsen wrote:
>> > >
>> > > > Hi
>> > > >
>> > > > The shading seems to work fine. I have committed a change to master.
>> > > >
>> > > > On Tue, Aug 27, 2013 at 12:34 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
>> > > > > Hi
>> > > > >
>> > > > > Logged a ticket
>> > > > > https://issues.apache.org/jira/browse/CAMEL-6673
>> > > > >
>> > > > > Looks like shading works nicely. I will give it a test spin before
>> > > > > committing any changes. But the .class files get included in
>> > > > > camel-core and available for everybody now.
>> > > > >
>> > > > > On Tue, Aug 27, 2013 at 12:26 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
>> > > > > > Hi
>> > > > > >
>> > > > > > I wonder if we can shade spi-annotations into the camel-core module,
>> > > > > > so its included out of the box?
>> > > > > > As they are needed at runtime, for example by components extending
>> > > > > > UriEndpointComponent etc.
>> > > > > >
>> > > > > > If not we should IMHO have it as required dependency and would need
>> > > > > > for it to be an OSGi bundle, and added to the features.xml so its
>> > > > > > installed in OSGi also.
>> > > > > >
>> > > > > >
>> > > > > > On Sat, Aug 17, 2013 at 8:42 PM, Christian Posta
>> > > > > > <christian.posta@gmail.com (mailto:christian.posta@gmail.com)> wrote:
>> > > > > > > Sounds good. I will give it another try with Java 7 and make sure
>> > > > > > > appropriate profiles get enabled.
>> > > > > > >
>> > > > > > > Thanks Babak!
>> > > > > > >
>> > > > > > > On Saturday, August 17, 2013, Babak Vahdat wrote:
>> > > > > > >
>> > > > > > > > Aha now I see, well if you make use of Java 7 and IntelliJ can't handle
>> > > > > > > > this
>> > > > > > > > then that sounds like a IntelliJ bug to me because in that case the apt
>> > > > > > > > profile IS enabled and IntelliJ should take the apt module dependency into
>> > > > > > > > account like any other POM dependencies. There was also a user reporting
>> > > > > > > > the
>> > > > > > > > same problem with IntelliJ. Using the maven-idea-plugin instead of
>> > > > > > > > IntelliJ's own "import" functionality solved the problem for him:
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html
>> > > > > > > >
>> > > > > > > > And that's also what we've got on the Wiki as well:
>> > > > > > > >
>> > > > > > > > http://camel.apache.org/building.html#Building-UsinganIDE
>> > > > > > > >
>> > > > > > > > That all said I think by making this dependency as optional, James original
>> > > > > > > > idea was to NOT bump this dependency transitively to the POM of all those
>> > > > > > > > Camel component, data format writers out there as the usage of this new
>> > > > > > > > feature should be understood as "optional" so people should not get that
>> > > > > > > > transitively but explicitly through their own POMs:
>> > > > > > > >
>> > > > > > > > http://camel.apache.org/endpoint-annotations.html
>> > > > > > > >
>> > > > > > > > I hope James will comment on this thread if I'm wrong :)
>> > > > > > > >
>> > > > > > > > Babak
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > ceposta wrote
>> > > > > > > > > Very interesting. That sounds like lots of headaches, so keeping optional
>> > > > > > > > > is fine if it solves that.
>> > > > > > > > > I was just noticing in Intellij that it couldn't compile camel-sql
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > because
>> > > > > > > > > it didn't bring in that dependency since it was marked optional. But
>> > > > > > > > > that's
>> > > > > > > > > an easy headache to fix compared to the ones you mention :)
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
>> > > > > > > > > &lt;
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > > babak.vahdat@
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > > &gt;wrote:
>> > > > > > > > >
>> > > > > > > > > > Hi Christian,
>> > > > > > > > > >
>> > > > > > > > > > I think having the optional flag set to true is indeed good as we used
>> > > > > > > >
>> > > > > > > > to
>> > > > > > > > > > have problems to build & run the tests using Java 6 profile on the
>> > > > > > > > > > CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
>> > > > > > > > > >
>> > > > > > > > > > https://github.com/apache/camel/blob/master/components/pom.xml#L221
>> > > > > > > > > >
>> > > > > > > > > > Also note that the apt module by itself brings a transitive dependency
>> > > > > > > >
>> > > > > > > > to
>> > > > > > > > > > spi-annotations:
>> > > > > > > > > >
>> > > > > > > > > > https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
>> > > > > > > > > >
>> > > > > > > > > > So I guess removing that optional flag would cause the same problems
>> > > > > > > > > > again,
>> > > > > > > > > > see also this thread:
>> > > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
>> > > > > > > > > >
>> > > > > > > > > > There's also another ODD issue we're facing with our Jenkins builds but
>> > > > > > > > > > unfortunately it's still not resolved, causing a lot of yellow/red
>> > > > > > > > > > bubbles
>> > > > > > > > > > by our profiles as well as other Apache projects:
>> > > > > > > > > >
>> > > > > > > > > > https://issues.apache.org/jira/browse/INFRA-6218
>> > > > > > > > > >
>> > > > > > > > > > Which is another story...
>> > > > > > > > > >
>> > > > > > > > > > Babak
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > > ceposta wrote
>> > > > > > > > > > > Apply this for the fix :)
>> > > > > > > > > > >
>> > > > > > > > > > >
>> > > > > > > > > > >
>> > > > > > > > > > > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
>> > > > > > > > > > > index cd2f201..7409c90 100755
>> > > > > > > > > > > --- a/camel-core/pom.xml
>> > > > > > > > > > > +++ b/camel-core/pom.xml
>> > > > > > > > > > > @@ -99,7 +99,6 @@
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > <groupId>
>> > > > > > > > > > > org.apache.camel
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > </groupId>
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > <artifactId>
>> > > > > > > > > > > spi-annotations
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > </artifactId>
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > <version>
>> > > > > > > > > > > ${project.version}
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > </version>
>> > > > > > > > > > > -
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > <optional>
>> > > > > > > > > > > true
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > </optional>
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > </dependency>
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > <dependency>
>> > > > > > > > > > >
>> > > > > > > > > > > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
>> > > > > > > > > > > &lt;
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > > > christian.posta@
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > > > &gt;wrote:
>> > > > > > > > > > >
>> > > > > > > > > > > > So in camel-core, the spi-annotations dependency is marked "optional"
>> > > > > > > > > >
>> > > > > > > > > > in
>> > > > > > > > > > > > the pom.
>> > > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > <dependency>
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > <groupId>
>> > > > > > > > > > > org.apache.camel
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > </groupId>
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > <artifactId>
>> > > > > > > > > > > spi-annotations
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > </artifactId>
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > <version>
>> > > > > > > > > > > ${project.version}
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > </version>
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > <optional>
>> > > > > > > > > > > true
>> > > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > </optional>
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > </dependency>
>> > > > > > > > > > > >
>> > > > > > > > > > > > But is it optional? Seems to be used in some of the core components,
>> > > > > > > > > >
>> > > > > > > > > > so
>> > > > > > > > > > > > should be there, right?
>> > > > > > > > > > > >
>> > > > > > > > > > > > --
>> > > > > > > > > > > > *Christian Posta*
>> > > > > > > > > > > > http://www.christianposta.com/blog
>> > > > > > > > > > > > twitter: @christianposta
>> > > > > > > > > > >
>> > > > > > > > > > >
>> > > > > > > > > > >
>> > > > > > > > > > >
>> > > > > > > > > > >
>> > > > > > > > > > >
>> > > > > > > > > > >
>> > > > > > > > > > >
>> > > > > > > > > > >
>> > > > > > > > > > > --
>> > > > > > > > > > > *Christian Posta*
>> > > > > > > > > > > http://www.christianposta.com/blog
>> > > > > > > > > > > twitter: @christianposta
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > >
>> > > > > > > > > > --
>> > > > > > > > > > View this message in context:View this message in context:
>> > > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
>> > > > > > > > Sent from the Camel Development mailing list archive at Nabble.com (http://Nabble.com).
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > --
>> > > > > > > *Christian Posta*
>> > > > > > > http://www.christianposta.com/blog
>> > > > > > > twitter: @christianposta
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > > --
>> > > > > > Claus Ibsen
>> > > > > > -----------------
>> > > > > > Red Hat, Inc.
>> > > > > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
>> > > > > > Twitter: davsclaus
>> > > > > > Blog: http://davsclaus.com
>> > > > > > Author of Camel in Action: http://www.manning.com/ibsen
>> > > > >
>> > > > >
>> > > > >
>> > > > >
>> > > > >
>> > > > >
>> > > > >
>> > > > >
>> > > > >
>> > > > > --
>> > > > > Claus Ibsen
>> > > > > -----------------
>> > > > > Red Hat, Inc.
>> > > > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
>> > > > > Twitter: davsclaus
>> > > > > Blog: http://davsclaus.com
>> > > > > Author of Camel in Action: http://www.manning.com/ibsen
>> > > >
>> > > >
>> > > >
>> > > >
>> > > >
>> > > >
>> > > >
>> > > >
>> > > >
>> > > > --
>> > > > Claus Ibsen
>> > > > -----------------
>> > > > Red Hat, Inc.
>> > > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
>> > > > Twitter: davsclaus
>> > > > Blog: http://davsclaus.com
>> > > > Author of Camel in Action: http://www.manning.com/ibsen
>> > >
>> >
>>
>>
>>
>>
>>
>> --
>> Claus Ibsen
>> -----------------
>> Red Hat, Inc.
>> Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
>> Twitter: davsclaus
>> Blog: http://davsclaus.com
>> Author of Camel in Action: http://www.manning.com/ibsen
>
>
>



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: spi-annotations

Posted by Willem jiang <wi...@gmail.com>.
All the tests except the ones in camel-core were failed.
We don't need to install the spi-annotations bundle as the classes are shade into camel-core by the bnd plugin.


--  
Willem Jiang

Red Hat, Inc.
Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
          http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
Twitter: willemjiang  
Weibo: 姜宁willem





On Wednesday, August 28, 2013 at 1:41 PM, Claus Ibsen wrote:

> Which tests is failing? That seems odd as the .class is just added to
> camel-core?
>  
> We need to find a solution as the JAR must be on the classpath. And
> for OSGi its not possible as its not an OSGi bundle.
>  
> On Wed, Aug 28, 2013 at 3:01 AM, Willem jiang <willem.jiang@gmail.com (mailto:willem.jiang@gmail.com)> wrote:
> > spi-annotations is already shaded into camel-core by bnd plugin, we don't need to use the shaded plugin to do this kind of job.
> > So I just revert the change for camel-2.12.0 release.
> >  
> >  
> > --
> > Willem Jiang
> >  
> > Red Hat, Inc.
> > Web: http://www.redhat.com
> > Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
> > http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
> > Twitter: willemjiang
> > Weibo: 姜宁willem
> >  
> >  
> >  
> >  
> >  
> > On Wednesday, August 28, 2013 at 8:22 AM, Willem jiang wrote:
> >  
> > > Lots of tests failed with this change, I'm trying to figure a solution for it now.
> > > BTW, it is not the good practice to shade the jars with the same package.
> > >  
> > >  
> > > --
> > > Willem Jiang
> > >  
> > > Red Hat, Inc.
> > > Web: http://www.redhat.com
> > > Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
> > > http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
> > > Twitter: willemjiang
> > > Weibo: 姜宁willem
> > >  
> > >  
> > >  
> > >  
> > >  
> > > On Tuesday, August 27, 2013 at 7:01 PM, Claus Ibsen wrote:
> > >  
> > > > Hi
> > > >  
> > > > The shading seems to work fine. I have committed a change to master.
> > > >  
> > > > On Tue, Aug 27, 2013 at 12:34 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
> > > > > Hi
> > > > >  
> > > > > Logged a ticket
> > > > > https://issues.apache.org/jira/browse/CAMEL-6673
> > > > >  
> > > > > Looks like shading works nicely. I will give it a test spin before
> > > > > committing any changes. But the .class files get included in
> > > > > camel-core and available for everybody now.
> > > > >  
> > > > > On Tue, Aug 27, 2013 at 12:26 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
> > > > > > Hi
> > > > > >  
> > > > > > I wonder if we can shade spi-annotations into the camel-core module,
> > > > > > so its included out of the box?
> > > > > > As they are needed at runtime, for example by components extending
> > > > > > UriEndpointComponent etc.
> > > > > >  
> > > > > > If not we should IMHO have it as required dependency and would need
> > > > > > for it to be an OSGi bundle, and added to the features.xml so its
> > > > > > installed in OSGi also.
> > > > > >  
> > > > > >  
> > > > > > On Sat, Aug 17, 2013 at 8:42 PM, Christian Posta
> > > > > > <christian.posta@gmail.com (mailto:christian.posta@gmail.com)> wrote:
> > > > > > > Sounds good. I will give it another try with Java 7 and make sure
> > > > > > > appropriate profiles get enabled.
> > > > > > >  
> > > > > > > Thanks Babak!
> > > > > > >  
> > > > > > > On Saturday, August 17, 2013, Babak Vahdat wrote:
> > > > > > >  
> > > > > > > > Aha now I see, well if you make use of Java 7 and IntelliJ can't handle
> > > > > > > > this
> > > > > > > > then that sounds like a IntelliJ bug to me because in that case the apt
> > > > > > > > profile IS enabled and IntelliJ should take the apt module dependency into
> > > > > > > > account like any other POM dependencies. There was also a user reporting
> > > > > > > > the
> > > > > > > > same problem with IntelliJ. Using the maven-idea-plugin instead of
> > > > > > > > IntelliJ's own "import" functionality solved the problem for him:
> > > > > > > >  
> > > > > > > >  
> > > > > > > > http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html
> > > > > > > >  
> > > > > > > > And that's also what we've got on the Wiki as well:
> > > > > > > >  
> > > > > > > > http://camel.apache.org/building.html#Building-UsinganIDE
> > > > > > > >  
> > > > > > > > That all said I think by making this dependency as optional, James original
> > > > > > > > idea was to NOT bump this dependency transitively to the POM of all those
> > > > > > > > Camel component, data format writers out there as the usage of this new
> > > > > > > > feature should be understood as "optional" so people should not get that
> > > > > > > > transitively but explicitly through their own POMs:
> > > > > > > >  
> > > > > > > > http://camel.apache.org/endpoint-annotations.html
> > > > > > > >  
> > > > > > > > I hope James will comment on this thread if I'm wrong :)
> > > > > > > >  
> > > > > > > > Babak
> > > > > > > >  
> > > > > > > >  
> > > > > > > > ceposta wrote
> > > > > > > > > Very interesting. That sounds like lots of headaches, so keeping optional
> > > > > > > > > is fine if it solves that.
> > > > > > > > > I was just noticing in Intellij that it couldn't compile camel-sql
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > > because
> > > > > > > > > it didn't bring in that dependency since it was marked optional. But
> > > > > > > > > that's
> > > > > > > > > an easy headache to fix compared to the ones you mention :)
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
> > > > > > > > > &lt;
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > > > babak.vahdat@
> > > > > > > >  
> > > > > > > >  
> > > > > > > > > &gt;wrote:
> > > > > > > > >  
> > > > > > > > > > Hi Christian,
> > > > > > > > > >  
> > > > > > > > > > I think having the optional flag set to true is indeed good as we used
> > > > > > > >  
> > > > > > > > to
> > > > > > > > > > have problems to build & run the tests using Java 6 profile on the
> > > > > > > > > > CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
> > > > > > > > > >  
> > > > > > > > > > https://github.com/apache/camel/blob/master/components/pom.xml#L221
> > > > > > > > > >  
> > > > > > > > > > Also note that the apt module by itself brings a transitive dependency
> > > > > > > >  
> > > > > > > > to
> > > > > > > > > > spi-annotations:
> > > > > > > > > >  
> > > > > > > > > > https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
> > > > > > > > > >  
> > > > > > > > > > So I guess removing that optional flag would cause the same problems
> > > > > > > > > > again,
> > > > > > > > > > see also this thread:
> > > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > > http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
> > > > > > > > > >  
> > > > > > > > > > There's also another ODD issue we're facing with our Jenkins builds but
> > > > > > > > > > unfortunately it's still not resolved, causing a lot of yellow/red
> > > > > > > > > > bubbles
> > > > > > > > > > by our profiles as well as other Apache projects:
> > > > > > > > > >  
> > > > > > > > > > https://issues.apache.org/jira/browse/INFRA-6218
> > > > > > > > > >  
> > > > > > > > > > Which is another story...
> > > > > > > > > >  
> > > > > > > > > > Babak
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > > ceposta wrote
> > > > > > > > > > > Apply this for the fix :)
> > > > > > > > > > >  
> > > > > > > > > > >  
> > > > > > > > > > >  
> > > > > > > > > > > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
> > > > > > > > > > > index cd2f201..7409c90 100755
> > > > > > > > > > > --- a/camel-core/pom.xml
> > > > > > > > > > > +++ b/camel-core/pom.xml
> > > > > > > > > > > @@ -99,7 +99,6 @@
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > <groupId>
> > > > > > > > > > > org.apache.camel
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > </groupId>
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > <artifactId>
> > > > > > > > > > > spi-annotations
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > </artifactId>
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > <version>
> > > > > > > > > > > ${project.version}
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > </version>
> > > > > > > > > > > -
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > <optional>
> > > > > > > > > > > true
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > </optional>
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > </dependency>
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > <dependency>
> > > > > > > > > > >  
> > > > > > > > > > > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
> > > > > > > > > > > &lt;
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > > > christian.posta@
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > > > &gt;wrote:
> > > > > > > > > > >  
> > > > > > > > > > > > So in camel-core, the spi-annotations dependency is marked "optional"
> > > > > > > > > >  
> > > > > > > > > > in
> > > > > > > > > > > > the pom.
> > > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > <dependency>
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > <groupId>
> > > > > > > > > > > org.apache.camel
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > </groupId>
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > <artifactId>
> > > > > > > > > > > spi-annotations
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > </artifactId>
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > <version>
> > > > > > > > > > > ${project.version}
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > </version>
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > <optional>
> > > > > > > > > > > true
> > > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > </optional>
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > </dependency>
> > > > > > > > > > > >  
> > > > > > > > > > > > But is it optional? Seems to be used in some of the core components,
> > > > > > > > > >  
> > > > > > > > > > so
> > > > > > > > > > > > should be there, right?
> > > > > > > > > > > >  
> > > > > > > > > > > > --
> > > > > > > > > > > > *Christian Posta*
> > > > > > > > > > > > http://www.christianposta.com/blog
> > > > > > > > > > > > twitter: @christianposta
> > > > > > > > > > >  
> > > > > > > > > > >  
> > > > > > > > > > >  
> > > > > > > > > > >  
> > > > > > > > > > >  
> > > > > > > > > > >  
> > > > > > > > > > >  
> > > > > > > > > > >  
> > > > > > > > > > >  
> > > > > > > > > > > --
> > > > > > > > > > > *Christian Posta*
> > > > > > > > > > > http://www.christianposta.com/blog
> > > > > > > > > > > twitter: @christianposta
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > >  
> > > > > > > > > > --
> > > > > > > > > > View this message in context:View this message in context:
> > > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > > http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
> > > > > > > > Sent from the Camel Development mailing list archive at Nabble.com (http://Nabble.com).
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > --
> > > > > > > *Christian Posta*
> > > > > > > http://www.christianposta.com/blog
> > > > > > > twitter: @christianposta
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > > --
> > > > > > Claus Ibsen
> > > > > > -----------------
> > > > > > Red Hat, Inc.
> > > > > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> > > > > > Twitter: davsclaus
> > > > > > Blog: http://davsclaus.com
> > > > > > Author of Camel in Action: http://www.manning.com/ibsen
> > > > >  
> > > > >  
> > > > >  
> > > > >  
> > > > >  
> > > > >  
> > > > >  
> > > > >  
> > > > >  
> > > > > --
> > > > > Claus Ibsen
> > > > > -----------------
> > > > > Red Hat, Inc.
> > > > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> > > > > Twitter: davsclaus
> > > > > Blog: http://davsclaus.com
> > > > > Author of Camel in Action: http://www.manning.com/ibsen
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > > --
> > > > Claus Ibsen
> > > > -----------------
> > > > Red Hat, Inc.
> > > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> > > > Twitter: davsclaus
> > > > Blog: http://davsclaus.com
> > > > Author of Camel in Action: http://www.manning.com/ibsen
> > >  
> >  
>  
>  
>  
>  
>  
> --  
> Claus Ibsen
> -----------------
> Red Hat, Inc.
> Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> Twitter: davsclaus
> Blog: http://davsclaus.com
> Author of Camel in Action: http://www.manning.com/ibsen




Re: spi-annotations

Posted by Claus Ibsen <cl...@gmail.com>.
Which tests is failing? That seems odd as the .class is just added to
camel-core?

We need to find a solution as the JAR must be on the classpath. And
for OSGi its not possible as its not an OSGi bundle.

On Wed, Aug 28, 2013 at 3:01 AM, Willem jiang <wi...@gmail.com> wrote:
> spi-annotations is already shaded into camel-core by bnd plugin, we don't need to use the shaded plugin to do this kind of job.
> So I just revert the change for camel-2.12.0 release.
>
>
> --
> Willem Jiang
>
> Red Hat, Inc.
> Web: http://www.redhat.com
> Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
>           http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
> Twitter: willemjiang
> Weibo: 姜宁willem
>
>
>
>
>
> On Wednesday, August 28, 2013 at 8:22 AM, Willem jiang wrote:
>
>> Lots of tests failed with this change, I'm trying to figure a solution for it now.
>> BTW, it is not the good practice to shade the jars with the same package.
>>
>>
>> --
>> Willem Jiang
>>
>> Red Hat, Inc.
>> Web: http://www.redhat.com
>> Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
>> http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
>> Twitter: willemjiang
>> Weibo: 姜宁willem
>>
>>
>>
>>
>>
>> On Tuesday, August 27, 2013 at 7:01 PM, Claus Ibsen wrote:
>>
>> > Hi
>> >
>> > The shading seems to work fine. I have committed a change to master.
>> >
>> > On Tue, Aug 27, 2013 at 12:34 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
>> > > Hi
>> > >
>> > > Logged a ticket
>> > > https://issues.apache.org/jira/browse/CAMEL-6673
>> > >
>> > > Looks like shading works nicely. I will give it a test spin before
>> > > committing any changes. But the .class files get included in
>> > > camel-core and available for everybody now.
>> > >
>> > > On Tue, Aug 27, 2013 at 12:26 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
>> > > > Hi
>> > > >
>> > > > I wonder if we can shade spi-annotations into the camel-core module,
>> > > > so its included out of the box?
>> > > > As they are needed at runtime, for example by components extending
>> > > > UriEndpointComponent etc.
>> > > >
>> > > > If not we should IMHO have it as required dependency and would need
>> > > > for it to be an OSGi bundle, and added to the features.xml so its
>> > > > installed in OSGi also.
>> > > >
>> > > >
>> > > > On Sat, Aug 17, 2013 at 8:42 PM, Christian Posta
>> > > > <christian.posta@gmail.com (mailto:christian.posta@gmail.com)> wrote:
>> > > > > Sounds good. I will give it another try with Java 7 and make sure
>> > > > > appropriate profiles get enabled.
>> > > > >
>> > > > > Thanks Babak!
>> > > > >
>> > > > > On Saturday, August 17, 2013, Babak Vahdat wrote:
>> > > > >
>> > > > > > Aha now I see, well if you make use of Java 7 and IntelliJ can't handle
>> > > > > > this
>> > > > > > then that sounds like a IntelliJ bug to me because in that case the apt
>> > > > > > profile IS enabled and IntelliJ should take the apt module dependency into
>> > > > > > account like any other POM dependencies. There was also a user reporting
>> > > > > > the
>> > > > > > same problem with IntelliJ. Using the maven-idea-plugin instead of
>> > > > > > IntelliJ's own "import" functionality solved the problem for him:
>> > > > > >
>> > > > > >
>> > > > > > http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html
>> > > > > >
>> > > > > > And that's also what we've got on the Wiki as well:
>> > > > > >
>> > > > > > http://camel.apache.org/building.html#Building-UsinganIDE
>> > > > > >
>> > > > > > That all said I think by making this dependency as optional, James original
>> > > > > > idea was to NOT bump this dependency transitively to the POM of all those
>> > > > > > Camel component, data format writers out there as the usage of this new
>> > > > > > feature should be understood as "optional" so people should not get that
>> > > > > > transitively but explicitly through their own POMs:
>> > > > > >
>> > > > > > http://camel.apache.org/endpoint-annotations.html
>> > > > > >
>> > > > > > I hope James will comment on this thread if I'm wrong :)
>> > > > > >
>> > > > > > Babak
>> > > > > >
>> > > > > >
>> > > > > > ceposta wrote
>> > > > > > > Very interesting. That sounds like lots of headaches, so keeping optional
>> > > > > > > is fine if it solves that.
>> > > > > > > I was just noticing in Intellij that it couldn't compile camel-sql
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > > because
>> > > > > > > it didn't bring in that dependency since it was marked optional. But
>> > > > > > > that's
>> > > > > > > an easy headache to fix compared to the ones you mention :)
>> > > > > > >
>> > > > > > >
>> > > > > > > On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
>> > > > > > > &lt;
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > > > babak.vahdat@
>> > > > > >
>> > > > > >
>> > > > > > > &gt;wrote:
>> > > > > > >
>> > > > > > > > Hi Christian,
>> > > > > > > >
>> > > > > > > > I think having the optional flag set to true is indeed good as we used
>> > > > > >
>> > > > > > to
>> > > > > > > > have problems to build & run the tests using Java 6 profile on the
>> > > > > > > > CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
>> > > > > > > >
>> > > > > > > > https://github.com/apache/camel/blob/master/components/pom.xml#L221
>> > > > > > > >
>> > > > > > > > Also note that the apt module by itself brings a transitive dependency
>> > > > > >
>> > > > > > to
>> > > > > > > > spi-annotations:
>> > > > > > > >
>> > > > > > > > https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
>> > > > > > > >
>> > > > > > > > So I guess removing that optional flag would cause the same problems
>> > > > > > > > again,
>> > > > > > > > see also this thread:
>> > > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > > http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
>> > > > > > > >
>> > > > > > > > There's also another ODD issue we're facing with our Jenkins builds but
>> > > > > > > > unfortunately it's still not resolved, causing a lot of yellow/red
>> > > > > > > > bubbles
>> > > > > > > > by our profiles as well as other Apache projects:
>> > > > > > > >
>> > > > > > > > https://issues.apache.org/jira/browse/INFRA-6218
>> > > > > > > >
>> > > > > > > > Which is another story...
>> > > > > > > >
>> > > > > > > > Babak
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > ceposta wrote
>> > > > > > > > > Apply this for the fix :)
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
>> > > > > > > > > index cd2f201..7409c90 100755
>> > > > > > > > > --- a/camel-core/pom.xml
>> > > > > > > > > +++ b/camel-core/pom.xml
>> > > > > > > > > @@ -99,7 +99,6 @@
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > <groupId>
>> > > > > > > > > org.apache.camel
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > </groupId>
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > <artifactId>
>> > > > > > > > > spi-annotations
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > </artifactId>
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > <version>
>> > > > > > > > > ${project.version}
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > </version>
>> > > > > > > > > -
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > <optional>
>> > > > > > > > > true
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > </optional>
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > </dependency>
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > <dependency>
>> > > > > > > > >
>> > > > > > > > > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
>> > > > > > > > > &lt;
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > > christian.posta@
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > > &gt;wrote:
>> > > > > > > > >
>> > > > > > > > > > So in camel-core, the spi-annotations dependency is marked "optional"
>> > > > > > > >
>> > > > > > > > in
>> > > > > > > > > > the pom.
>> > > > > > > > >
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > <dependency>
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > <groupId>
>> > > > > > > > > org.apache.camel
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > </groupId>
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > <artifactId>
>> > > > > > > > > spi-annotations
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > </artifactId>
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > <version>
>> > > > > > > > > ${project.version}
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > </version>
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > <optional>
>> > > > > > > > > true
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > </optional>
>> > > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > >
>> > > > > > > </dependency>
>> > > > > > > > > >
>> > > > > > > > > > But is it optional? Seems to be used in some of the core components,
>> > > > > > > >
>> > > > > > > > so
>> > > > > > > > > > should be there, right?
>> > > > > > > > > >
>> > > > > > > > > > --
>> > > > > > > > > > *Christian Posta*
>> > > > > > > > > > http://www.christianposta.com/blog
>> > > > > > > > > > twitter: @christianposta
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > >
>> > > > > > > > > --
>> > > > > > > > > *Christian Posta*
>> > > > > > > > > http://www.christianposta.com/blog
>> > > > > > > > > twitter: @christianposta
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > >
>> > > > > > > > --
>> > > > > > > > View this message in context:View this message in context:
>> > > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > >
>> > > > > > http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
>> > > > > > Sent from the Camel Development mailing list archive at Nabble.com (http://Nabble.com).
>> > > > >
>> > > > >
>> > > > >
>> > > > >
>> > > > >
>> > > > >
>> > > > > --
>> > > > > *Christian Posta*
>> > > > > http://www.christianposta.com/blog
>> > > > > twitter: @christianposta
>> > > >
>> > > >
>> > > >
>> > > >
>> > > >
>> > > >
>> > > >
>> > > > --
>> > > > Claus Ibsen
>> > > > -----------------
>> > > > Red Hat, Inc.
>> > > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
>> > > > Twitter: davsclaus
>> > > > Blog: http://davsclaus.com
>> > > > Author of Camel in Action: http://www.manning.com/ibsen
>> > >
>> > >
>> > >
>> > >
>> > >
>> > >
>> > >
>> > > --
>> > > Claus Ibsen
>> > > -----------------
>> > > Red Hat, Inc.
>> > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
>> > > Twitter: davsclaus
>> > > Blog: http://davsclaus.com
>> > > Author of Camel in Action: http://www.manning.com/ibsen
>> >
>> >
>> >
>> >
>> >
>> >
>> >
>> > --
>> > Claus Ibsen
>> > -----------------
>> > Red Hat, Inc.
>> > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
>> > Twitter: davsclaus
>> > Blog: http://davsclaus.com
>> > Author of Camel in Action: http://www.manning.com/ibsen
>>
>
>
>



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: spi-annotations

Posted by Willem jiang <wi...@gmail.com>.
spi-annotations is already shaded into camel-core by bnd plugin, we don't need to use the shaded plugin to do this kind of job.
So I just revert the change for camel-2.12.0 release.


--  
Willem Jiang

Red Hat, Inc.
Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
          http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
Twitter: willemjiang  
Weibo: 姜宁willem





On Wednesday, August 28, 2013 at 8:22 AM, Willem jiang wrote:

> Lots of tests failed with this change, I'm trying to figure a solution for it now.
> BTW, it is not the good practice to shade the jars with the same package.
>  
>  
> --  
> Willem Jiang
>  
> Red Hat, Inc.
> Web: http://www.redhat.com
> Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
> http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
> Twitter: willemjiang  
> Weibo: 姜宁willem
>  
>  
>  
>  
>  
> On Tuesday, August 27, 2013 at 7:01 PM, Claus Ibsen wrote:
>  
> > Hi
> >  
> > The shading seems to work fine. I have committed a change to master.
> >  
> > On Tue, Aug 27, 2013 at 12:34 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
> > > Hi
> > >  
> > > Logged a ticket
> > > https://issues.apache.org/jira/browse/CAMEL-6673
> > >  
> > > Looks like shading works nicely. I will give it a test spin before
> > > committing any changes. But the .class files get included in
> > > camel-core and available for everybody now.
> > >  
> > > On Tue, Aug 27, 2013 at 12:26 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
> > > > Hi
> > > >  
> > > > I wonder if we can shade spi-annotations into the camel-core module,
> > > > so its included out of the box?
> > > > As they are needed at runtime, for example by components extending
> > > > UriEndpointComponent etc.
> > > >  
> > > > If not we should IMHO have it as required dependency and would need
> > > > for it to be an OSGi bundle, and added to the features.xml so its
> > > > installed in OSGi also.
> > > >  
> > > >  
> > > > On Sat, Aug 17, 2013 at 8:42 PM, Christian Posta
> > > > <christian.posta@gmail.com (mailto:christian.posta@gmail.com)> wrote:
> > > > > Sounds good. I will give it another try with Java 7 and make sure
> > > > > appropriate profiles get enabled.
> > > > >  
> > > > > Thanks Babak!
> > > > >  
> > > > > On Saturday, August 17, 2013, Babak Vahdat wrote:
> > > > >  
> > > > > > Aha now I see, well if you make use of Java 7 and IntelliJ can't handle
> > > > > > this
> > > > > > then that sounds like a IntelliJ bug to me because in that case the apt
> > > > > > profile IS enabled and IntelliJ should take the apt module dependency into
> > > > > > account like any other POM dependencies. There was also a user reporting
> > > > > > the
> > > > > > same problem with IntelliJ. Using the maven-idea-plugin instead of
> > > > > > IntelliJ's own "import" functionality solved the problem for him:
> > > > > >  
> > > > > >  
> > > > > > http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html
> > > > > >  
> > > > > > And that's also what we've got on the Wiki as well:
> > > > > >  
> > > > > > http://camel.apache.org/building.html#Building-UsinganIDE
> > > > > >  
> > > > > > That all said I think by making this dependency as optional, James original
> > > > > > idea was to NOT bump this dependency transitively to the POM of all those
> > > > > > Camel component, data format writers out there as the usage of this new
> > > > > > feature should be understood as "optional" so people should not get that
> > > > > > transitively but explicitly through their own POMs:
> > > > > >  
> > > > > > http://camel.apache.org/endpoint-annotations.html
> > > > > >  
> > > > > > I hope James will comment on this thread if I'm wrong :)
> > > > > >  
> > > > > > Babak
> > > > > >  
> > > > > >  
> > > > > > ceposta wrote
> > > > > > > Very interesting. That sounds like lots of headaches, so keeping optional
> > > > > > > is fine if it solves that.
> > > > > > > I was just noticing in Intellij that it couldn't compile camel-sql
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > > because
> > > > > > > it didn't bring in that dependency since it was marked optional. But
> > > > > > > that's
> > > > > > > an easy headache to fix compared to the ones you mention :)
> > > > > > >  
> > > > > > >  
> > > > > > > On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
> > > > > > > &lt;
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > > > babak.vahdat@
> > > > > >  
> > > > > >  
> > > > > > > &gt;wrote:
> > > > > > >  
> > > > > > > > Hi Christian,
> > > > > > > >  
> > > > > > > > I think having the optional flag set to true is indeed good as we used
> > > > > >  
> > > > > > to
> > > > > > > > have problems to build & run the tests using Java 6 profile on the
> > > > > > > > CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
> > > > > > > >  
> > > > > > > > https://github.com/apache/camel/blob/master/components/pom.xml#L221
> > > > > > > >  
> > > > > > > > Also note that the apt module by itself brings a transitive dependency
> > > > > >  
> > > > > > to
> > > > > > > > spi-annotations:
> > > > > > > >  
> > > > > > > > https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
> > > > > > > >  
> > > > > > > > So I guess removing that optional flag would cause the same problems
> > > > > > > > again,
> > > > > > > > see also this thread:
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > > http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
> > > > > > > >  
> > > > > > > > There's also another ODD issue we're facing with our Jenkins builds but
> > > > > > > > unfortunately it's still not resolved, causing a lot of yellow/red
> > > > > > > > bubbles
> > > > > > > > by our profiles as well as other Apache projects:
> > > > > > > >  
> > > > > > > > https://issues.apache.org/jira/browse/INFRA-6218
> > > > > > > >  
> > > > > > > > Which is another story...
> > > > > > > >  
> > > > > > > > Babak
> > > > > > > >  
> > > > > > > >  
> > > > > > > > ceposta wrote
> > > > > > > > > Apply this for the fix :)
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
> > > > > > > > > index cd2f201..7409c90 100755
> > > > > > > > > --- a/camel-core/pom.xml
> > > > > > > > > +++ b/camel-core/pom.xml
> > > > > > > > > @@ -99,7 +99,6 @@
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > <groupId>
> > > > > > > > > org.apache.camel
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > </groupId>
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > <artifactId>
> > > > > > > > > spi-annotations
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > </artifactId>
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > <version>
> > > > > > > > > ${project.version}
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > </version>
> > > > > > > > > -
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > <optional>
> > > > > > > > > true
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > </optional>
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > </dependency>
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > <dependency>
> > > > > > > > >  
> > > > > > > > > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
> > > > > > > > > &lt;
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > > > christian.posta@
> > > > > > > >  
> > > > > > > >  
> > > > > > > > > &gt;wrote:
> > > > > > > > >  
> > > > > > > > > > So in camel-core, the spi-annotations dependency is marked "optional"
> > > > > > > >  
> > > > > > > > in
> > > > > > > > > > the pom.
> > > > > > > > >  
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > <dependency>
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > <groupId>
> > > > > > > > > org.apache.camel
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > </groupId>
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > <artifactId>
> > > > > > > > > spi-annotations
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > </artifactId>
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > <version>
> > > > > > > > > ${project.version}
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > </version>
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > <optional>
> > > > > > > > > true
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > </optional>
> > > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > </dependency>
> > > > > > > > > >  
> > > > > > > > > > But is it optional? Seems to be used in some of the core components,
> > > > > > > >  
> > > > > > > > so
> > > > > > > > > > should be there, right?
> > > > > > > > > >  
> > > > > > > > > > --
> > > > > > > > > > *Christian Posta*
> > > > > > > > > > http://www.christianposta.com/blog
> > > > > > > > > > twitter: @christianposta
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > >  
> > > > > > > > > --
> > > > > > > > > *Christian Posta*
> > > > > > > > > http://www.christianposta.com/blog
> > > > > > > > > twitter: @christianposta
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > > --
> > > > > > > > View this message in context:View this message in context:
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > >  
> > > > > > http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
> > > > > > Sent from the Camel Development mailing list archive at Nabble.com (http://Nabble.com).
> > > > >  
> > > > >  
> > > > >  
> > > > >  
> > > > >  
> > > > >  
> > > > > --
> > > > > *Christian Posta*
> > > > > http://www.christianposta.com/blog
> > > > > twitter: @christianposta
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > > --
> > > > Claus Ibsen
> > > > -----------------
> > > > Red Hat, Inc.
> > > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> > > > Twitter: davsclaus
> > > > Blog: http://davsclaus.com
> > > > Author of Camel in Action: http://www.manning.com/ibsen
> > >  
> > >  
> > >  
> > >  
> > >  
> > >  
> > >  
> > > --
> > > Claus Ibsen
> > > -----------------
> > > Red Hat, Inc.
> > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> > > Twitter: davsclaus
> > > Blog: http://davsclaus.com
> > > Author of Camel in Action: http://www.manning.com/ibsen
> >  
> >  
> >  
> >  
> >  
> >  
> >  
> > --  
> > Claus Ibsen
> > -----------------
> > Red Hat, Inc.
> > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> > Twitter: davsclaus
> > Blog: http://davsclaus.com
> > Author of Camel in Action: http://www.manning.com/ibsen
>  




Re: spi-annotations

Posted by Willem jiang <wi...@gmail.com>.
Lots of tests failed with this change, I'm trying to figure a solution for it now.
BTW, it is not the good practice to shade the jars with the same package.


--  
Willem Jiang

Red Hat, Inc.
Web: http://www.redhat.com
Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) (English)
          http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese)
Twitter: willemjiang  
Weibo: 姜宁willem





On Tuesday, August 27, 2013 at 7:01 PM, Claus Ibsen wrote:

> Hi
>  
> The shading seems to work fine. I have committed a change to master.
>  
> On Tue, Aug 27, 2013 at 12:34 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
> > Hi
> >  
> > Logged a ticket
> > https://issues.apache.org/jira/browse/CAMEL-6673
> >  
> > Looks like shading works nicely. I will give it a test spin before
> > committing any changes. But the .class files get included in
> > camel-core and available for everybody now.
> >  
> > On Tue, Aug 27, 2013 at 12:26 PM, Claus Ibsen <claus.ibsen@gmail.com (mailto:claus.ibsen@gmail.com)> wrote:
> > > Hi
> > >  
> > > I wonder if we can shade spi-annotations into the camel-core module,
> > > so its included out of the box?
> > > As they are needed at runtime, for example by components extending
> > > UriEndpointComponent etc.
> > >  
> > > If not we should IMHO have it as required dependency and would need
> > > for it to be an OSGi bundle, and added to the features.xml so its
> > > installed in OSGi also.
> > >  
> > >  
> > > On Sat, Aug 17, 2013 at 8:42 PM, Christian Posta
> > > <christian.posta@gmail.com (mailto:christian.posta@gmail.com)> wrote:
> > > > Sounds good. I will give it another try with Java 7 and make sure
> > > > appropriate profiles get enabled.
> > > >  
> > > > Thanks Babak!
> > > >  
> > > > On Saturday, August 17, 2013, Babak Vahdat wrote:
> > > >  
> > > > > Aha now I see, well if you make use of Java 7 and IntelliJ can't handle
> > > > > this
> > > > > then that sounds like a IntelliJ bug to me because in that case the apt
> > > > > profile IS enabled and IntelliJ should take the apt module dependency into
> > > > > account like any other POM dependencies. There was also a user reporting
> > > > > the
> > > > > same problem with IntelliJ. Using the maven-idea-plugin instead of
> > > > > IntelliJ's own "import" functionality solved the problem for him:
> > > > >  
> > > > >  
> > > > > http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html
> > > > >  
> > > > > And that's also what we've got on the Wiki as well:
> > > > >  
> > > > > http://camel.apache.org/building.html#Building-UsinganIDE
> > > > >  
> > > > > That all said I think by making this dependency as optional, James original
> > > > > idea was to NOT bump this dependency transitively to the POM of all those
> > > > > Camel component, data format writers out there as the usage of this new
> > > > > feature should be understood as "optional" so people should not get that
> > > > > transitively but explicitly through their own POMs:
> > > > >  
> > > > > http://camel.apache.org/endpoint-annotations.html
> > > > >  
> > > > > I hope James will comment on this thread if I'm wrong :)
> > > > >  
> > > > > Babak
> > > > >  
> > > > >  
> > > > > ceposta wrote
> > > > > > Very interesting. That sounds like lots of headaches, so keeping optional
> > > > > > is fine if it solves that.
> > > > > > I was just noticing in Intellij that it couldn't compile camel-sql
> > > > >  
> > > > >  
> > > > > because
> > > > > > it didn't bring in that dependency since it was marked optional. But
> > > > > > that's
> > > > > > an easy headache to fix compared to the ones you mention :)
> > > > > >  
> > > > > >  
> > > > > > On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
> > > > > > &lt;
> > > > >  
> > > > >  
> > > > >  
> > > > > > babak.vahdat@
> > > > >  
> > > > > > &gt;wrote:
> > > > > >  
> > > > > > > Hi Christian,
> > > > > > >  
> > > > > > > I think having the optional flag set to true is indeed good as we used
> > > > > to
> > > > > > > have problems to build & run the tests using Java 6 profile on the
> > > > > > > CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
> > > > > > >  
> > > > > > > https://github.com/apache/camel/blob/master/components/pom.xml#L221
> > > > > > >  
> > > > > > > Also note that the apt module by itself brings a transitive dependency
> > > > > to
> > > > > > > spi-annotations:
> > > > > > >  
> > > > > > > https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
> > > > > > >  
> > > > > > > So I guess removing that optional flag would cause the same problems
> > > > > > > again,
> > > > > > > see also this thread:
> > > > > >  
> > > > >  
> > > > >  
> > > > > http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
> > > > > > >  
> > > > > > > There's also another ODD issue we're facing with our Jenkins builds but
> > > > > > > unfortunately it's still not resolved, causing a lot of yellow/red
> > > > > > > bubbles
> > > > > > > by our profiles as well as other Apache projects:
> > > > > > >  
> > > > > > > https://issues.apache.org/jira/browse/INFRA-6218
> > > > > > >  
> > > > > > > Which is another story...
> > > > > > >  
> > > > > > > Babak
> > > > > > >  
> > > > > > >  
> > > > > > > ceposta wrote
> > > > > > > > Apply this for the fix :)
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
> > > > > > > > index cd2f201..7409c90 100755
> > > > > > > > --- a/camel-core/pom.xml
> > > > > > > > +++ b/camel-core/pom.xml
> > > > > > > > @@ -99,7 +99,6 @@
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <groupId>
> > > > > > > > org.apache.camel
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </groupId>
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <artifactId>
> > > > > > > > spi-annotations
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </artifactId>
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <version>
> > > > > > > > ${project.version}
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </version>
> > > > > > > > -
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <optional>
> > > > > > > > true
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </optional>
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </dependency>
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <dependency>
> > > > > > > >  
> > > > > > > > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
> > > > > > > > &lt;
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > > christian.posta@
> > > > > > >  
> > > > > > > > &gt;wrote:
> > > > > > > >  
> > > > > > > > > So in camel-core, the spi-annotations dependency is marked "optional"
> > > > > > > in
> > > > > > > > > the pom.
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > > <dependency>
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <groupId>
> > > > > > > > org.apache.camel
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </groupId>
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <artifactId>
> > > > > > > > spi-annotations
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </artifactId>
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <version>
> > > > > > > > ${project.version}
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </version>
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > <optional>
> > > > > > > > true
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </optional>
> > > > > > > >  
> > > > > > >  
> > > > > >  
> > > > > >  
> > > > > > </dependency>
> > > > > > > > >  
> > > > > > > > > But is it optional? Seems to be used in some of the core components,
> > > > > > > so
> > > > > > > > > should be there, right?
> > > > > > > > >  
> > > > > > > > > --
> > > > > > > > > *Christian Posta*
> > > > > > > > > http://www.christianposta.com/blog
> > > > > > > > > twitter: @christianposta
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > >  
> > > > > > > > --
> > > > > > > > *Christian Posta*
> > > > > > > > http://www.christianposta.com/blog
> > > > > > > > twitter: @christianposta
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > >  
> > > > > > > --
> > > > > > > View this message in context:View this message in context:
> > > > > >  
> > > > >  
> > > > >  
> > > > > http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
> > > > > Sent from the Camel Development mailing list archive at Nabble.com (http://Nabble.com).
> > > >  
> > > >  
> > > >  
> > > >  
> > > > --
> > > > *Christian Posta*
> > > > http://www.christianposta.com/blog
> > > > twitter: @christianposta
> > >  
> > >  
> > >  
> > >  
> > >  
> > > --
> > > Claus Ibsen
> > > -----------------
> > > Red Hat, Inc.
> > > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> > > Twitter: davsclaus
> > > Blog: http://davsclaus.com
> > > Author of Camel in Action: http://www.manning.com/ibsen
> >  
> >  
> >  
> >  
> >  
> > --
> > Claus Ibsen
> > -----------------
> > Red Hat, Inc.
> > Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> > Twitter: davsclaus
> > Blog: http://davsclaus.com
> > Author of Camel in Action: http://www.manning.com/ibsen
>  
>  
>  
>  
>  
> --  
> Claus Ibsen
> -----------------
> Red Hat, Inc.
> Email: cibsen@redhat.com (mailto:cibsen@redhat.com)
> Twitter: davsclaus
> Blog: http://davsclaus.com
> Author of Camel in Action: http://www.manning.com/ibsen




Re: spi-annotations

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

The shading seems to work fine. I have committed a change to master.

On Tue, Aug 27, 2013 at 12:34 PM, Claus Ibsen <cl...@gmail.com> wrote:
> Hi
>
> Logged a ticket
> https://issues.apache.org/jira/browse/CAMEL-6673
>
> Looks like shading works nicely. I will give it a test spin before
> committing any changes. But the .class files get included in
> camel-core and available for everybody now.
>
> On Tue, Aug 27, 2013 at 12:26 PM, Claus Ibsen <cl...@gmail.com> wrote:
>> Hi
>>
>> I wonder if we can shade spi-annotations into the camel-core module,
>> so its included out of the box?
>> As they are needed at runtime, for example by components extending
>> UriEndpointComponent etc.
>>
>> If not we should IMHO have it as required dependency and would need
>> for it to be an OSGi bundle, and added to the features.xml so its
>> installed in OSGi also.
>>
>>
>> On Sat, Aug 17, 2013 at 8:42 PM, Christian Posta
>> <ch...@gmail.com> wrote:
>>> Sounds good. I will give it another try with Java 7 and make sure
>>> appropriate profiles get enabled.
>>>
>>> Thanks Babak!
>>>
>>> On Saturday, August 17, 2013, Babak Vahdat wrote:
>>>
>>>> Aha now I see, well if you make use of Java 7 and IntelliJ can't handle
>>>> this
>>>> then that sounds like a IntelliJ bug to me because in that case the apt
>>>> profile IS enabled and IntelliJ should take the apt module dependency into
>>>> account like any other POM dependencies. There was also a user reporting
>>>> the
>>>> same problem with IntelliJ. Using the maven-idea-plugin instead of
>>>> IntelliJ's own "import" functionality solved the problem for him:
>>>>
>>>>
>>>> http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html
>>>>
>>>> And that's also what we've got on the Wiki as well:
>>>>
>>>> http://camel.apache.org/building.html#Building-UsinganIDE
>>>>
>>>> That all said I think by making this dependency as optional, James original
>>>> idea was to NOT bump this dependency transitively to the POM of all those
>>>> Camel component, data format writers out there as the usage of this new
>>>> feature should be understood as "optional" so people should not get that
>>>> transitively but explicitly through their own POMs:
>>>>
>>>> http://camel.apache.org/endpoint-annotations.html
>>>>
>>>> I hope James will comment on this thread if I'm wrong :)
>>>>
>>>> Babak
>>>>
>>>>
>>>> ceposta wrote
>>>> > Very interesting. That sounds like lots of headaches, so keeping optional
>>>> > is fine if it solves that.
>>>> > I was just noticing in Intellij that it couldn't compile camel-sql
>>>> because
>>>> > it didn't bring in that dependency since it was marked optional. But
>>>> > that's
>>>> > an easy headache to fix compared to the ones you mention :)
>>>> >
>>>> >
>>>> > On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
>>>> > &lt;
>>>>
>>>> > babak.vahdat@
>>>>
>>>> > &gt;wrote:
>>>> >
>>>> >> Hi Christian,
>>>> >>
>>>> >> I think having the optional flag set to true is indeed good as we used
>>>> to
>>>> >> have problems to build & run the tests using Java 6 profile on the
>>>> >> CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
>>>> >>
>>>> >> https://github.com/apache/camel/blob/master/components/pom.xml#L221
>>>> >>
>>>> >> Also note that the apt module by itself brings a transitive dependency
>>>> to
>>>> >> spi-annotations:
>>>> >>
>>>> >> https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
>>>> >>
>>>> >> So I guess removing that optional flag would cause the same problems
>>>> >> again,
>>>> >> see also this thread:
>>>> >>
>>>> >>
>>>> >>
>>>> http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
>>>> >>
>>>> >> There's also another ODD issue we're facing with our Jenkins builds but
>>>> >> unfortunately it's still not resolved, causing a lot of yellow/red
>>>> >> bubbles
>>>> >> by our profiles as well as other Apache projects:
>>>> >>
>>>> >> https://issues.apache.org/jira/browse/INFRA-6218
>>>> >>
>>>> >> Which is another story...
>>>> >>
>>>> >> Babak
>>>> >>
>>>> >>
>>>> >> ceposta wrote
>>>> >> > Apply this for the fix :)
>>>> >> >
>>>> >> >
>>>> >> >
>>>> >> > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
>>>> >> > index cd2f201..7409c90 100755
>>>> >> > --- a/camel-core/pom.xml
>>>> >> > +++ b/camel-core/pom.xml
>>>> >> > @@ -99,7 +99,6 @@
>>>> >> >
>>>> >> >
>>>> > <groupId>
>>>> >> > org.apache.camel
>>>> >> >
>>>> > </groupId>
>>>> >> >
>>>> >> >
>>>> > <artifactId>
>>>> >> > spi-annotations
>>>> >> >
>>>> > </artifactId>
>>>> >> >
>>>> >> >
>>>> > <version>
>>>> >> > ${project.version}
>>>> >> >
>>>> > </version>
>>>> >> > -
>>>> >> >
>>>> > <optional>
>>>> >> > true
>>>> >> >
>>>> > </optional>
>>>> >> >
>>>> >> >
>>>> > </dependency>
>>>> >> >
>>>> >> >
>>>> > <dependency>
>>>> >> >
>>>> >> > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
>>>> >> > &lt;
>>>> >>
>>>> >> > christian.posta@
>>>> >>
>>>> >> > &gt;wrote:
>>>> >> >
>>>> >> >> So in camel-core, the spi-annotations dependency is marked "optional"
>>>> >> in
>>>> >> >> the pom.
>>>> >> >>
>>>> >> >>
>>>> >>
>>>> >> >>
>>>> >> >
>>>> > <dependency>
>>>> >> >>
>>>> >> >
>>>> > <groupId>
>>>> >> > org.apache.camel
>>>> >> >
>>>> > </groupId>
>>>> >> >>
>>>> >> >
>>>> > <artifactId>
>>>> >> > spi-annotations
>>>> >> >
>>>> > </artifactId>
>>>> >> >>
>>>> >> >
>>>> > <version>
>>>> >> > ${project.version}
>>>> >> >
>>>> > </version>
>>>> >> >>
>>>> >> >
>>>> > <optional>
>>>> >> > true
>>>> >> >
>>>> > </optional>
>>>> >> >>
>>>> >> >
>>>> > </dependency>
>>>> >> >>
>>>> >> >> But is it optional? Seems to be used in some of the core components,
>>>> >> so
>>>> >> >> should be there, right?
>>>> >> >>
>>>> >> >> --
>>>> >> >> *Christian Posta*
>>>> >> >> http://www.christianposta.com/blog
>>>> >> >> twitter: @christianposta
>>>> >> >>
>>>> >> >
>>>> >> >
>>>> >> >
>>>> >> > --
>>>> >> > *Christian Posta*
>>>> >> > http://www.christianposta.com/blog
>>>> >> > twitter: @christianposta
>>>> >>
>>>> >>
>>>> >>
>>>> >>
>>>> >>
>>>> >> --
>>>> >> View this message in context:View this message in context:
>>>> http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
>>>> Sent from the Camel Development mailing list archive at Nabble.com.
>>>>
>>>
>>>
>>> --
>>> *Christian Posta*
>>> http://www.christianposta.com/blog
>>> twitter: @christianposta
>>
>>
>>
>> --
>> Claus Ibsen
>> -----------------
>> Red Hat, Inc.
>> Email: cibsen@redhat.com
>> Twitter: davsclaus
>> Blog: http://davsclaus.com
>> Author of Camel in Action: http://www.manning.com/ibsen
>
>
>
> --
> Claus Ibsen
> -----------------
> Red Hat, Inc.
> Email: cibsen@redhat.com
> Twitter: davsclaus
> Blog: http://davsclaus.com
> Author of Camel in Action: http://www.manning.com/ibsen



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: spi-annotations

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

Logged a ticket
https://issues.apache.org/jira/browse/CAMEL-6673

Looks like shading works nicely. I will give it a test spin before
committing any changes. But the .class files get included in
camel-core and available for everybody now.

On Tue, Aug 27, 2013 at 12:26 PM, Claus Ibsen <cl...@gmail.com> wrote:
> Hi
>
> I wonder if we can shade spi-annotations into the camel-core module,
> so its included out of the box?
> As they are needed at runtime, for example by components extending
> UriEndpointComponent etc.
>
> If not we should IMHO have it as required dependency and would need
> for it to be an OSGi bundle, and added to the features.xml so its
> installed in OSGi also.
>
>
> On Sat, Aug 17, 2013 at 8:42 PM, Christian Posta
> <ch...@gmail.com> wrote:
>> Sounds good. I will give it another try with Java 7 and make sure
>> appropriate profiles get enabled.
>>
>> Thanks Babak!
>>
>> On Saturday, August 17, 2013, Babak Vahdat wrote:
>>
>>> Aha now I see, well if you make use of Java 7 and IntelliJ can't handle
>>> this
>>> then that sounds like a IntelliJ bug to me because in that case the apt
>>> profile IS enabled and IntelliJ should take the apt module dependency into
>>> account like any other POM dependencies. There was also a user reporting
>>> the
>>> same problem with IntelliJ. Using the maven-idea-plugin instead of
>>> IntelliJ's own "import" functionality solved the problem for him:
>>>
>>>
>>> http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html
>>>
>>> And that's also what we've got on the Wiki as well:
>>>
>>> http://camel.apache.org/building.html#Building-UsinganIDE
>>>
>>> That all said I think by making this dependency as optional, James original
>>> idea was to NOT bump this dependency transitively to the POM of all those
>>> Camel component, data format writers out there as the usage of this new
>>> feature should be understood as "optional" so people should not get that
>>> transitively but explicitly through their own POMs:
>>>
>>> http://camel.apache.org/endpoint-annotations.html
>>>
>>> I hope James will comment on this thread if I'm wrong :)
>>>
>>> Babak
>>>
>>>
>>> ceposta wrote
>>> > Very interesting. That sounds like lots of headaches, so keeping optional
>>> > is fine if it solves that.
>>> > I was just noticing in Intellij that it couldn't compile camel-sql
>>> because
>>> > it didn't bring in that dependency since it was marked optional. But
>>> > that's
>>> > an easy headache to fix compared to the ones you mention :)
>>> >
>>> >
>>> > On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
>>> > &lt;
>>>
>>> > babak.vahdat@
>>>
>>> > &gt;wrote:
>>> >
>>> >> Hi Christian,
>>> >>
>>> >> I think having the optional flag set to true is indeed good as we used
>>> to
>>> >> have problems to build & run the tests using Java 6 profile on the
>>> >> CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
>>> >>
>>> >> https://github.com/apache/camel/blob/master/components/pom.xml#L221
>>> >>
>>> >> Also note that the apt module by itself brings a transitive dependency
>>> to
>>> >> spi-annotations:
>>> >>
>>> >> https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
>>> >>
>>> >> So I guess removing that optional flag would cause the same problems
>>> >> again,
>>> >> see also this thread:
>>> >>
>>> >>
>>> >>
>>> http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
>>> >>
>>> >> There's also another ODD issue we're facing with our Jenkins builds but
>>> >> unfortunately it's still not resolved, causing a lot of yellow/red
>>> >> bubbles
>>> >> by our profiles as well as other Apache projects:
>>> >>
>>> >> https://issues.apache.org/jira/browse/INFRA-6218
>>> >>
>>> >> Which is another story...
>>> >>
>>> >> Babak
>>> >>
>>> >>
>>> >> ceposta wrote
>>> >> > Apply this for the fix :)
>>> >> >
>>> >> >
>>> >> >
>>> >> > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
>>> >> > index cd2f201..7409c90 100755
>>> >> > --- a/camel-core/pom.xml
>>> >> > +++ b/camel-core/pom.xml
>>> >> > @@ -99,7 +99,6 @@
>>> >> >
>>> >> >
>>> > <groupId>
>>> >> > org.apache.camel
>>> >> >
>>> > </groupId>
>>> >> >
>>> >> >
>>> > <artifactId>
>>> >> > spi-annotations
>>> >> >
>>> > </artifactId>
>>> >> >
>>> >> >
>>> > <version>
>>> >> > ${project.version}
>>> >> >
>>> > </version>
>>> >> > -
>>> >> >
>>> > <optional>
>>> >> > true
>>> >> >
>>> > </optional>
>>> >> >
>>> >> >
>>> > </dependency>
>>> >> >
>>> >> >
>>> > <dependency>
>>> >> >
>>> >> > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
>>> >> > &lt;
>>> >>
>>> >> > christian.posta@
>>> >>
>>> >> > &gt;wrote:
>>> >> >
>>> >> >> So in camel-core, the spi-annotations dependency is marked "optional"
>>> >> in
>>> >> >> the pom.
>>> >> >>
>>> >> >>
>>> >>
>>> >> >>
>>> >> >
>>> > <dependency>
>>> >> >>
>>> >> >
>>> > <groupId>
>>> >> > org.apache.camel
>>> >> >
>>> > </groupId>
>>> >> >>
>>> >> >
>>> > <artifactId>
>>> >> > spi-annotations
>>> >> >
>>> > </artifactId>
>>> >> >>
>>> >> >
>>> > <version>
>>> >> > ${project.version}
>>> >> >
>>> > </version>
>>> >> >>
>>> >> >
>>> > <optional>
>>> >> > true
>>> >> >
>>> > </optional>
>>> >> >>
>>> >> >
>>> > </dependency>
>>> >> >>
>>> >> >> But is it optional? Seems to be used in some of the core components,
>>> >> so
>>> >> >> should be there, right?
>>> >> >>
>>> >> >> --
>>> >> >> *Christian Posta*
>>> >> >> http://www.christianposta.com/blog
>>> >> >> twitter: @christianposta
>>> >> >>
>>> >> >
>>> >> >
>>> >> >
>>> >> > --
>>> >> > *Christian Posta*
>>> >> > http://www.christianposta.com/blog
>>> >> > twitter: @christianposta
>>> >>
>>> >>
>>> >>
>>> >>
>>> >>
>>> >> --
>>> >> View this message in context:View this message in context:
>>> http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
>>> Sent from the Camel Development mailing list archive at Nabble.com.
>>>
>>
>>
>> --
>> *Christian Posta*
>> http://www.christianposta.com/blog
>> twitter: @christianposta
>
>
>
> --
> Claus Ibsen
> -----------------
> Red Hat, Inc.
> Email: cibsen@redhat.com
> Twitter: davsclaus
> Blog: http://davsclaus.com
> Author of Camel in Action: http://www.manning.com/ibsen



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: spi-annotations

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

I wonder if we can shade spi-annotations into the camel-core module,
so its included out of the box?
As they are needed at runtime, for example by components extending
UriEndpointComponent etc.

If not we should IMHO have it as required dependency and would need
for it to be an OSGi bundle, and added to the features.xml so its
installed in OSGi also.


On Sat, Aug 17, 2013 at 8:42 PM, Christian Posta
<ch...@gmail.com> wrote:
> Sounds good. I will give it another try with Java 7 and make sure
> appropriate profiles get enabled.
>
> Thanks Babak!
>
> On Saturday, August 17, 2013, Babak Vahdat wrote:
>
>> Aha now I see, well if you make use of Java 7 and IntelliJ can't handle
>> this
>> then that sounds like a IntelliJ bug to me because in that case the apt
>> profile IS enabled and IntelliJ should take the apt module dependency into
>> account like any other POM dependencies. There was also a user reporting
>> the
>> same problem with IntelliJ. Using the maven-idea-plugin instead of
>> IntelliJ's own "import" functionality solved the problem for him:
>>
>>
>> http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html
>>
>> And that's also what we've got on the Wiki as well:
>>
>> http://camel.apache.org/building.html#Building-UsinganIDE
>>
>> That all said I think by making this dependency as optional, James original
>> idea was to NOT bump this dependency transitively to the POM of all those
>> Camel component, data format writers out there as the usage of this new
>> feature should be understood as "optional" so people should not get that
>> transitively but explicitly through their own POMs:
>>
>> http://camel.apache.org/endpoint-annotations.html
>>
>> I hope James will comment on this thread if I'm wrong :)
>>
>> Babak
>>
>>
>> ceposta wrote
>> > Very interesting. That sounds like lots of headaches, so keeping optional
>> > is fine if it solves that.
>> > I was just noticing in Intellij that it couldn't compile camel-sql
>> because
>> > it didn't bring in that dependency since it was marked optional. But
>> > that's
>> > an easy headache to fix compared to the ones you mention :)
>> >
>> >
>> > On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
>> > &lt;
>>
>> > babak.vahdat@
>>
>> > &gt;wrote:
>> >
>> >> Hi Christian,
>> >>
>> >> I think having the optional flag set to true is indeed good as we used
>> to
>> >> have problems to build & run the tests using Java 6 profile on the
>> >> CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
>> >>
>> >> https://github.com/apache/camel/blob/master/components/pom.xml#L221
>> >>
>> >> Also note that the apt module by itself brings a transitive dependency
>> to
>> >> spi-annotations:
>> >>
>> >> https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
>> >>
>> >> So I guess removing that optional flag would cause the same problems
>> >> again,
>> >> see also this thread:
>> >>
>> >>
>> >>
>> http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
>> >>
>> >> There's also another ODD issue we're facing with our Jenkins builds but
>> >> unfortunately it's still not resolved, causing a lot of yellow/red
>> >> bubbles
>> >> by our profiles as well as other Apache projects:
>> >>
>> >> https://issues.apache.org/jira/browse/INFRA-6218
>> >>
>> >> Which is another story...
>> >>
>> >> Babak
>> >>
>> >>
>> >> ceposta wrote
>> >> > Apply this for the fix :)
>> >> >
>> >> >
>> >> >
>> >> > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
>> >> > index cd2f201..7409c90 100755
>> >> > --- a/camel-core/pom.xml
>> >> > +++ b/camel-core/pom.xml
>> >> > @@ -99,7 +99,6 @@
>> >> >
>> >> >
>> > <groupId>
>> >> > org.apache.camel
>> >> >
>> > </groupId>
>> >> >
>> >> >
>> > <artifactId>
>> >> > spi-annotations
>> >> >
>> > </artifactId>
>> >> >
>> >> >
>> > <version>
>> >> > ${project.version}
>> >> >
>> > </version>
>> >> > -
>> >> >
>> > <optional>
>> >> > true
>> >> >
>> > </optional>
>> >> >
>> >> >
>> > </dependency>
>> >> >
>> >> >
>> > <dependency>
>> >> >
>> >> > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
>> >> > &lt;
>> >>
>> >> > christian.posta@
>> >>
>> >> > &gt;wrote:
>> >> >
>> >> >> So in camel-core, the spi-annotations dependency is marked "optional"
>> >> in
>> >> >> the pom.
>> >> >>
>> >> >>
>> >>
>> >> >>
>> >> >
>> > <dependency>
>> >> >>
>> >> >
>> > <groupId>
>> >> > org.apache.camel
>> >> >
>> > </groupId>
>> >> >>
>> >> >
>> > <artifactId>
>> >> > spi-annotations
>> >> >
>> > </artifactId>
>> >> >>
>> >> >
>> > <version>
>> >> > ${project.version}
>> >> >
>> > </version>
>> >> >>
>> >> >
>> > <optional>
>> >> > true
>> >> >
>> > </optional>
>> >> >>
>> >> >
>> > </dependency>
>> >> >>
>> >> >> But is it optional? Seems to be used in some of the core components,
>> >> so
>> >> >> should be there, right?
>> >> >>
>> >> >> --
>> >> >> *Christian Posta*
>> >> >> http://www.christianposta.com/blog
>> >> >> twitter: @christianposta
>> >> >>
>> >> >
>> >> >
>> >> >
>> >> > --
>> >> > *Christian Posta*
>> >> > http://www.christianposta.com/blog
>> >> > twitter: @christianposta
>> >>
>> >>
>> >>
>> >>
>> >>
>> >> --
>> >> View this message in context:View this message in context:
>> http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
>> Sent from the Camel Development mailing list archive at Nabble.com.
>>
>
>
> --
> *Christian Posta*
> http://www.christianposta.com/blog
> twitter: @christianposta



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: spi-annotations

Posted by Christian Posta <ch...@gmail.com>.
Sounds good. I will give it another try with Java 7 and make sure
appropriate profiles get enabled.

Thanks Babak!

On Saturday, August 17, 2013, Babak Vahdat wrote:

> Aha now I see, well if you make use of Java 7 and IntelliJ can't handle
> this
> then that sounds like a IntelliJ bug to me because in that case the apt
> profile IS enabled and IntelliJ should take the apt module dependency into
> account like any other POM dependencies. There was also a user reporting
> the
> same problem with IntelliJ. Using the maven-idea-plugin instead of
> IntelliJ's own "import" functionality solved the problem for him:
>
>
> http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html
>
> And that's also what we've got on the Wiki as well:
>
> http://camel.apache.org/building.html#Building-UsinganIDE
>
> That all said I think by making this dependency as optional, James original
> idea was to NOT bump this dependency transitively to the POM of all those
> Camel component, data format writers out there as the usage of this new
> feature should be understood as "optional" so people should not get that
> transitively but explicitly through their own POMs:
>
> http://camel.apache.org/endpoint-annotations.html
>
> I hope James will comment on this thread if I'm wrong :)
>
> Babak
>
>
> ceposta wrote
> > Very interesting. That sounds like lots of headaches, so keeping optional
> > is fine if it solves that.
> > I was just noticing in Intellij that it couldn't compile camel-sql
> because
> > it didn't bring in that dependency since it was marked optional. But
> > that's
> > an easy headache to fix compared to the ones you mention :)
> >
> >
> > On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
> > &lt;
>
> > babak.vahdat@
>
> > &gt;wrote:
> >
> >> Hi Christian,
> >>
> >> I think having the optional flag set to true is indeed good as we used
> to
> >> have problems to build & run the tests using Java 6 profile on the
> >> CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
> >>
> >> https://github.com/apache/camel/blob/master/components/pom.xml#L221
> >>
> >> Also note that the apt module by itself brings a transitive dependency
> to
> >> spi-annotations:
> >>
> >> https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
> >>
> >> So I guess removing that optional flag would cause the same problems
> >> again,
> >> see also this thread:
> >>
> >>
> >>
> http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
> >>
> >> There's also another ODD issue we're facing with our Jenkins builds but
> >> unfortunately it's still not resolved, causing a lot of yellow/red
> >> bubbles
> >> by our profiles as well as other Apache projects:
> >>
> >> https://issues.apache.org/jira/browse/INFRA-6218
> >>
> >> Which is another story...
> >>
> >> Babak
> >>
> >>
> >> ceposta wrote
> >> > Apply this for the fix :)
> >> >
> >> >
> >> >
> >> > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
> >> > index cd2f201..7409c90 100755
> >> > --- a/camel-core/pom.xml
> >> > +++ b/camel-core/pom.xml
> >> > @@ -99,7 +99,6 @@
> >> >
> >> >
> > <groupId>
> >> > org.apache.camel
> >> >
> > </groupId>
> >> >
> >> >
> > <artifactId>
> >> > spi-annotations
> >> >
> > </artifactId>
> >> >
> >> >
> > <version>
> >> > ${project.version}
> >> >
> > </version>
> >> > -
> >> >
> > <optional>
> >> > true
> >> >
> > </optional>
> >> >
> >> >
> > </dependency>
> >> >
> >> >
> > <dependency>
> >> >
> >> > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
> >> > &lt;
> >>
> >> > christian.posta@
> >>
> >> > &gt;wrote:
> >> >
> >> >> So in camel-core, the spi-annotations dependency is marked "optional"
> >> in
> >> >> the pom.
> >> >>
> >> >>
> >>
> >> >>
> >> >
> > <dependency>
> >> >>
> >> >
> > <groupId>
> >> > org.apache.camel
> >> >
> > </groupId>
> >> >>
> >> >
> > <artifactId>
> >> > spi-annotations
> >> >
> > </artifactId>
> >> >>
> >> >
> > <version>
> >> > ${project.version}
> >> >
> > </version>
> >> >>
> >> >
> > <optional>
> >> > true
> >> >
> > </optional>
> >> >>
> >> >
> > </dependency>
> >> >>
> >> >> But is it optional? Seems to be used in some of the core components,
> >> so
> >> >> should be there, right?
> >> >>
> >> >> --
> >> >> *Christian Posta*
> >> >> http://www.christianposta.com/blog
> >> >> twitter: @christianposta
> >> >>
> >> >
> >> >
> >> >
> >> > --
> >> > *Christian Posta*
> >> > http://www.christianposta.com/blog
> >> > twitter: @christianposta
> >>
> >>
> >>
> >>
> >>
> >> --
> >> View this message in context:View this message in context:
> http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
> Sent from the Camel Development mailing list archive at Nabble.com.
>


-- 
*Christian Posta*
http://www.christianposta.com/blog
twitter: @christianposta

Re: spi-annotations

Posted by Babak Vahdat <ba...@swissonline.ch>.
Aha now I see, well if you make use of Java 7 and IntelliJ can't handle this
then that sounds like a IntelliJ bug to me because in that case the apt
profile IS enabled and IntelliJ should take the apt module dependency into
account like any other POM dependencies. There was also a user reporting the
same problem with IntelliJ. Using the maven-idea-plugin instead of
IntelliJ's own "import" functionality solved the problem for him:

http://camel.465427.n5.nabble.com/About-the-spi-annotations-dependency-tp5736873p5737084.html

And that's also what we've got on the Wiki as well:

http://camel.apache.org/building.html#Building-UsinganIDE

That all said I think by making this dependency as optional, James original
idea was to NOT bump this dependency transitively to the POM of all those
Camel component, data format writers out there as the usage of this new
feature should be understood as "optional" so people should not get that
transitively but explicitly through their own POMs:

http://camel.apache.org/endpoint-annotations.html

I hope James will comment on this thread if I'm wrong :)

Babak


ceposta wrote
> Very interesting. That sounds like lots of headaches, so keeping optional
> is fine if it solves that.
> I was just noticing in Intellij that it couldn't compile camel-sql because
> it didn't bring in that dependency since it was marked optional. But
> that's
> an easy headache to fix compared to the ones you mention :)
> 
> 
> On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
> &lt;

> babak.vahdat@

> &gt;wrote:
> 
>> Hi Christian,
>>
>> I think having the optional flag set to true is indeed good as we used to
>> have problems to build & run the tests using Java 6 profile on the
>> CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
>>
>> https://github.com/apache/camel/blob/master/components/pom.xml#L221
>>
>> Also note that the apt module by itself brings a transitive dependency to
>> spi-annotations:
>>
>> https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
>>
>> So I guess removing that optional flag would cause the same problems
>> again,
>> see also this thread:
>>
>>
>> http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
>>
>> There's also another ODD issue we're facing with our Jenkins builds but
>> unfortunately it's still not resolved, causing a lot of yellow/red
>> bubbles
>> by our profiles as well as other Apache projects:
>>
>> https://issues.apache.org/jira/browse/INFRA-6218
>>
>> Which is another story...
>>
>> Babak
>>
>>
>> ceposta wrote
>> > Apply this for the fix :)
>> >
>> >
>> >
>> > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
>> > index cd2f201..7409c90 100755
>> > --- a/camel-core/pom.xml
>> > +++ b/camel-core/pom.xml
>> > @@ -99,7 +99,6 @@
>> >
>> > 
> <groupId>
>> > org.apache.camel
>> > 
> </groupId>
>> >
>> > 
> <artifactId>
>> > spi-annotations
>> > 
> </artifactId>
>> >
>> > 
> <version>
>> > ${project.version}
>> > 
> </version>
>> > -
>> > 
> <optional>
>> > true
>> > 
> </optional>
>> >
>> > 
> </dependency>
>> >
>> > 
> <dependency>
>> >
>> > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
>> > &lt;
>>
>> > christian.posta@
>>
>> > &gt;wrote:
>> >
>> >> So in camel-core, the spi-annotations dependency is marked "optional"
>> in
>> >> the pom.
>> >>
>> >>
>>
>> >>
>> > 
> <dependency>
>> >>
>> > 
> <groupId>
>> > org.apache.camel
>> > 
> </groupId>
>> >>
>> > 
> <artifactId>
>> > spi-annotations
>> > 
> </artifactId>
>> >>
>> > 
> <version>
>> > ${project.version}
>> > 
> </version>
>> >>
>> > 
> <optional>
>> > true
>> > 
> </optional>
>> >>
>> > 
> </dependency>
>> >>
>> >> But is it optional? Seems to be used in some of the core components,
>> so
>> >> should be there, right?
>> >>
>> >> --
>> >> *Christian Posta*
>> >> http://www.christianposta.com/blog
>> >> twitter: @christianposta
>> >>
>> >
>> >
>> >
>> > --
>> > *Christian Posta*
>> > http://www.christianposta.com/blog
>> > twitter: @christianposta
>>
>>
>>
>>
>>
>> --
>> View this message in context:
>> http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737448.html
>> Sent from the Camel Development mailing list archive at Nabble.com.
>>
> 
> 
> 
> -- 
> *Christian Posta*
> http://www.christianposta.com/blog
> twitter: @christianposta





--
View this message in context: http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737457.html
Sent from the Camel Development mailing list archive at Nabble.com.

Re: spi-annotations

Posted by Christian Posta <ch...@gmail.com>.
Very interesting. That sounds like lots of headaches, so keeping optional
is fine if it solves that.
I was just noticing in Intellij that it couldn't compile camel-sql because
it didn't bring in that dependency since it was marked optional. But that's
an easy headache to fix compared to the ones you mention :)


On Sat, Aug 17, 2013 at 1:11 AM, Babak Vahdat
<ba...@swissonline.ch>wrote:

> Hi Christian,
>
> I think having the optional flag set to true is indeed good as we used to
> have problems to build & run the tests using Java 6 profile on the
> CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:
>
> https://github.com/apache/camel/blob/master/components/pom.xml#L221
>
> Also note that the apt module by itself brings a transitive dependency to
> spi-annotations:
>
> https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43
>
> So I guess removing that optional flag would cause the same problems again,
> see also this thread:
>
>
> http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html
>
> There's also another ODD issue we're facing with our Jenkins builds but
> unfortunately it's still not resolved, causing a lot of yellow/red bubbles
> by our profiles as well as other Apache projects:
>
> https://issues.apache.org/jira/browse/INFRA-6218
>
> Which is another story...
>
> Babak
>
>
> ceposta wrote
> > Apply this for the fix :)
> >
> >
> >
> > diff --git a/camel-core/pom.xml b/camel-core/pom.xml
> > index cd2f201..7409c90 100755
> > --- a/camel-core/pom.xml
> > +++ b/camel-core/pom.xml
> > @@ -99,7 +99,6 @@
> >
> > <groupId>
> > org.apache.camel
> > </groupId>
> >
> > <artifactId>
> > spi-annotations
> > </artifactId>
> >
> > <version>
> > ${project.version}
> > </version>
> > -
> > <optional>
> > true
> > </optional>
> >
> > </dependency>
> >
> > <dependency>
> >
> > On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
> > &lt;
>
> > christian.posta@
>
> > &gt;wrote:
> >
> >> So in camel-core, the spi-annotations dependency is marked "optional" in
> >> the pom.
> >>
> >>
>
> >>
> > <dependency>
> >>
> > <groupId>
> > org.apache.camel
> > </groupId>
> >>
> > <artifactId>
> > spi-annotations
> > </artifactId>
> >>
> > <version>
> > ${project.version}
> > </version>
> >>
> > <optional>
> > true
> > </optional>
> >>
> > </dependency>
> >>
> >> But is it optional? Seems to be used in some of the core components, so
> >> should be there, right?
> >>
> >> --
> >> *Christian Posta*
> >> http://www.christianposta.com/blog
> >> twitter: @christianposta
> >>
> >
> >
> >
> > --
> > *Christian Posta*
> > http://www.christianposta.com/blog
> > twitter: @christianposta
>
>
>
>
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737448.html
> Sent from the Camel Development mailing list archive at Nabble.com.
>



-- 
*Christian Posta*
http://www.christianposta.com/blog
twitter: @christianposta

Re: spi-annotations

Posted by Babak Vahdat <ba...@swissonline.ch>.
Hi Christian,

I think having the optional flag set to true is indeed good as we used to
have problems to build & run the tests using Java 6 profile on the
CI-Server, e.g. the profile "Camel.trunk.fulltest". See also here:

https://github.com/apache/camel/blob/master/components/pom.xml#L221

Also note that the apt module by itself brings a transitive dependency to
spi-annotations:

https://github.com/apache/camel/blob/master/tooling/apt/pom.xml#L43

So I guess removing that optional flag would cause the same problems again,
see also this thread:

http://camel.465427.n5.nabble.com/Our-builds-looks-really-bad-tp5731673p5731743.html

There's also another ODD issue we're facing with our Jenkins builds but
unfortunately it's still not resolved, causing a lot of yellow/red bubbles
by our profiles as well as other Apache projects:

https://issues.apache.org/jira/browse/INFRA-6218

Which is another story...

Babak


ceposta wrote
> Apply this for the fix :)
> 
> 
> 
> diff --git a/camel-core/pom.xml b/camel-core/pom.xml
> index cd2f201..7409c90 100755
> --- a/camel-core/pom.xml
> +++ b/camel-core/pom.xml
> @@ -99,7 +99,6 @@
>        
> <groupId>
> org.apache.camel
> </groupId>
>        
> <artifactId>
> spi-annotations
> </artifactId>
>        
> <version>
> ${project.version}
> </version>
> -      
> <optional>
> true
> </optional>
>      
> </dependency>
>      
> <dependency>
> 
> On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
> &lt;

> christian.posta@

> &gt;wrote:
> 
>> So in camel-core, the spi-annotations dependency is marked "optional" in
>> the pom.
>>
>>     

>>     
> <dependency>
>>       
> <groupId>
> org.apache.camel
> </groupId>
>>       
> <artifactId>
> spi-annotations
> </artifactId>
>>       
> <version>
> ${project.version}
> </version>
>>       
> <optional>
> true
> </optional>
>>     
> </dependency>
>>
>> But is it optional? Seems to be used in some of the core components, so
>> should be there, right?
>>
>> --
>> *Christian Posta*
>> http://www.christianposta.com/blog
>> twitter: @christianposta
>>
> 
> 
> 
> -- 
> *Christian Posta*
> http://www.christianposta.com/blog
> twitter: @christianposta





--
View this message in context: http://camel.465427.n5.nabble.com/spi-annotations-tp5737435p5737448.html
Sent from the Camel Development mailing list archive at Nabble.com.

Re: spi-annotations

Posted by Christian Posta <ch...@gmail.com>.
Apply this for the fix :)



diff --git a/camel-core/pom.xml b/camel-core/pom.xml
index cd2f201..7409c90 100755
--- a/camel-core/pom.xml
+++ b/camel-core/pom.xml
@@ -99,7 +99,6 @@
       <groupId>org.apache.camel</groupId>
       <artifactId>spi-annotations</artifactId>
       <version>${project.version}</version>
-      <optional>true</optional>
     </dependency>

     <dependency>


On Fri, Aug 16, 2013 at 1:43 PM, Christian Posta
<ch...@gmail.com>wrote:

> So in camel-core, the spi-annotations dependency is marked "optional" in
> the pom.
>
>     <!-- required dependencies by camel-core -->
>     <dependency>
>       <groupId>org.apache.camel</groupId>
>       <artifactId>spi-annotations</artifactId>
>       <version>${project.version}</version>
>       <optional>true</optional>
>     </dependency>
>
> But is it optional? Seems to be used in some of the core components, so
> should be there, right?
>
> --
> *Christian Posta*
> http://www.christianposta.com/blog
> twitter: @christianposta
>



-- 
*Christian Posta*
http://www.christianposta.com/blog
twitter: @christianposta