You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Heiner Braun privat <h....@onlinehome.de> on 2003/11/10 22:04:43 UTC

trying to test the latest woody hibernate flowscript example


Hugo Burm wrote:

>On Sunday 09 November 2003 02:50 pm, you wrote:
>  
>
>>I got your xmlform-example running with cocoon-2.1rc1-dev.
>>But I have problems with your woody example. I tried it now with
>>cocoon-2.1rc3-dev.
>>But when I start cocoon I get the error :
>>For element list  the attribute role and the attribute name are missing
>>although role is no list attribute  and name is given.
>>Best regards
>>Heiner
>>    
>>
>
>
>I uploaded a new verzion (zip archive) to the Wiki page around 15.30h today 
>(sunday). So if your clock is displaying the correct time,  I guess you are 
>using the old version. Try the newest one.
>The problem you detected arises from a wrong DTD in the header of the 
>Hibernate xmb configuration file.
>Should be -2.0
>
>Regards
>
>Hugo
>
>
>  
>
I installed the latest version of cocoon 2.1 from the cvs and your latest hibernatewoody-example.

When I start cocoon I get the following protocoll :
./cocoon.sh: using ./build/webapp as the webapp directory
-------------------- Loading --------------------
Processing repository: ./tools/jetty/lib
Adding jar: ./tools/jetty/lib/jetty-4.2.9.jar
Adding jar: ./tools/jetty/lib/servlet-2.3.jar
Processing repository: ./lib/endorsed
Adding jar: ./lib/endorsed/xalan-2.5.2.jar
Adding jar: ./lib/endorsed/xercesImpl-2.5.0.jar
Adding jar: ./lib/endorsed/xml-apis.jar
-------------------- Executing -----------------
Main Class: org.mortbay.jetty.Server
01:06:31.771 EVENT  Starting Jetty/4.2.9
01:06:34.561 EVENT  Started WebApplicationContext[/,./build/webapp]
Hibernate factory instance created
Hibernate service called
Hibernate configure called
11.11.2003 01:06:41 net.sf.hibernate.cfg.Environment <clinit>
INFO: Hibernate 2.1 beta 5
11.11.2003 01:06:41 net.sf.hibernate.cfg.Environment <clinit>
INFO: loaded properties from resource hibernate.properties: 
{hibernate.connection.username=makler, 
hibernate.connection.password=Braun, 
hibernate.cglib.use_reflection_optimizer=true, 
hibernate.dialect=net.sf.hibernate.dialect.MySQLDialect, 
hibernate.connection.url=jdbc:mysql://localhost:3306/test, 
hibernate.connection.driver_class=com.mysql.jdbc.Driver}
11.11.2003 01:06:41 net.sf.hibernate.cfg.Environment <clinit>
INFO: using CGLIB reflection optimizer
11.11.2003 01:06:41 net.sf.hibernate.cfg.Configuration addClass
INFO: Mapping resource: org/apache/cocoon/woody/samples/Form2Bean.hbm.xml
11.11.2003 01:06:43 net.sf.hibernate.cfg.Binder bindRootClass
INFO: Mapping class: org.apache.cocoon.woody.samples.Form2Bean -> form2bean
Exception in thread "main" java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:324)
        at Loader.invokeMain(Unknown Source)
        at Loader.run(Unknown Source)
        at Loader.main(Unknown Source)
Caused by: java.lang.NoClassDefFoundError: 
org/apache/cocoon/woody/datatype/Enum
        at java.lang.ClassLoader.defineClass0(Native Method)
        at java.lang.ClassLoader.defineClass(ClassLoader.java:537)
        at 
java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
        at java.net.URLClassLoader.defineClass(URLClassLoader.java:251)
        at java.net.URLClassLoader.access$100(URLClassLoader.java:55)
        at java.net.URLClassLoader$1.run(URLClassLoader.java:194)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
        at org.mortbay.http.ContextLoader.loadClass(ContextLoader.java:225)
        at org.mortbay.http.ContextLoader.loadClass(ContextLoader.java:198)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
        at java.lang.Class.getDeclaredMethods0(Native Method)
        at java.lang.Class.privateGetDeclaredMethods(Class.java:1647)
        at java.lang.Class.getDeclaredMethods(Class.java:1131)
        at 
net.sf.hibernate.property.BasicPropertyAccessor.getterMethod(BasicPropertyAccessor.java:215)
        at 
net.sf.hibernate.property.BasicPropertyAccessor.getGetterOrNull(BasicPropertyAccessor.java:195)
        at 
net.sf.hibernate.property.BasicPropertyAccessor.getGetter(BasicPropertyAccessor.java:185)
        at 
