geode-wan/src/test/java/org/apache/geode/management/WANManagementDUnitTest.java
@SuppressWarnings("serial")
  protected void checkAsyncQueueMBean(final VM vm, final boolean shouldExist) {
    SerializableRunnable checkAsyncQueueMBean =
        new SerializableRunnable("Check Async Queue MBean") {
          public void run() {
            Cache cache = GemFireCacheImpl.getInstance();
            ManagementService service = ManagementService.getManagementService(cache);
            AsyncEventQueueMXBean bean = service.getLocalAsyncEventQueueMXBean("pn");
            if (shouldExist) {
              assertNotNull(bean);
            } else {
              assertNull(bean);
            }
          }
        };
    vm.invoke(checkAsyncQueueMBean);
  }
/**
   * Checks whether a Async Queue MBean is created or not
   * 
   * @param vm reference to VM
   */
Checks whether a Async Queue MBean is created or not

@param vm reference to VM
Checks whether a Async Queue MBean is created or not @param vm reference to VM
@SuppressWarnings("serial")
  protected void checkAsyncQueueMBean(final VM vm, final boolean shouldExist) {
    SerializableRunnable checkAsyncQueueMBean =
        new SerializableRunnable("Check Async Queue MBean") {
          public void run() {
            Cache cache = GemFireCacheImpl.getInstance();
            ManagementService service = ManagementService.getManagementService(cache);
            AsyncEventQueueMXBean bean = service.getLocalAsyncEventQueueMXBean("pn");
            if (shouldExist) {
              assertNotNull(bean);
            } else {
              assertNull(bean);
            }
          }
        };
    vm.invoke(checkAsyncQueueMBean);
  }
@ SuppressWarnings ( "serial" ) protected void checkAsyncQueueMBean ( final VM vm , final boolean shouldExist ) { SerializableRunnable checkAsyncQueueMBean = new SerializableRunnable ( "Check Async Queue MBean" ) { public void run ( ) { Cache cache = GemFireCacheImpl . getInstance ( ) ; ManagementService service = ManagementService . getManagementService ( cache ) ; AsyncEventQueueMXBean bean = service . getLocalAsyncEventQueueMXBean ( "pn" ) ; if ( shouldExist ) { assertNotNull ( bean ) ; } else { assertNull ( bean ) ; } } } ; vm . invoke ( checkAsyncQueueMBean ) ; }
Checks whether a Async Queue MBean is created or not
Checks whether a Async Queue MBean is created or not