You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Felix Meschberger (Resolved) (JIRA)" <ji...@apache.org> on 2012/01/16 19:57:39 UTC
[jira] [Resolved] (SLING-2370) Ensure request counter is atomically
incremented
[ https://issues.apache.org/jira/browse/SLING-2370?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Felix Meschberger resolved SLING-2370.
--------------------------------------
Resolution: Fixed
Fixed as described in Rev. 1232111
> Ensure request counter is atomically incremented
> ------------------------------------------------
>
> Key: SLING-2370
> URL: https://issues.apache.org/jira/browse/SLING-2370
> Project: Sling
> Issue Type: Improvement
> Components: Engine
> Affects Versions: Engine 2.2.4
> Reporter: Felix Meschberger
> Assignee: Felix Meschberger
> Fix For: Engine 2.2.6
>
>
> The SlingHttpServletResponseImpl contains the request counter, which is a static value incremented on each request. In case of heave concurrency, this counter may yield the same value for two different requests.
> Using an AtomicLong (instead of int) we can ensure atomicity of update and retrieval and at the same time increase the number of unique request ids (int was probably wrong anyway in this respect and it should have been long from the start).
--
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