You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "John Ray (JIRA)" <ji...@apache.org> on 2007/09/08 23:15:29 UTC
[jira] Created: (WICKET-946) WebRequestCodingStrategy is not
synchronized
WebRequestCodingStrategy is not synchronized
--------------------------------------------
Key: WICKET-946
URL: https://issues.apache.org/jira/browse/WICKET-946
Project: Wicket
Issue Type: Bug
Components: wicket
Affects Versions: 1.3.0-beta3
Reporter: John Ray
The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
I'll include a patch to fix this as well as a new version of the java file that you can use if you want
Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WICKET-946) WebRequestCodingStrategy is not
synchronized
Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-946?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12526827 ]
Igor Vaynberg commented on WICKET-946:
--------------------------------------
such a usecase is commonly handled by mounting a "dispatch" page.
so you would mount a dispatch page to lets say /page mount with indexed url coding strat, and then pass in the name of the page as a param
so if you want to display page foo the url would be /page/foo instead of just /foo
if foo is representated by an actual wicket page then the dispatch page can throw a restartresponseexception and hard-redirect to page foo.
makes sense?
> WebRequestCodingStrategy is not synchronized
> --------------------------------------------
>
> Key: WICKET-946
> URL: https://issues.apache.org/jira/browse/WICKET-946
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.0-beta3
> Reporter: John Ray
> Assignee: Igor Vaynberg
> Attachments: WebRequestCodingStrategy-patch, WebRequestCodingStrategy.java
>
>
> The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
> I'll include a patch to fix this as well as a new version of the java file that you can use if you want
> Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WICKET-946) WebRequestCodingStrategy is not
synchronized
Posted by "John Ray (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-946?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12526842 ]
John Ray commented on WICKET-946:
---------------------------------
The way my application is currently written it has a number of pages created the standard wicket way. However the user can add a page dynamically anyplace they want. The issues with having a dispatch page is that it restricts the possible URLs of any of the dynamic pages. For instance if I have the following top level pages
/index
/page1
/page2
If the user then wants to add a couple pages to the top level you end up with the following
/index
/page1
/page2
/page/foo1
/page/foo2
I would also need to create a dispatch page in each of my applications directories when the application is first started just in case the user wants to add a page there. I do see where your coming from though and perhaps I should be looking at patching into wicket farther up chain. When I saw the unmount method I assumed this was the best place and just thought the synchronization was an oversight.
> WebRequestCodingStrategy is not synchronized
> --------------------------------------------
>
> Key: WICKET-946
> URL: https://issues.apache.org/jira/browse/WICKET-946
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.0-beta3
> Reporter: John Ray
> Assignee: Igor Vaynberg
> Attachments: WebRequestCodingStrategy-patch, WebRequestCodingStrategy.java
>
>
> The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
> I'll include a patch to fix this as well as a new version of the java file that you can use if you want
> Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (WICKET-946) WebRequestCodingStrategy is not
synchronized
Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-946?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Igor Vaynberg reassigned WICKET-946:
------------------------------------
Assignee: Igor Vaynberg
> WebRequestCodingStrategy is not synchronized
> --------------------------------------------
>
> Key: WICKET-946
> URL: https://issues.apache.org/jira/browse/WICKET-946
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.0-beta3
> Reporter: John Ray
> Assignee: Igor Vaynberg
> Attachments: WebRequestCodingStrategy-patch, WebRequestCodingStrategy.java
>
>
> The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
> I'll include a patch to fix this as well as a new version of the java file that you can use if you want
> Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (WICKET-946) WebRequestCodingStrategy is not
synchronized
Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-946?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Igor Vaynberg resolved WICKET-946.
----------------------------------
Resolution: Fixed
applied patch
> WebRequestCodingStrategy is not synchronized
> --------------------------------------------
>
> Key: WICKET-946
> URL: https://issues.apache.org/jira/browse/WICKET-946
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.0-beta3
> Reporter: John Ray
> Assignee: Igor Vaynberg
> Attachments: mylyn-context.zip, WebRequestCodingStrategy-patch, WebRequestCodingStrategy.java
>
>
> The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
> I'll include a patch to fix this as well as a new version of the java file that you can use if you want
> Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WICKET-946) WebRequestCodingStrategy is not
synchronized
Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-946?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Igor Vaynberg updated WICKET-946:
---------------------------------
Attachment: mylyn-context.zip
> WebRequestCodingStrategy is not synchronized
> --------------------------------------------
>
> Key: WICKET-946
> URL: https://issues.apache.org/jira/browse/WICKET-946
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.0-beta3
> Reporter: John Ray
> Assignee: Igor Vaynberg
> Attachments: mylyn-context.zip, WebRequestCodingStrategy-patch, WebRequestCodingStrategy.java
>
>
> The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
> I'll include a patch to fix this as well as a new version of the java file that you can use if you want
> Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WICKET-946) WebRequestCodingStrategy is not
synchronized
Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-946?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12526671 ]
Igor Vaynberg commented on WICKET-946:
--------------------------------------
what exactly is the usecase for this? you are only meant to mount/unmount pages in your application.init() method
> WebRequestCodingStrategy is not synchronized
> --------------------------------------------
>
> Key: WICKET-946
> URL: https://issues.apache.org/jira/browse/WICKET-946
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.0-beta3
> Reporter: John Ray
> Assignee: Igor Vaynberg
> Attachments: WebRequestCodingStrategy-patch, WebRequestCodingStrategy.java
>
>
> The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
> I'll include a patch to fix this as well as a new version of the java file that you can use if you want
> Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WICKET-946) WebRequestCodingStrategy is not
synchronized
Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-946?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Igor Vaynberg updated WICKET-946:
---------------------------------
Fix Version/s: 1.3.0-beta4
> WebRequestCodingStrategy is not synchronized
> --------------------------------------------
>
> Key: WICKET-946
> URL: https://issues.apache.org/jira/browse/WICKET-946
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.0-beta3
> Reporter: John Ray
> Assignee: Igor Vaynberg
> Fix For: 1.3.0-beta4
>
> Attachments: mylyn-context.zip, WebRequestCodingStrategy-patch, WebRequestCodingStrategy.java
>
>
> The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
> I'll include a patch to fix this as well as a new version of the java file that you can use if you want
> Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WICKET-946) WebRequestCodingStrategy is not
synchronized
Posted by "John Ray (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-946?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
John Ray updated WICKET-946:
----------------------------
Attachment: WebRequestCodingStrategy.java
> WebRequestCodingStrategy is not synchronized
> --------------------------------------------
>
> Key: WICKET-946
> URL: https://issues.apache.org/jira/browse/WICKET-946
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.0-beta3
> Reporter: John Ray
> Attachments: WebRequestCodingStrategy-patch, WebRequestCodingStrategy.java
>
>
> The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
> I'll include a patch to fix this as well as a new version of the java file that you can use if you want
> Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WICKET-946) WebRequestCodingStrategy is not
synchronized
Posted by "John Ray (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-946?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
John Ray updated WICKET-946:
----------------------------
Attachment: WebRequestCodingStrategy-patch
> WebRequestCodingStrategy is not synchronized
> --------------------------------------------
>
> Key: WICKET-946
> URL: https://issues.apache.org/jira/browse/WICKET-946
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.0-beta3
> Reporter: John Ray
> Attachments: WebRequestCodingStrategy-patch, WebRequestCodingStrategy.java
>
>
> The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
> I'll include a patch to fix this as well as a new version of the java file that you can use if you want
> Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (WICKET-946) WebRequestCodingStrategy is not
synchronized
Posted by "John Ray (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-946?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12526815 ]
John Ray commented on WICKET-946:
---------------------------------
The usecase is to create a kind of content management system or WIKI. I basically want user's to be able to add/remove pages while the application is running.
> WebRequestCodingStrategy is not synchronized
> --------------------------------------------
>
> Key: WICKET-946
> URL: https://issues.apache.org/jira/browse/WICKET-946
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.0-beta3
> Reporter: John Ray
> Assignee: Igor Vaynberg
> Attachments: WebRequestCodingStrategy-patch, WebRequestCodingStrategy.java
>
>
> The WebRequestCodingStrategy class uses a TreeMap to store mounted pages however there is no synchronization done. This will cause problems if pages are being mounted/unmounted by one thread while web requests are being served from a different one. It could also cause problems if two threads try to mount/unmount pages at the same time.
> I'll include a patch to fix this as well as a new version of the java file that you can use if you want
> Keep up the good work
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.