You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@shale.apache.org by Colin Chalmers <co...@xs4all.nl> on 2007/02/28 19:22:10 UTC

Trouble with simple dialog

Hi,

I'm experimenting with the dialog manager and seem to have ommitted a 
setting somewhere which is throwing an exception.

Basically I'm just hitting one page and after clicking a button I should 
be brought to the next page, however this is not happening.
In the logs I see the following exception:

<exception>
2007-02-28 15:53:54 StandardContext[/shale]null
java.lang.NullPointerException
    at 
org.apache.shale.dialog.faces.DialogNavigationHandler.handleNavigation(DialogNavigationHandler.java:121)
    at 
org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:84)
    at 
org.apache.shale.view.faces.ViewActionListener.processAction(ViewActionListener.java:74)
    at javax.faces.component.UICommand.broadcast(UICommand.java:106)
    at 
javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
    at 
javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
    at 
org.apache.shale.view.faces.ShaleViewRoot.processApplication(ShaleViewRoot.java:40)
    at 
org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:316)
    at 
org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
    at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
    at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
    at 
org.apache.shale.application.faces.ShaleApplicationFilter.doFilter(ShaleApplicationFilter.java:267)
    at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
    at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
    at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
    at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
    at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
    at 
org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
    at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
    at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
    at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
    at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
    at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
    at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
    at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
    at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
    at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
    at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
    at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
    at 
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
    at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
    at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
    at 
org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
    at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
    at java.lang.Thread.run(Thread.java:534)
</exception>

My dialog-config files looks like the following

<dialogs>
  <dialog name="Create New Dialog" start="Input">
    <transition outcome="start" target="Input"/>
     <transition outcome="exit" target="Exit"/>
        
    <view name="Input" viewId="/input.jsf" >                   
          <transition outcome="next" target="Register"/>
   </view>
   
    <end name="Exit" viewId="/goodBye.jsf"/>
      
 </dialog>
</dialogs>

& th epage itself contains

    <h:form id="start">
        <h:commandButton id="startDialog" action="dialog:Create New 
Dialog" value="Create New Dialog >>" />
    </h:form>

