You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Martin Grigorov (Resolved) (JIRA)" <ji...@apache.org> on 2011/10/09 12:48:29 UTC

[jira] [Resolved] (WICKET-4116) Ajax link reports wield error when session is expired

     [ https://issues.apache.org/jira/browse/WICKET-4116?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Martin Grigorov resolved WICKET-4116.
-------------------------------------

       Resolution: Fixed
    Fix Version/s: 1.5.2

With r1180580 if a request to listener interface is executed on expired page then a re-paint of the whole (and new) page is scheduled.
Additionally a debug message is logged.
                
> Ajax link reports wield error when session is expired
> -----------------------------------------------------
>
>                 Key: WICKET-4116
>                 URL: https://issues.apache.org/jira/browse/WICKET-4116
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 1.5.1
>            Reporter: Robin Shine
>            Assignee: Martin Grigorov
>             Fix For: 1.5.2
>
>
> Reproducing steps:
> 1. Put below simple page into a Wicket application and get it mounted:
> TestPage.java:
> import org.apache.wicket.ajax.AjaxRequestTarget;
> import org.apache.wicket.ajax.markup.html.AjaxLink;
> import org.apache.wicket.markup.html.WebPage;
> @SuppressWarnings("serial")
> public class TestPage extends WebPage {
> 	
> 	public TestPage() {
> 		
> 		add(new AjaxLink<Void>("test") {
> 			@Override
> 			public void onClick(AjaxRequestTarget target) {
> 			}
> 			
> 		});
> 		
> 	}
> 	
> }
> TestPage.html:
> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
> <?xml version="1.0" encoding="UTF-8"?>
> <html xmlns="http://www.w3.org/1999/xhtml">
> 	<head>
> 		<title>Test Page</title>
> 	</head>
> 	<body>
> 		<a wicket:id="test">test</a>
> 	</body>
> </html>
> 2. Access the page in browser via mounted url, the page will display a link. 
> 3. Wait until current session is expired (do not refresh the page or click the link while waiting). 
> 4. Hit the link and below exception will be thrown:
> Message: Cannot find behavior with id: 0 on component: [ [Component id = test]]. Perhaps the behavior did not properly implement getStatelessHint() and returned 'true' to indicate that it is stateless instead of returning 'false' to indicate that it is stateful.
> 5. In wicket 1.5.0, this results in a PageExpiredException which is more comprehensive. 

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira