You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by klausb <kl...@hp.com> on 2010/11/30 09:29:22 UTC

Observation on OSGi and NoTypeConversionAvailableException

While coding with Karaf and Camel 2.5.0, I made the following observation:

If I'm loading two communicating bundles using the VM endpoint I do not see
any problems.
Both get started and exchange messages as expected.

Afterwards, if I quit Karaf (^D) gracefully and restart it, Karaf wants
reloads the bundles from its cache to reach the state before the shutdown.
Here I see the NoTypeConversionAvailableException on one of the two bundles.
And it is always complaining about: 

No type converter available to convert from type: java.lang.String to the
required type: java.lang.Boolean with value false

The affected bundle consequently fails and does not start.
Is this known bug or do I need to prepare the container differently to avoid
this behavior?

klaus.

-- 
View this message in context: http://camel.465427.n5.nabble.com/Observation-on-OSGi-and-NoTypeConversionAvailableException-tp3285742p3285742.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Observation on OSGi and NoTypeConversionAvailableException

Posted by klausb <kl...@hp.com>.
Yes, I used features. I defined my own feature, which loads this

<feature version='2.5.0'>camel-core</feature>
<feature version='2.5.0'>camel-spring</feature>
<feature version='2.5.0'>camel-xstream</feature>

klaus.
-- 
View this message in context: http://camel.465427.n5.nabble.com/Observation-on-OSGi-and-NoTypeConversionAvailableException-tp3285742p3285822.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Observation on OSGi and NoTypeConversionAvailableException

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

Did you install camel using features?

features:install camel

Which loads and ensures all JARs and bundles is installed correctly.

Also each Camel component has a feature, eg camel-mail
features:install camel-mail



On Tue, Nov 30, 2010 at 9:29 AM, klausb <kl...@hp.com> wrote:
>
> While coding with Karaf and Camel 2.5.0, I made the following observation:
>
> If I'm loading two communicating bundles using the VM endpoint I do not see
> any problems.
> Both get started and exchange messages as expected.
>
> Afterwards, if I quit Karaf (^D) gracefully and restart it, Karaf wants
> reloads the bundles from its cache to reach the state before the shutdown.
> Here I see the NoTypeConversionAvailableException on one of the two bundles.
> And it is always complaining about:
>
> No type converter available to convert from type: java.lang.String to the
> required type: java.lang.Boolean with value false
>
> The affected bundle consequently fails and does not start.
> Is this known bug or do I need to prepare the container differently to avoid
> this behavior?
>
> klaus.
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Observation-on-OSGi-and-NoTypeConversionAvailableException-tp3285742p3285742.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>



-- 
Claus Ibsen
-----------------
FuseSource
Email: cibsen@fusesource.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.blogspot.com/
Author of Camel in Action: http://www.manning.com/ibsen/

Re: Observation on OSGi and NoTypeConversionAvailableException

Posted by Hendy Irawan <he...@soluvas.com>.
I have posted a detailed experience how to run Camel inside an Eclipse RCP
application (successfully :-).

Anyone interested can look here:

http://eclipsedriven.blogspot.com/2011/01/pojo-remoting-over-camel-xmpp-within.html

Good luck :-)

-----
Soluvas - Making eCommerce Work for You 
--
View this message in context: http://camel.465427.n5.nabble.com/Observation-on-OSGi-and-NoTypeConversionAvailableException-tp3285742p4268926.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Observation on OSGi and NoTypeConversionAvailableException

Posted by Hendy Irawan <he...@soluvas.com>.
I followed what Willem said and my Camel app is working fine with :

- Eclipse 3.7 milestone
- Camel-blueprint 2.5.0 + camel-eclipse
- Aries Blueprint 0.2-incubator
- XMPP component (need to hack dependencies though)

(this is Eclipse RCP application)

Basically I need to *start* (not just resolve) all Camel bundles, especially
camel-core which provides the type converters.

-----
http://www.Soluvas.com/ Soluvas - Making eCommerce Work for You 
-- 
View this message in context: http://camel.465427.n5.nabble.com/Observation-on-OSGi-and-NoTypeConversionAvailableException-tp3285742p3323165.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Observation on OSGi and NoTypeConversionAvailableException

Posted by klausb <kl...@hp.com>.
I switched to camel 2.4.0 and it works now.

Thanks to all,
klaus.
-- 
View this message in context: http://camel.465427.n5.nabble.com/Observation-on-OSGi-and-NoTypeConversionAvailableException-tp3285742p3287614.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Observation on OSGi and NoTypeConversionAvailableException

Posted by Willem Jiang <wi...@gmail.com>.
On 11/30/10 3:29 AM, klausb wrote:
>
> While coding with Karaf and Camel 2.5.0, I made the following observation:
>
> If I'm loading two communicating bundles using the VM endpoint I do not see
> any problems.
> Both get started and exchange messages as expected.
>
> Afterwards, if I quit Karaf (^D) gracefully and restart it, Karaf wants
> reloads the bundles from its cache to reach the state before the shutdown.
> Here I see the NoTypeConversionAvailableException on one of the two bundles.
> And it is always complaining about:
>
> No type converter available to convert from type: java.lang.String to the
> required type: java.lang.Boolean with value false

If you want to make sure Camel works well with the OSGi, you need to 
make sure the camel-core and camel-spring bundle are started rightly 
before the you application bundle is loaded.

>
> The affected bundle consequently fails and does not start.
> Is this known bug or do I need to prepare the container differently to avoid
> this behavior?

What's the version of Karaf are you using ?
If you are using Karaf 2.1.0, you can specify the bundle's start level 
from the features file.e
>
> klaus.
>


-- 
Willem
----------------------------------
FuseSource
Web: http://www.fusesource.com
Blog:    http://willemjiang.blogspot.com (English)
          http://jnn.javaeye.com (Chinese)
Twitter: willemjiang