Currently I've no idea why it's not working :-((

Any help or links to examples would be much appreciated!!

Thx

/Colin



SV: SV: Trouble with simple dialog

Posted by Hermod Opstvedt <he...@opstvedt.com>.
Hi

It's not required - The I asked was that it is null, meaning that if had
declared it empty that would explain the NullPointerException.

What version of Shale and Shale-dialog are you using?

Hermod

-----Opprinnelig melding-----
Fra: Colin Chalmers [mailto:colnews@xs4all.nl] 
Sendt: 28. februar 2007 21:53
Til: user@shale.apache.org
Emne: Re: SV: Trouble with simple dialog

Hi Hermod,

Thx for the reply.

The "Register" target is a copyPaste error, but even ommitting that 
transition doesn't affect the stack-trace.

I haven't defined the context-param you mention and was unaware that it 
was required, I thought the default setting was dialog?
Can you point me to info concerning this?

/Colin

Hermod Opstvedt wrote:

>Hi
>
>Just quickly looking at your dialog file, I notice that you have a target
>"Register" that is not defined.
>
>Looking at the code, the problem is that the web.xml context-param
>Constants.DIALOG_PREFIX_PARAM is missing or ill defined. Have you defined
>it?
>
>Hermod
>
>
>-----Opprinnelig melding-----
>Fra: Colin Chalmers [mailto:colnews@xs4all.nl] 
>Sendt: 28. februar 2007 19:22
>Til: user@shale.apache.org
>Emne: Trouble with simple dialog
>
>Hi,
>
>I'm experimenting with the dialog manager and seem to have ommitted a 
>setting somewhere which is throwing an exception.
>
>Basically I'm just hitting one page and after clicking a button I should 
>be brought to the next page, however this is not happening.
>In the logs I see the following exception:
>
><exception>
>2007-02-28 15:53:54 StandardContext[/shale]null
>java.lang.NullPointerException
>    at 
>org.apache.shale.dialog.faces.DialogNavigationHandler.handleNavigation(Dial
o
>gNavigationHandler.java:121)
>    at 
>org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListe
n
>erImpl.java:84)
>    at 
>org.apache.shale.view.faces.ViewActionListener.processAction(ViewActionList
e
>ner.java:74)
>    at javax.faces.component.UICommand.broadcast(UICommand.java:106)
>    at 
>javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
>    at 
>javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
>    at 
>org.apache.shale.view.faces.ShaleViewRoot.processApplication(ShaleViewRoot.
j
>ava:40)
>    at 
>org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.
j
>ava:316)
>    at 
>org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
>    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applicatio
n
>FilterChain.java:237)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterC
h
>ain.java:157)
>    at 
>org.apache.shale.application.faces.ShaleApplicationFilter.doFilter(ShaleApp
l
>icationFilter.java:267)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applicatio
n
>FilterChain.java:186)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterC
h
>ain.java:157)
>    at 
>org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.j
a
>va:214)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveConte
x
>t.java:104)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at 
>org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContex
t
>Valve.java:198)
>    at 
>org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.j
a
>va:152)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveConte
x
>t.java:104)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at 
>org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:13
7
>)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveConte
x
>t.java:104)
>    at 
>org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:11
8
>)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveConte
x
>t.java:102)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at 
>org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.jav
a
>:109)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveConte
x
>t.java:104)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
>    at 
>org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
>    at 
>org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
>    at 
>org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConn
e
>ction(Http11Protocol.java:705)
>    at 
>org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
>    at 
>org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.ja
v
>a:683)
>    at java.lang.Thread.run(Thread.java:534)
></exception>
>
>My dialog-config files looks like the following
>
><dialogs>
>  <dialog name="Create New Dialog" start="Input">
>    <transition outcome="start" target="Input"/>
>     <transition outcome="exit" target="Exit"/>
>        
>    <view name="Input" viewId="/input.jsf" >                   
>          <transition outcome="next" target="Register"/>
>   </view>
>   
>    <end name="Exit" viewId="/goodBye.jsf"/>
>      
> </dialog>
></dialogs>
>
>& th epage itself contains
>
>    <h:form id="start">
>        <h:commandButton id="startDialog" action="dialog:Create New 
>Dialog" value="Create New Dialog >>" />
>    </h:form>
>
>Currently I've no idea why it's not working :-((
>
>Any help or links to examples would be much appreciated!!
>
>Thx
>
>/Colin
>
>
>
>
>  
>


Re: SV: Trouble with simple dialog

Posted by Colin Chalmers <co...@xs4all.nl>.
Hi Hermod,

Thx for the reply.

The "Register" target is a copyPaste error, but even ommitting that 
transition doesn't affect the stack-trace.

I haven't defined the context-param you mention and was unaware that it 
was required, I thought the default setting was dialog?
Can you point me to info concerning this?

/Colin

Hermod Opstvedt wrote:

>Hi
>
>Just quickly looking at your dialog file, I notice that you have a target
>"Register" that is not defined.
>
>Looking at the code, the problem is that the web.xml context-param
>Constants.DIALOG_PREFIX_PARAM is missing or ill defined. Have you defined
>it?
>
>Hermod
>
>
>-----Opprinnelig melding-----
>Fra: Colin Chalmers [mailto:colnews@xs4all.nl] 
>Sendt: 28. februar 2007 19:22
>Til: user@shale.apache.org
>Emne: Trouble with simple dialog
>
>Hi,
>
>I'm experimenting with the dialog manager and seem to have ommitted a 
>setting somewhere which is throwing an exception.
>
>Basically I'm just hitting one page and after clicking a button I should 
>be brought to the next page, however this is not happening.
>In the logs I see the following exception:
>
><exception>
>2007-02-28 15:53:54 StandardContext[/shale]null
>java.lang.NullPointerException
>    at 
>org.apache.shale.dialog.faces.DialogNavigationHandler.handleNavigation(Dialo
>gNavigationHandler.java:121)
>    at 
>org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListen
>erImpl.java:84)
>    at 
>org.apache.shale.view.faces.ViewActionListener.processAction(ViewActionListe
>ner.java:74)
>    at javax.faces.component.UICommand.broadcast(UICommand.java:106)
>    at 
>javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
>    at 
>javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
>    at 
>org.apache.shale.view.faces.ShaleViewRoot.processApplication(ShaleViewRoot.j
>ava:40)
>    at 
>org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.j
>ava:316)
>    at 
>org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
>    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
>FilterChain.java:237)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
>ain.java:157)
>    at 
>org.apache.shale.application.faces.ShaleApplicationFilter.doFilter(ShaleAppl
>icationFilter.java:267)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
>FilterChain.java:186)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
>ain.java:157)
>    at 
>org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
>va:214)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
>t.java:104)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at 
>org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContext
>Valve.java:198)
>    at 
>org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
>va:152)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
>t.java:104)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at 
>org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137
>)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
>t.java:104)
>    at 
>org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118
>)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
>t.java:102)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at 
>org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
>:109)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
>t.java:104)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
>    at 
>org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
>    at 
>org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
>    at 
>org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConne
>ction(Http11Protocol.java:705)
>    at 
>org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
>    at 
>org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
>a:683)
>    at java.lang.Thread.run(Thread.java:534)
></exception>
>
>My dialog-config files looks like the following
>
><dialogs>
>  <dialog name="Create New Dialog" start="Input">
>    <transition outcome="start" target="Input"/>
>     <transition outcome="exit" target="Exit"/>
>        
>    <view name="Input" viewId="/input.jsf" >                   
>          <transition outcome="next" target="Register"/>
>   </view>
>   
>    <end name="Exit" viewId="/goodBye.jsf"/>
>      
> </dialog>
></dialogs>
>
>& th epage itself contains
>
>    <h:form id="start">
>        <h:commandButton id="startDialog" action="dialog:Create New 
>Dialog" value="Create New Dialog >>" />
>    </h:form>
>
>Currently I've no idea why it's not working :-((
>
>Any help or links to examples would be much appreciated!!
>
>Thx
>
>/Colin
>
>
>
>
>  
>


Re: SV: Trouble with simple dialog

Posted by Colin Chalmers <co...@xs4all.nl>.
Hermod,

Sorry I see the info on the site. As far as I see I haven't deviated 
from the default dialog:foo type of value?

Are there any other params and/or phase-listeners I should be aware of?

For the sake of clarity I'm using version 1.0.4

/Colin

Hermod Opstvedt wrote:

>Hi
>
>Just quickly looking at your dialog file, I notice that you have a target
>"Register" that is not defined.
>
>Looking at the code, the problem is that the web.xml context-param
>Constants.DIALOG_PREFIX_PARAM is missing or ill defined. Have you defined
>it?
>
>Hermod
>
>
>-----Opprinnelig melding-----
>Fra: Colin Chalmers [mailto:colnews@xs4all.nl] 
>Sendt: 28. februar 2007 19:22
>Til: user@shale.apache.org
>Emne: Trouble with simple dialog
>
>Hi,
>
>I'm experimenting with the dialog manager and seem to have ommitted a 
>setting somewhere which is throwing an exception.
>
>Basically I'm just hitting one page and after clicking a button I should 
>be brought to the next page, however this is not happening.
>In the logs I see the following exception:
>
><exception>
>2007-02-28 15:53:54 StandardContext[/shale]null
>java.lang.NullPointerException
>    at 
>org.apache.shale.dialog.faces.DialogNavigationHandler.handleNavigation(Dialo
>gNavigationHandler.java:121)
>    at 
>org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListen
>erImpl.java:84)
>    at 
>org.apache.shale.view.faces.ViewActionListener.processAction(ViewActionListe
>ner.java:74)
>    at javax.faces.component.UICommand.broadcast(UICommand.java:106)
>    at 
>javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
>    at 
>javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
>    at 
>org.apache.shale.view.faces.ShaleViewRoot.processApplication(ShaleViewRoot.j
>ava:40)
>    at 
>org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.j
>ava:316)
>    at 
>org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
>    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
>FilterChain.java:237)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
>ain.java:157)
>    at 
>org.apache.shale.application.faces.ShaleApplicationFilter.doFilter(ShaleAppl
>icationFilter.java:267)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
>FilterChain.java:186)
>    at 
>org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
>ain.java:157)
>    at 
>org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
>va:214)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
>t.java:104)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at 
>org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContext
>Valve.java:198)
>    at 
>org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
>va:152)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
>t.java:104)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at 
>org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137
>)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
>t.java:104)
>    at 
>org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118
>)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
>t.java:102)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at 
>org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
>:109)
>    at 
>org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
>t.java:104)
>    at 
>org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
>    at 
>org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
>    at 
>org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
>    at 
>org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConne
>ction(Http11Protocol.java:705)
>    at 
>org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
>    at 
>org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
>a:683)
>    at java.lang.Thread.run(Thread.java:534)
></exception>
>
>My dialog-config files looks like the following
>
><dialogs>
>  <dialog name="Create New Dialog" start="Input">
>    <transition outcome="start" target="Input"/>
>     <transition outcome="exit" target="Exit"/>
>        
>    <view name="Input" viewId="/input.jsf" >                   
>          <transition outcome="next" target="Register"/>
>   </view>
>   
>    <end name="Exit" viewId="/goodBye.jsf"/>
>      
> </dialog>
></dialogs>
>
>& th epage itself contains
>
>    <h:form id="start">
>        <h:commandButton id="startDialog" action="dialog:Create New 
>Dialog" value="Create New Dialog >>" />
>    </h:form>
>
>Currently I've no idea why it's not working :-((
>
>Any help or links to examples would be much appreciated!!
>
>Thx
>
>/Colin
>
>
>
>
>  
>


SV: Trouble with simple dialog

Posted by Hermod Opstvedt <he...@opstvedt.com>.
Hi

Just quickly looking at your dialog file, I notice that you have a target
"Register" that is not defined.

Looking at the code, the problem is that the web.xml context-param
Constants.DIALOG_PREFIX_PARAM is missing or ill defined. Have you defined
it?

Hermod


-----Opprinnelig melding-----
Fra: Colin Chalmers [mailto:colnews@xs4all.nl] 
Sendt: 28. februar 2007 19:22
Til: user@shale.apache.org
Emne: Trouble with simple dialog

Hi,

I'm experimenting with the dialog manager and seem to have ommitted a 
setting somewhere which is throwing an exception.

Basically I'm just hitting one page and after clicking a button I should 
be brought to the next page, however this is not happening.
In the logs I see the following exception:

<exception>
2007-02-28 15:53:54 StandardContext[/shale]null
java.lang.NullPointerException
    at 
org.apache.shale.dialog.faces.DialogNavigationHandler.handleNavigation(Dialo
gNavigationHandler.java:121)
    at 
org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListen
erImpl.java:84)
    at 
org.apache.shale.view.faces.ViewActionListener.processAction(ViewActionListe
ner.java:74)
    at javax.faces.component.UICommand.broadcast(UICommand.java:106)
    at 
javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
    at 
javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
    at 
org.apache.shale.view.faces.ShaleViewRoot.processApplication(ShaleViewRoot.j
ava:40)
    at 
org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.j
ava:316)
    at 
