Use modernized java.util.concurrent APIs

MSAL

The Java concurrent APIs were updated in Java 9 and those changes resulted in certain APIs being deprecated. This recipe updates an application to replace the deprecated APIs with their modern alternatives.

org.openrewrite.java.migrate.concurrent.JavaConcurrentAPIs
mod run . --recipe=org.openrewrite.java.migrate.concurrent.JavaConcurrentAPIs

Install it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.

Recipe list

It runs these recipes, in this order.

  1. Use AtomicBoolean#weakCompareAndSetPlain(boolean, boolean)
  2. Use AtomicInteger#weakCompareAndSetPlain(int, int)
  3. Use AtomicIntegerArray#weakCompareAndSetPlain(int, int, int)
  4. Use AtomicLong#weakCompareAndSetPlain(long, long)
  5. Use AtomicLongArray#weakCompareAndSetPlain(int, long, long)
  6. Use AtomicReference#weakCompareAndSetPlain(T, T)
  7. Use AtomicReferenceArray#weakCompareAndSetPlain(int, T, T)