Class CheckCallerRunsPolicy

java.lang.Object
org.jgroups.stack.CheckCallerRunsPolicy
All Implemented Interfaces:
Policy

public class CheckCallerRunsPolicy extends Object implements Policy
If either UNICAST3 or NAKACK2 are missing, then this policy checks that the thread pool has a rejection policy of ThreadPoolExecutor.CallerRunsPolicy.

Issues a warning and changes the rejection policy to ThreadPoolExecutor.CallerRunsPolicy if not.

Since:
5.2.14
  • Field Details

    • UNICAST3

      protected static final Class<? extends Protocol> UNICAST3
    • NAKACK2

      protected static final Class<? extends Protocol> NAKACK2
  • Constructor Details

    • CheckCallerRunsPolicy

      public CheckCallerRunsPolicy()
  • Method Details

    • check

      public void check(Protocol prot) throws Exception
      Description copied from interface: Policy
      Checks that a condition is met in a given protocol
      Specified by:
      check in interface Policy
      Parameters:
      prot - The protocol in which the policy is run
      Throws:
      Exception - Thrown if the condition is not met
    • isCallerRunsHandler

      protected static boolean isCallerRunsHandler(RejectedExecutionHandler h)