org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
    at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:237)
    at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:157)
    at 
org.apache.shale.application.faces.ShaleApplicationFilter.doFilter(ShaleAppl
icationFilter.java:267)
    at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:186)
    at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:157)
    at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:214)
    at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
t.java:104)
    at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
    at 
org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContext
Valve.java:198)
    at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:152)
    at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
t.java:104)
    at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
    at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137
)
    at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
t.java:104)
    at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118
)
    at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
t.java:102)
    at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
    at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:109)
    at 
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContex
t.java:104)
    at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
    at 
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
    at 
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
    at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConne
ction(Http11Protocol.java:705)
    at 
org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
    at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
a:683)
    at java.lang.Thread.run(Thread.java:534)
</exception>

My dialog-config files looks like the following

<dialogs>
  <dialog name="Create New Dialog" start="Input">
    <transition outcome="start" target="Input"/>
     <transition outcome="exit" target="Exit"/>
        
    <view name="Input" viewId="/input.jsf" >                   
          <transition outcome="next" target="Register"/>
   </view>
   
    <end name="Exit" viewId="/goodBye.jsf"/>
      
 </dialog>
</dialogs>

& th epage itself contains

    <h:form id="start">
        <h:commandButton id="startDialog" action="dialog:Create New 
Dialog" value="Create New Dialog >>" />
    </h:form>

