Skip to content

Commit 0f7024e

Browse files
committed
add comment wrt unnecessary (at this point) fix for #738
1 parent 09e5ba1 commit 0f7024e

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

src/main/java/com/fasterxml/jackson/databind/SerializerProvider.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1380,6 +1380,10 @@ protected JsonSerializer<Object> _createUntypedSerializer(JavaType type)
13801380
* since there's one instance per serialization).
13811381
* Perhaps not-yet-resolved instance might be exposed too early to callers.
13821382
*/
1383+
// 13-Apr-2018, tatu: Problem does NOT occur any more with late 2.8.x and 2.9.x
1384+
// versions, likely due to concurrency fixes for `AnnotatedClass` introspection.
1385+
// This sync block could probably be removed; but to minimize any risk of
1386+
// regression sync block will only be removed from 3.0.
13831387
synchronized (_serializerCache) {
13841388
// 17-Feb-2013, tatu: Used to call deprecated method (that passed property)
13851389
return (JsonSerializer<Object>)_serializerFactory.createSerializer(this, type);

src/test/java/com/fasterxml/jackson/databind/misc/RaceCondition738Test.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public HasSubTypes getHasSubTypes() {
5656
*/
5757

5858
public void testRepeatedly() throws Exception {
59-
final int COUNT = 2000;
59+
final int COUNT = 3000;
6060
for (int i = 0; i < COUNT; i++) {
6161
runOnce(i, COUNT);
6262
}

0 commit comments

Comments
 (0)