Hi,

did you deployed commons-dbcp and xbean?

- Romain


2011/11/25 Charles Moulliard <[email protected]>

> If somebody has an idea ;-)
>
> ---------- Forwarded message ----------
> From: Charles Moulliard <[email protected]>
> Date: Fri, Nov 25, 2011 at 6:38 PM
> Subject: Very strange issue
> To: dev <[email protected]>
>
>
> Hi,
>
> I have a very strange problem in this part of the code of openejb
> using apache geronimo xbean
>
> My bundle imports/exports well the following package :
>
> karaf@root> packages:exports | grep org.apache.openejb.resource.jdbc
>   128 org.apache.openejb.resource.jdbc; version=4.0.0.beta-2-SNAPSHOT
>
> karaf@root> packages:imports | grep org.apache.openejb.resource.jdbc
> Apache OpenEJB :: Container :: Core (128):
> org.apache.openejb.resource.jdbc; version=4.0.0.beta-2-SNAPSHOT
> Apache OpenEJB :: Container :: Core (128):
> org.apache.openejb.resource.jdbc; version=4.0.0.beta-2-SNAPSHOT
>
> but when Apache Xbean through org.apache.xbean.recipe.RecipeHelper
> method is called
>
>    public Class getType() {
>        if (typeClass != null || typeName != null) {
>            Class type = typeClass;
>            if (type == null) {
>                try {
>                    type = RecipeHelper.loadClass(typeName);
>                } catch (ClassNotFoundException e) {
>                    throw new ConstructionException("Type class could
> not be found: " + typeName);
>                }
>            }
>
>            return type;
>        }
>
>        return null;
>    }
>
> -->
>
>    public static Class loadClass(String name) throws
> ClassNotFoundException {
>        ClassLoader classLoader =
> ExecutionContext.getContext().getClassLoader();
>        Class<?> type = Class.forName(name, true, classLoader);
>        return type;
>    }
>
> It generates the following error
>
> Caused by: org.apache.xbean.recipe.ConstructionException: Type class
> could not be found: org.apache.openejb.resource.jdbc.DataSourceFactory
>        at
> org.apache.xbean.recipe.ObjectRecipe.getType(ObjectRecipe.java:355)
>        at
> org.apache.xbean.recipe.ObjectRecipe.internalCreate(ObjectRecipe.java:266)
>        at
> org.apache.xbean.recipe.AbstractRecipe.create(AbstractRecipe.java:96)
>        at
> org.apache.xbean.recipe.AbstractRecipe.create(AbstractRecipe.java:61)
>        at
> org.apache.xbean.recipe.AbstractRecipe.create(AbstractRecipe.java:49)
>        at
> org.apache.openejb.assembler.classic.Assembler.createResource(Assembler.java:1418)
>        at
> org.apache.openejb.assembler.classic.Assembler.buildContainerSystem(Assembler.java:395)
>        at
> org.apache.openejb.assembler.classic.Assembler.build(Assembler.java:318)
>
> See screenshot for the classloader used (felix)
> http://cl.ly/1W2N083K3f0U022A151v
>
> Any hep is welcome ?
>
> Regards,
>
> Charles Moulliard
>
> Apache Committer
>
> Blog : http://cmoulliard.blogspot.com
> Twitter : http://twitter.com/cmoulliard
> Linkedin : http://www.linkedin.com/in/charlesmoulliard
> Skype: cmoulliard
>

Reply via email to