Skip to content

Commit

Permalink
Revert #1266: change default pool back to ThreadLocal-based pool (unt…
Browse files Browse the repository at this point in the history
…il 3.0) (#1294)
  • Loading branch information
cowtowncoder authored Jun 4, 2024
1 parent 47da668 commit 8bda625
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
1 change: 0 additions & 1 deletion release-notes/VERSION-2.x
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ a pure JSON library.
#1264: Rename shaded `ch.randelshofer:fastdoubleparser` classes
to prevent use by downstream consumers
(requested by @seadbrane)
#1266: Change default recycler pool to `newConcurrentDequePool()` in 2.18
#1271: Deprecate `LockFreePool` implementation in 2.18 (remove from 3.0)
#1277: Add back Java 22 optimisation in FastDoubleParser

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@ public final class JsonRecyclerPools
{
/**
* Method to call to get the default recycler pool instance:
* as of Jackson 2.18.x and later (except for 2.17.0) this is same as calling
* {@link #newConcurrentDequePool()}: before this it was calling
* {@link #threadLocalPool()} (except for 2.17.1 that temporarily
* called {@link #newLockFreePool()}, changed back due to reported issues).
* as of Jackson 2.18 this is same as calling
* {@link #threadLocalPool()}: Jackson 2.17.0 instead had this call
* {@link #newLockFreePool()} but this was reverted due to problems reported.
*<p>
* Default pool will likely be changed in Jackson 3.0 to something else.
*
* @return the default {@link RecyclerPool} implementation to use
* if no specific implementation desired.
*/
public static RecyclerPool<BufferRecycler> defaultPool() {
// since 2.18.0:
return newConcurrentDequePool();
return threadLocalPool();
}

/**
Expand Down

0 comments on commit 8bda625

Please sign in to comment.