Hi,
Could you use
osgi:headers fon_bundle_id
and tell if the optional import package
"rg.apache.avalon.framework.configuration" is already get resolved?
The red color means doesn't get resolved.
Freeman
On 2011-6-2, at 下午1:59, Scott Came wrote:
Thanks, Freeman, but that didn't help.
I restarted servicemix, did "refresh [fop bundle id]", then tried to
start my bundle that instantiates FopFactory. I still get the
NoClassDefFoundError.
I also uninstalled the Fop bundle, then reinstalled it, to be sure
Avalon was there prior to Fop.
Still when I start my bundle that instantiates FopFactory, I get the
NCDFE.
Anything else I could try?
-----Original Message-----
From: Freeman Fang [mailto:[email protected]]
Sent: Wednesday, June 01, 2011 5:31 PM
To: [email protected]
Subject: Re: Install snapshot bundles
Hi,
That's because Fon bundle optionally import
org.apache.avalon.framework.configuration package, so even this
package isn't available, it won't affect the fon start correctly.
After you manually install avalon bundle, you also need refresh Fon
bundle to pick up this optional import. Or you can put Fon and
avalon into a feature, then install this feature can get all
available optional package installed out of box.
Freeman
On 2011-6-2, at 上午4:26, Scott Came wrote:
OK, I figured this out...but there seems to be a problem with the
Fop bundle.
Since the apache snapshots repository is included in the list that
the mvn installer searches, it worked to install the fop bundle and
its two dependencies (xmlgraphics-commons and batik). All three
install and start just fine.
However, when I attempt to instantiate
org.apache.fop.apps.FopFactory I get this exception (embedded in a
chained stack trace)...
Caused by: java.lang.NoClassDefFoundError: org/apache/avalon/
framework/configuration/ConfigurationException
at org.apache.fop.apps.FopFactory.<init>(FopFactory.java:153)
at org.apache.fop.apps.FopFactory.newInstance(FopFactory.java:
177)
at
gov
.ojp
.it.ws.remote.PdfExportProcessor.<clinit>(PdfExportProcessor.java:26)
at
sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at
sun
.reflect
.NativeConstructorAccessorImpl
.newInstance(NativeConstructorAccessorImpl.java:39)
at
sun
.reflect
.DelegatingConstructorAccessorImpl
.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:
513)
at
org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:
126)
at
org
.springframework
.beans
.factory
.support
.SimpleInstantiationStrategy
.instantiate(SimpleInstantiationStrategy.java:74)
at
org
.springframework
.beans
.factory
.support
.AbstractAutowireCapableBeanFactory
.instantiateBean(AbstractAutowireCapableBeanFactory.java:958)
... 15 more
Clearly there is a dependency on Avalon here...so I looked in the
fop bundle pom, and installed org.apache.avalon.framework/avalon-
framework-api and -impl bundles. They both installed and started
fine. But still when I install and start my bundle that
instantiates org.apache.fop.apps.FopFactory, I still get the same
stack trace as above.
If it helps diagnose, here is a snippet from osgi:list:
[ 234] [Active ] [ ] [ ] [ 60] Apache
ServiceMix :: Bundles :: fop (1.0.0.1-SNAPSHOT)
[ 236] [Active ] [ ] [ ] [ 60] Apache
ServiceMix :: Bundles :: xmlgraphics-commons (1.4.0.1-SNAPSHOT)
[ 237] [Active ] [ ] [ ] [ 60] Apache
ServiceMix :: Bundles :: batik (1.7.0.1-SNAPSHOT)
[ 241] [Active ] [ ] [ ] [ 60]
mvn:org.apache.avalon.framework/avalon-framework-api/4.3.1
[ 242] [Active ] [ ] [ ] [ 60]
mvn:org.apache.avalon.framework/avalon-framework-impl/4.3.1
Could it be that these Avalon bundles are not "osgi-ready"? (I did
not see smx bundles for them...)
Thanks.
--Scott
-----Original Message-----
From: Scott Came [mailto:[email protected]]
Sent: Wednesday, June 01, 2011 11:57 AM
To: [email protected]
Subject: Install snapshot bundles
I would like to install the new FOP bundle (snapshot) into my
running instance of smx 4.3.0.
I see it has been deployed to the snapshot repository:
https://repository.apache.org/content/groups/snapshots/org/apache/servicemix/bundles/org.apache.servicemix.bundles.fop/
I also note that it has a number of dependencies.
What is the easiest way to install the bundle, and its
dependencies? I'd rather avoid manually downloading the graph of
dependencies and placing all the jars in the smx deploy
directory...is there an easier way?
Thanks.
--Scott
---------------------------------------------
Freeman Fang
FuseSource
Email:[email protected]
Web: fusesource.com
Twitter: freemanfang
Blog: http://freemanfang.blogspot.com
Connect at CamelOne May 24-26
The Open Source Integration Conference
---------------------------------------------
Freeman Fang
FuseSource
Email:[email protected]
Web: fusesource.com
Twitter: freemanfang
Blog: http://freemanfang.blogspot.com
Connect at CamelOne May 24-26
The Open Source Integration Conference