Currently I've no idea why it's not working :-((

Any help or links to examples would be much appreciated!!

Thx

/Colin



Re: Trouble with simple dialog

Posted by Colin Chalmers <co...@xs4all.nl>.
Craig,

That was indeed the issue, thx!

/Colin

Craig McClanahan wrote:

> On 2/28/07, Colin Chalmers <co...@xs4all.nl> wrote:
>
>> Hi,
>>
>> I'm experimenting with the dialog manager and seem to have ommitted a
>> setting somewhere which is throwing an exception.
>>
>> Basically I'm just hitting one page and after clicking a button I should
>> be brought to the next page, however this is not happening.
>> In the logs I see the following exception:
>>
>> <exception>
>> 2007-02-28 15:53:54 StandardContext[/shale]null
>> java.lang.NullPointerException
>>     at
>> org.apache.shale.dialog.faces.DialogNavigationHandler.handleNavigation(DialogNavigationHandler.java:121) 
>>
>>     at
>>
>
> Hmm ... the NPE here implies that the DialogContextManager managed
> bean (looked for in the line right above) cannot be found.  One way
> this could happen is if you didn't include the actual dialog manager
> implementation JAR (shale-dialog-basic-1.0.4.jar in this case) in
> addition to the API jar (shale-dialog-1.0.4.jar) in your webapp.
>
> Could you check that please?
>
> Craig
>
>
>
> org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:84) 
>
>
>>     at
>> org.apache.shale.view.faces.ViewActionListener.processAction(ViewActionListener.java:74) 
>>
>>     at javax.faces.component.UICommand.broadcast(UICommand.java:106)
>>     at
>> javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
>>     at
>> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
>>     at
>> org.apache.shale.view.faces.ShaleViewRoot.processApplication(ShaleViewRoot.java:40) 
>>
>>     at
>> org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:316) 
>>
>>     at
>> org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86) 
>>
>>     at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
>>     at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237) 
>>
>>     at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157) 
>>
>>     at
>> org.apache.shale.application.faces.ShaleApplicationFilter.doFilter(ShaleApplicationFilter.java:267) 
>>
>>     at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186) 
>>
>>     at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157) 
>>
>>     at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214) 
>>
>>     at
>> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) 
>>
>>     at
>> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) 
>>
>>     at
>> org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198) 
>>
>>     at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152) 
>>
>>     at
>> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) 
>>
>>     at
>> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) 
>>
>>     at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137) 
>>
>>     at
>> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) 
>>
>>     at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118) 
>>
>>     at
>> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102) 
>>
>>     at
>> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) 
>>
>>     at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) 
>>
>>     at
>> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104) 
>>
>>     at
>> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520) 
>>
>>     at 
>> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
>>     at
>> org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
>>     at
>> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799) 
>>
>>     at
>> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705) 
>>
>>     at
>> org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577) 
>>
>>     at
>> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683) 
>>
>>     at java.lang.Thread.run(Thread.java:534)
>> </exception>
>>
>> My dialog-config files looks like the following
>>
>> <dialogs>
>>   <dialog name="Create New Dialog" start="Input">
>>     <transition outcome="start" target="Input"/>
>>      <transition outcome="exit" target="Exit"/>
>>
>>     <view name="Input" viewId="/input.jsf" >
>>           <transition outcome="next" target="Register"/>
>>    </view>
>>
>>     <end name="Exit" viewId="/goodBye.jsf"/>
>>
>>  </dialog>
>> </dialogs>
>>
>> & th epage itself contains
>>
>>     <h:form id="start">
>>         <h:commandButton id="startDialog" action="dialog:Create New
>> Dialog" value="Create New Dialog >>" />
>>     </h:form>
>>
>> Currently I've no idea why it's not working :-((
>>
>> Any help or links to examples would be much appreciated!!
>>
>> Thx
>>
>> /Colin
>>
>>
>>
>
>


Re: Trouble with simple dialog

Posted by Craig McClanahan <cr...@apache.org>.
On 2/28/07, Colin Chalmers <co...@xs4all.nl> wrote:
> Hi,
>
> I'm experimenting with the dialog manager and seem to have ommitted a
> setting somewhere which is throwing an exception.
>
> Basically I'm just hitting one page and after clicking a button I should
> be brought to the next page, however this is not happening.
> In the logs I see the following exception:
>
> <exception>
> 2007-02-28 15:53:54 StandardContext[/shale]null
> java.lang.NullPointerException
>     at
> org.apache.shale.dialog.faces.DialogNavigationHandler.handleNavigation(DialogNavigationHandler.java:121)
>     at
>

Hmm ... the NPE here implies that the DialogContextManager managed
bean (looked for in the line right above) cannot be found.  One way
this could happen is if you didn't include the actual dialog manager
implementation JAR (shale-dialog-basic-1.0.4.jar in this case) in
addition to the API jar (shale-dialog-1.0.4.jar) in your webapp.

Could you check that please?

Craig



org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:84)
>     at
> org.apache.shale.view.faces.ViewActionListener.processAction(ViewActionListener.java:74)
>     at javax.faces.component.UICommand.broadcast(UICommand.java:106)
>     at
> javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
>     at
> javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
>     at
> org.apache.shale.view.faces.ShaleViewRoot.processApplication(ShaleViewRoot.java:40)
>     at
> org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:316)
>     at
> org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
>     at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
>     at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
>     at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
>     at
> org.apache.shale.application.faces.ShaleApplicationFilter.doFilter(ShaleApplicationFilter.java:267)
>     at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
>     at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
>     at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
>     at
> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
>     at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>     at
> org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
>     at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
>     at
> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
>     at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>     at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
>     at
> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
>     at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
>     at
> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
>     at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>     at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>     at
> org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
>     at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
>     at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
>     at
> org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
>     at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
>     at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
>     at
> org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
>     at
> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
>     at java.lang.Thread.run(Thread.java:534)
> </exception>
>
> My dialog-config files looks like the following
>
> <dialogs>
>   <dialog name="Create New Dialog" start="Input">
>     <transition outcome="start" target="Input"/>
>      <transition outcome="exit" target="Exit"/>
>
>     <view name="Input" viewId="/input.jsf" >
>           <transition outcome="next" target="Register"/>
>    </view>
>
>     <end name="Exit" viewId="/goodBye.jsf"/>
>
>  </dialog>
> </dialogs>
>
> & th epage itself contains
>
>     <h:form id="start">
>         <h:commandButton id="startDialog" action="dialog:Create New
> Dialog" value="Create New Dialog >>" />
>     </h:form>
>
> Currently I've no idea why it's not working :-((
>
> Any help or links to examples would be much appreciated!!
>
> Thx
>
> /Colin
>
>
>