geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From MoleSon <sascha.gebha...@t-online.de>
Subject Re: ClassCastException when using a self written TypeConverter
Date Thu, 05 Jul 2007 14:15:01 GMT

I managed to deploy my application now by adding the tranql jar to my ear
file, but this threw up a bunch of new errors now, so i'll follow your
suggestion to update to the new geronimo version ;)

Manu George wrote:
> 
> I remember facing a similar issue and I think that there is a bug with
> the TypeConverter stuff in OpenEJB. I would second Gianny's advice to
> use Geronimo 2.0 and OEJB 3.0 and get back if there are issues there.
> 
> Regards
> Manu
> 
> On 7/5/07, Gianny Damour <gianny.damour@optusnet.com.au> wrote:
>> On 05/07/2007, at 10:34 PM, MoleSon wrote:
>>
>> > Could not deploy module
>> > org.apache.geronimo.common.DeploymentException: Could not deploy
>> > module
>> >       ...
>> > Caused by: org.apache.geronimo.common.DeploymentException: Cannot
>> > create
>> > type converter mypackage.MyTypeConverter
>> >       at
>> > org.openejb.deployment.SchemataBuilder.processEnterpriseBeans
>> > (SchemataBuilder.java:436)
>> >       ... 32 more
>> > Caused by: java.lang.ClassCastException: mypackage.MyTypeConverter
>> >       at
>> > org.openejb.deployment.SchemataBuilder.processEnterpriseBeans
>> > (SchemataBuilder.java:434)
>> >       ... 33 more
>> >
>> > I had a look at the geronimo source code and notices that the
>> > Exception is
>> > thrown at these lines in the ScemataBuilder:
>> > try
>> > {
>> >       Class typeConverterClass = cl.loadClass(mapping.getTypeConverter
>> > ().trim());
>> >       typeConverter = (TypeConverter)typeConverterClass.newInstance();
>> > }
>> > catch(Exception e)
>> > {
>> >       throw new DeploymentException("Cannot create type converter " +
>> > mapping.getTypeConverter(), e);
>> > }
>>
>> It is hard to diagnostic. Could you please put a breakpoint after
>> cl.loadClass and tell us what the value of MultiParentClassLoader.id
>> is? Also, I strongly recommend you to migrate to the latest version
>> of Geronimo/OpenEJB, which uses OpenJPA as the underlying persistence
>> framework for CMPs. This migration should be "effortless" as you do
>> not need to change your OpenEJB deployment descriptors. Furthermore,
>> you will also be able to leverage the simplified programming model of
>> EJB3.
>>
>> Thanks,
>> Gianny
>>
>>
>>
> 
> 

-- 
View this message in context: http://www.nabble.com/ClassCastException-when-using-a-self-written-TypeConverter-tf4029440s134.html#a11447283
Sent from the Apache Geronimo - Users mailing list archive at Nabble.com.


Mime
View raw message