Is synchronization within an HttpSession feasible?
问题 UPDATE: Solution right after question. Question: Usually, synchronization is serializing parallel requests within a JVM, e.g. private static final Object LOCK = new Object(); public void doSomething() { ... synchronized(LOCK) { ... } ... } When looking at web applications, some synchronization on "JVM global" scope is maybe becoming a performance bottleneck and synchronization only within the scope of the user's HttpSession would make more sense. Is the following code a possibility? I doubt