Ok, good,
Thank you Freeman!

One more question: do you consider this to be a "best practice" or a
"workaround"?

Thanks!
Cristiano


2014/1/9 Freeman Fang <[email protected]>

> Yep.
>
> And put springsec feature in front of camel feature in featuresBoot should
> be helpful.
> -------------
> Freeman(Yue) Fang
>
> Red Hat, Inc.
> FuseSource is now part of Red Hat
>
>
>
> On 2014-1-9, at 下午5:53, Achim Nierbeck wrote:
>
> > The answer is pretty simple,
> > if you have a Bundle A that imports packages optionally and it is
> resolved
> > those optional imports won't be imported until this bundle is refreshed,
> > since for the resolver this bundle in question is fully resolved as those
> > missing imports are optional. The resolver doesn't look through all kinds
> > of bundles to check if a newly added bundle does now provide optionally
> > needed packages.
> >
> > Regards, Achim
> >
> >
> > 2014/1/9 Cristiano Costantini <[email protected]>
> >
> >> Hi all,
> >> I've posted this question here because it involves
> >> org.apache.servicemix.bundles,
> >> maybe is it a topic that better fit the Karaf user mailing list?
> >>
> >> thank you!
> >> Cristiano
> >>
> >>
> >> 2014/1/8 Cristiano Costantini <[email protected]>
> >>
> >>> Hi All,
> >>> I've made an application by defining a feature called "springsec":
> >>>
> >>>
> >>
> https://github.com/cristcost/springsec/blob/master/src/main/resources/features.xml
> >>>
> >>> I install the application on servicemix 4.5.3 where I define to launch
> >> the
> >>> feature at boot
> >>>
> >>
> (featuresBoot=karaf-framework,config,activemq-broker,activemq-spring,saaj,cxf-specs,camel,activemq-camel,camel-cxf,camel-blueprint,war,webconsole,springsec).
> >>>
> >>> as you can see, my feature has add the bundle
> >>>
> >>
> "mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.aspectj/${smx-aspectj.version}"
> >>> which is required for resolving org.aspectj.* optional imports of the
> >>> bundle org.springframework.aop (see its imports here
> >>> https://gist.github.com/cristcost/8313004)
> >>>
> >>> The problem is that even if I define to add my feature at boot,
> >>> org.springframework.aop starts without resolving the optional imports,
> >> and
> >>> until I restart ServiceMix I get a:
> >>>
> >>> "189 - org.springframework.web - 3.0.7.RELEASE | Context initialization
> >>> failed java.lang.NoClassDefFoundError: org/aspectj/lang/JoinPoint"
> >>> ...
> >>> "Caused by: java.lang.ClassNotFoundException:
> org.aspectj.lang.JoinPoint
> >>> not found by org.springframework.aop [74]"
> >>>
> >>>
> >>> Can anyone tell me if there is a good way to force
> >> org.springframework.aop
> >>> [74] to resolve the org.aspectj.* optional dependencies at startup?
> >>>
> >>>
> >>> Thank you,
> >>> Cristiano
> >>>
> >>
> >
> >
> >
> > --
> >
> > Apache Karaf <http://karaf.apache.org/> Committer & PMC
> > OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> Committer
> &
> > Project Lead
> > OPS4J Pax for Vaadin <http://team.ops4j.org/wiki/display/PAXVAADIN/Home>
> > Commiter & Project Lead
> > blog <http://notizblog.nierbeck.de/>
>
>

Reply via email to