cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Antonio Gallardo" <agalla...@agssa.net>
Subject Re: building Collection from JDO problems
Date Sat, 21 Feb 2004 22:37:05 GMT
Hi Bert:

It looks like a table game :-)

Well you went to the next step and you are faced with the next trivia :-D

AFAIK, the problem is that you need to JDO "enhance" your classes. See the
build.xml that Druid did for you. Also remeber you need to use jdo 1.01
NOT jdo 1.00

Best Regards,

Antonio Gallardo


Bert Van Kets dijo:
> And the woes continue... :-(
>
> The LinkDAO class is now instantiated, but when I get to building the
> Query
> I get an error saying I don't implement javax.jdo.spi.persistenceCapable
> on
> the class used for putting data in my collection. No document references
> the
> need for a persistanceCapable implementation in this situation.
> Full stack trace below.
>
> When debugging in Eclipse, javaw.exe (Tomcat) even throws me a bug crash.
>
> Here's the code again I use to retreive the data. Am I missing a step? The
> OJB docs don't tell me a lot. :-/
>
> public void retrieve(LinksBean bean, JdoPMF pmf) {
>   /* 1. Get the PersistenceManager */
>   PersistenceManager persistenceManager = pmf.getPersistenceManager();
>   // 2. start transaction
>   persistenceManager.currentTransaction().begin();
>   Query query = persistenceManager.newQuery(Link.class);
>   Collection thisCollection = (Collection) query.execute();
>   bean.setLinks(thisCollection);
>   // 3. End transaction
>   persistenceManager.currentTransaction().commit();
> }
>
> Any help is appreciated.
>
> Bert
>
> Original Exception: javax.jdo.JDOUserException: Class given to getExtent,
> be.bvar.admin.links.Link,  does not implement
> javax.jdo.spi.PersistenceCapable
> 	at com.sun.jdori.common.PersistenceManagerImpl.getExtent(Unknown Source)
> 	at com.sun.jdori.common.query.QueryImpl.checkCandidates(Unknown Source)
> 	at com.sun.jdori.common.query.QueryImpl.execute(Unknown Source)
> 	at be.bvar.admin.links.LinksDAO.retrieve(LinksDAO.java:26)
> 	at java.lang.reflect.Method.invoke(Native Method)
> 	at
> org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:230)
> 	at org.mozilla.javascript.ScriptRuntime.call(ScriptRuntime.java:1244)
> 	at
> org.mozilla.javascript.continuations.ContinuationInterpreter.interpret(Conti
> nuationInterpreter.java:1105)
> 	at
> org.mozilla.javascript.continuations.ContinuationInterpreter.interpret(Conti
> nuationInterpreter.java:190)
> 	at
> org.mozilla.javascript.continuations.ContinuationInterpreter.interpret(Conti
> nuationInterpreter.java:138)
> 	at
> org.mozilla.javascript.continuations.InterpretedFunctionImpl.call(Interprete
> dFunctionImpl.java:121)
> 	at org.mozilla.javascript.ScriptRuntime.call(ScriptRuntime.java:1244)
> 	at
> org.apache.cocoon.components.flow.javascript.fom.FOM_JavaScriptInterpreter.c
> allFunction(FOM_JavaScriptInterpreter.java:719)
> 	at
> org.apache.cocoon.components.treeprocessor.sitemap.CallFunctionNode.invoke(C
> allFunctionNode.java:160)
> 	at
> org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo
> keNodes(AbstractParentProcessingNode.java:84)
> 	at
> org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invok
> e(PreparableMatchNode.java:165)
> 	at
> org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo
> keNodes(AbstractParentProcessingNode.java:107)
> 	at
> org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(Pipel
> ineNode.java:162)
> 	at
> org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo
> keNodes(AbstractParentProcessingNode.java:107)
> 	at
> org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(Pipe
> linesNode.java:136)
> 	at
> org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess
> or.java:371)
> 	at
> org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess
> or.java:312)
> 	at
> org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNod
> e.java:133)
> 	at
> org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo
> keNodes(AbstractParentProcessingNode.java:84)
> 	at
> org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invok
> e(PreparableMatchNode.java:165)
> 	at
> org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo
> keNodes(AbstractParentProcessingNode.java:107)
> 	at
> org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(Pipel
> ineNode.java:162)
> 	at
> org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo
> keNodes(AbstractParentProcessingNode.java:107)
> 	at
> org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(Pipe
> linesNode.java:136)
> 	at
> org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess
> or.java:371)
> 	at
> org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess
> or.java:312)
> 	at org.apache.cocoon.Cocoon.process(Cocoon.java:656)
> 	at
> org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1112)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
> FilterChain.java:247)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
> ain.java:193)
> 	at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
> va:256)
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:643)
> 	at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
> va:191)
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:643)
> 	at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at
> org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2417)
> 	at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180
> )
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:643)
> 	at
> org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.
> java:171)
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:641)
> 	at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172
> )
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:641)
> 	at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
> :174)
> 	at
> org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
> eNext(StandardPipeline.java:643)
> 	at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at
> org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:193)
> 	at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:781)
> 	at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConne
> ction(Http11Protocol.java:549)
> 	at
> org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:589)
> 	at
> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
> a:666)
> 	at java.lang.Thread.run(Thread.java:479)
>
>
>
> ---------------------------------------------------------------------
> 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


Mime
View raw message