You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by ad...@apache.org on 2014/07/25 23:06:27 UTC

[2/2] git commit: WICKET-5643 WebPageRenderer should bind a Session if redirect is required and the session is temporary.

WICKET-5643 WebPageRenderer should bind a Session if redirect is
required and the session is temporary.

Added a warning log if a null session id is provided.


Project: http://git-wip-us.apache.org/repos/asf/wicket/repo
Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/6b8439f9
Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/6b8439f9
Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/6b8439f9

Branch: refs/heads/wicket-6.x
Commit: 6b8439f93e1809e5fc8b5fb283a4c0ff8c0dac47
Parents: 1064d37
Author: Andrea Del Bene <an...@gmail.com>
Authored: Tue Jul 22 18:19:31 2014 +0200
Committer: Andrea Del Bene <an...@gmail.com>
Committed: Fri Jul 25 23:01:01 2014 +0200

----------------------------------------------------------------------
 .../org/apache/wicket/protocol/http/WebApplication.java  | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/wicket/blob/6b8439f9/wicket-core/src/main/java/org/apache/wicket/protocol/http/WebApplication.java
----------------------------------------------------------------------
diff --git a/wicket-core/src/main/java/org/apache/wicket/protocol/http/WebApplication.java b/wicket-core/src/main/java/org/apache/wicket/protocol/http/WebApplication.java
index 54bb265..dff0777 100644
--- a/wicket-core/src/main/java/org/apache/wicket/protocol/http/WebApplication.java
+++ b/wicket-core/src/main/java/org/apache/wicket/protocol/http/WebApplication.java
@@ -886,14 +886,19 @@ public abstract class WebApplication extends Application
 
 	/**
 	 * Store the buffered response at application level to use it at a later time.
-	 * NOTE: the method requires a not-null session id, otherwise it just returns.
-	 * 
+	 *
 	 * @param sessionId
 	 * @param url
 	 * @param response
 	 */
 	public void storeBufferedResponse(String sessionId, Url url, BufferedWebResponse response)
-	{	
+	{
+		if (sessionId == null) 
+		{
+			log.warn("storeBufferedResponse needs a valid session id to store the response, but a null one was found. "
+					+ "Please report the problem to dev team and try to reproduce it in a quickstart project.");
+		}
+		
 		String key = sessionId + url.toString();
 		storedResponses.put(key, response);
 	}