cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bill Bruyn (JIRA)" <j...@apache.org>
Subject [jira] Commented: (COCOON-1817) Dynamic forms with libraries: java.net.MalformedURLException
Date Wed, 29 Mar 2006 16:19:19 GMT
    [ http://issues.apache.org/jira/browse/COCOON-1817?page=comments#action_12372276 ] 

Bill Bruyn commented on COCOON-1817:
------------------------------------

Oops.  Forgot the stack trace:

org.apache.cocoon.ProcessingException: Error calling flowscript function oof
	at resource://org/apache/cocoon/forms/flow/javascript/Form.js:47:-1
	at file:/C:/Program Files/jakarta-tomcat-5.5.9/webapps/docgen/document-wizard/flow/main.js:56:-1
	at <map:call> - file:/C:/Program%20Files/jakarta-tomcat-5.5.9/webapps/docgen/document-wizard/sitemap.xmap:47:31
	at <map:mount> - file:/C:/Program%20Files/jakarta-tomcat-5.5.9/webapps/docgen/sitemap.xmap:662:66
	at org.apache.cocoon.ProcessingException.throwLocated(ProcessingException.java:144)
	at org.apache.cocoon.components.flow.javascript.LocationTrackingDebugger.getException(LocationTrackingDebugger.java:132)
	at org.apache.cocoon.components.flow.javascript.fom.FOM_JavaScriptInterpreter.callFunction(FOM_JavaScriptInterpreter.java:760)
	at org.apache.cocoon.components.treeprocessor.sitemap.CallFunctionNode.invoke(CallFunctionNode.java:138)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:46)
	at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:130)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
	at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:142)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
	at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:92)
	at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:234)
	at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:176)
	at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:248)
	at org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNode.java:117)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:46)
	at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:130)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
	at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:142)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
	at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:92)
	at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:234)
	at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:176)
	at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:248)
	at org.apache.cocoon.Cocoon.process(Cocoon.java:679)
	at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1154)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:407)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
	at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
	at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
	at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
	at java.lang.Thread.run(Thread.java:595)
Caused by: org.apache.cocoon.forms.formmodel.library.LibraryException: Could not include library
'cocoon:/forms/library.xml'
	at org.apache.cocoon.forms.formmodel.library.Library.includeAs(Library.java:108)
	at org.apache.cocoon.forms.formmodel.ImportDefinitionBuilder.buildWidgetDefinition(ImportDefinitionBuilder.java:44)
	at org.apache.cocoon.forms.formmodel.AbstractWidgetDefinitionBuilder.buildWidgetDefinition(AbstractWidgetDefinitionBuilder.java:65)
	at org.apache.cocoon.forms.formmodel.AbstractWidgetDefinitionBuilder.buildAnotherWidgetDefinition(AbstractWidgetDefinitionBuilder.java:160)
	at org.apache.cocoon.forms.formmodel.AbstractContainerDefinitionBuilder.setupContainer(AbstractContainerDefinitionBuilder.java:59)
	at org.apache.cocoon.forms.formmodel.FormDefinitionBuilder.buildWidgetDefinition(FormDefinitionBuilder.java:54)
	at org.apache.cocoon.forms.DefaultFormManager.getFormDefinition(DefaultFormManager.java:179)
	at org.apache.cocoon.forms.DefaultFormManager.createForm(DefaultFormManager.java:136)
	at sun.reflect.GeneratedMethodAccessor202.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	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(ContinuationInterpreter.java:1134)
	at org.mozilla.javascript.continuations.ContinuationInterpreter.interpret(ContinuationInterpreter.java:190)
	at org.mozilla.javascript.continuations.ContinuationInterpreter.interpret(ContinuationInterpreter.java:138)
	at org.mozilla.javascript.continuations.InterpretedFunctionImpl.call(InterpretedFunctionImpl.java:121)
	at org.mozilla.javascript.ScriptRuntime.call(ScriptRuntime.java:1244)
	at org.apache.cocoon.components.flow.javascript.fom.FOM_JavaScriptInterpreter.callFunction(FOM_JavaScriptInterpreter.java:758)
	... 38 more
Caused by: java.net.MalformedURLException: BaseURI is not valid, it must contain a protocol:
[unknown location]
	at org.apache.excalibur.source.impl.SourceResolverImpl.resolveURI(SourceResolverImpl.java:171)
	at org.apache.cocoon.components.CocoonComponentManager.resolveURI(CocoonComponentManager.java:541)
	at org.apache.cocoon.forms.formmodel.library.LibraryManagerImpl.getLibrary(LibraryManagerImpl.java:134)
	at org.apache.cocoon.forms.formmodel.library.Library.includeAs(Library.java:101)
	... 56 more


java.net.MalformedURLException: BaseURI is not valid, it must contain a protocol: [unknown
location]
	at org.apache.excalibur.source.impl.SourceResolverImpl.resolveURI(SourceResolverImpl.java:171)
	at org.apache.cocoon.components.CocoonComponentManager.resolveURI(CocoonComponentManager.java:541)
	at org.apache.cocoon.forms.formmodel.library.LibraryManagerImpl.getLibrary(LibraryManagerImpl.java:134)
	at org.apache.cocoon.forms.formmodel.library.Library.includeAs(Library.java:101)
	at org.apache.cocoon.forms.formmodel.ImportDefinitionBuilder.buildWidgetDefinition(ImportDefinitionBuilder.java:44)
	at org.apache.cocoon.forms.formmodel.AbstractWidgetDefinitionBuilder.buildWidgetDefinition(AbstractWidgetDefinitionBuilder.java:65)
	at org.apache.cocoon.forms.formmodel.AbstractWidgetDefinitionBuilder.buildAnotherWidgetDefinition(AbstractWidgetDefinitionBuilder.java:160)
	at org.apache.cocoon.forms.formmodel.AbstractContainerDefinitionBuilder.setupContainer(AbstractContainerDefinitionBuilder.java:59)
	at org.apache.cocoon.forms.formmodel.FormDefinitionBuilder.buildWidgetDefinition(FormDefinitionBuilder.java:54)
	at org.apache.cocoon.forms.DefaultFormManager.getFormDefinition(DefaultFormManager.java:179)
	at org.apache.cocoon.forms.DefaultFormManager.createForm(DefaultFormManager.java:136)
	at sun.reflect.GeneratedMethodAccessor202.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	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(ContinuationInterpreter.java:1134)
	at org.mozilla.javascript.continuations.ContinuationInterpreter.interpret(ContinuationInterpreter.java:190)
	at org.mozilla.javascript.continuations.ContinuationInterpreter.interpret(ContinuationInterpreter.java:138)
	at org.mozilla.javascript.continuations.InterpretedFunctionImpl.call(InterpretedFunctionImpl.java:121)
	at org.mozilla.javascript.ScriptRuntime.call(ScriptRuntime.java:1244)
	at org.apache.cocoon.components.flow.javascript.fom.FOM_JavaScriptInterpreter.callFunction(FOM_JavaScriptInterpreter.java:758)
	at org.apache.cocoon.components.treeprocessor.sitemap.CallFunctionNode.invoke(CallFunctionNode.java:138)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:46)
	at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:130)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
	at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:142)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
	at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:92)
	at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:234)
	at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:176)
	at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:248)
	at org.apache.cocoon.components.treeprocessor.sitemap.MountNode.invoke(MountNode.java:117)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:46)
	at org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:130)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
	at org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:142)
	at org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:68)
	at org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:92)
	at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:234)
	at org.apache.cocoon.components.treeprocessor.ConcreteTreeProcessor.process(ConcreteTreeProcessor.java:176)
	at org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:248)
	at org.apache.cocoon.Cocoon.process(Cocoon.java:679)
	at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1154)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:407)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
	at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
	at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
	at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
	at java.lang.Thread.run(Thread.java:595)


> Dynamic forms with libraries:  java.net.MalformedURLException
> -------------------------------------------------------------
>
>          Key: COCOON-1817
>          URL: http://issues.apache.org/jira/browse/COCOON-1817
>      Project: Cocoon
>         Type: Bug
>   Components: Blocks: Forms
>     Versions: 2.1.8
>     Reporter: Bill Bruyn
>  Attachments: cocoon-scratchpad.zip
>
> I am trying to build forms dynamically from a jx template, and am able to do so like
this:
>     var form = new Form("cocoon:/forms/" + name + ".jx"); 
> But I get MalformedURLExceptions[1] at form instantiation when I try it like this:
>     var obj = "Here is some bizData to be used in building the dynamic form from a JX
template...";
>     var model = pipelines.processToDOM("forms/" + name + ".jx", {bizData : obj});
>     var form = new Form(model.getDocumentElement());
> and my form definition references a library:
> <fd:form  xmlns:fd="http://apache.org/cocoon/forms/1.0#definition">
>   <fd:widgets>
>     
>     <fd:import prefix="lib" uri="cocoon://form-libraries/model/sample.xml"/>  
 
>     <fd:expand id="lib:account"/>
>     
>   </fd:widgets>
> </fd:form>
> Attached is a small app that illustrates the problem.  You should be able to unzip it
and
> 1)  modify build.properties for your environment
> 2)  ant cocoon:get
> 3)  ant build
> http://localhost:8080/scratchpad/sandbox should work as-is.  To induce the error, edit
sandbox/flow/main.js (see comments inline)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message