net.sf.hibernate.util.ReflectHelper.reflectedPropertyType(ReflectHelper.java:57)
        at net.sf.hibernate.mapping.Value.setTypeByReflection(Value.java:92)
        at net.sf.hibernate.cfg.Binder.createProperty(Binder.java:953)
        at net.sf.hibernate.cfg.Binder.propertiesFromXML(Binder.java:946)
        at net.sf.hibernate.cfg.Binder.bindRootClass(Binder.java:313)
        at net.sf.hibernate.cfg.Binder.bindRoot(Binder.java:1143)
        at net.sf.hibernate.cfg.Configuration.add(Configuration.java:243)
        at 
net.sf.hibernate.cfg.Configuration.addInputStream(Configuration.java:266)
        at 
net.sf.hibernate.cfg.Configuration.addClass(Configuration.java:307)
        at 
org.apache.cocoon.woody.samples.HibernateFactory.initialize(HibernateFactory.java:80)
        at 
org.apache.avalon.framework.container.ContainerUtil.initialize(ContainerUtil.java:282)
        at 
org.apache.avalon.excalibur.component.DefaultComponentFactory.newInstance(DefaultComponentFactory.java:310)
        at 
org.apache.avalon.excalibur.component.ThreadSafeComponentHandler.initialize(ThreadSafeComponentHandler.java:143)
        at 
org.apache.avalon.excalibur.component.ExcaliburComponentManager.initialize(ExcaliburComponentManager.java:556)
        at 
org.apache.cocoon.components.CocoonComponentManager.initialize(CocoonComponentManager.java:547)
        at 
org.apache.avalon.framework.container.ContainerUtil.initialize(ContainerUtil.java:282)
        at org.apache.cocoon.Cocoon.initialize(Cocoon.java:340)
        at 
org.apache.avalon.framework.container.ContainerUtil.initialize(ContainerUtil.java:282)
        at 
org.apache.cocoon.servlet.CocoonServlet.createCocoon(CocoonServlet.java:1369)
        at 
org.apache.cocoon.servlet.CocoonServlet.init(CocoonServlet.java:515)
        at 
org.mortbay.jetty.servlet.ServletHolder.start(ServletHolder.java:219)
        at 
org.mortbay.jetty.servlet.ServletHandler.initializeServlets(ServletHandler.java:436)
        at 
org.mortbay.jetty.servlet.WebApplicationHandler.initializeServlets(WebApplicationHandler.java:150)
        at 
org.mortbay.jetty.servlet.WebApplicationContext.start(WebApplicationContext.java:442)
        at org.mortbay.http.HttpServer.start(HttpServer.java:647)
        at org.mortbay.jetty.Server.main(Server.java:429)
        ... 7 more


Re: trying to test the latest woody hibernate flowscript example

Posted by Ugo Cei <u....@cbim.it>.
Hugo Burm wrote:
> I added three compiled Woody class Form2Bean,Contact,en Sex in
> \WEB-INF\classes\org\apache\cocoon\woody\samples in the download zip.
> The enumeration is used in Sex. The enumeration appears to be removed now
> from Woody.

I'm sorry to have caused this little trouble, but the enumeration 
support in Woody is to be considered a little less than alpha-quality 
code, more like a proof of concept. Indeed, I haven't documented it at 
all. Expect it to be relatively stable as soon as I have added the 
javadoc comments, a Wiki page and maybe a few test cases.

	Ugo



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


RE: trying to test the latest woody hibernate flowscript example

Posted by Hugo Burm <hu...@xs4all.nl>.
I added three compiled Woody class Form2Bean,Contact,en Sex in
\WEB-INF\classes\org\apache\cocoon\woody\samples in the download zip.
The enumeration is used in Sex. The enumeration appears to be removed now
from Woody.
Try to use the newest compiled versions that come with the latest CVS
version of Cocoon and are in sync with Woody. If that does not work, I
included the Woody sources of these classes, so you can find out what has
changed. I did not modify these classes, I included them to tackle problems
like this.

Hugo

> -----Original Message-----
> From: Ugo Cei [mailto:u.cei@cbim.it]
> Sent: Monday, November 10, 2003 11:58 PM
> To: users@cocoon.apache.org
> Subject: Re: trying to test the latest woody hibernate flowscript
> example
>
>
> Heiner Braun privat wrote:
> > Caused by: java.lang.NoClassDefFoundError:
> > org/apache/cocoon/woody/datatype/Enum
>
> This class was removed from CVS yesterday. I suspect the
> hibernate-flowscript example code used it, but now it's gone,
> being useless.
>
> 	Ugo
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: trying to test the latest woody hibernate flowscript example

Posted by Ugo Cei <u....@cbim.it>.
Heiner Braun privat wrote:
> Caused by: java.lang.NoClassDefFoundError: 
> org/apache/cocoon/woody/datatype/Enum

This class was removed from CVS yesterday. I suspect the 
hibernate-flowscript example code used it, but now it's gone, being useless.

	Ugo


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org