Github user svenmeier commented on a diff in the pull request:
https://github.com/apache/wicket/pull/214#discussion_r107143773
--- Diff:
wicket-core/src/main/java/org/apache/wicket/page/PageAccessSynchronizer.java ---
@@ -93,8 +94,8 @@ public Duration getTimeout(int pageId)
*/
public void lockPage(int pageId) throws CouldNotLockPageException
{
- final Thread thread = Thread.currentThread();
- final PageLock lock = new PageLock(pageId, thread);
+ final RequestCycle cycle = RequestCycle.get();
--- End diff --
PageLock is the lock: as long as there is a PageLock instance, all access
to the corresponding page has to wait.
Currently PageLock holds a reference to the thread, but the thread isn't
used actually apart from identifying the lock. The RequestCycle can be used
equally well for that.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---