I'm trying to figure out how to exercise the CreateRegion and
DestoryRegion classes from a client in order to test authorization.  I
can't figure out what the API would be for a client to trigger the
cmdExecute() call on the server.

For example, I was able to hit it in ClearRegion by having the client
execute the Region.clear() method.  Here's a snippet from the unit
test:

SerializableRunnable clearAuthorized = new SerializableRunnable() {
  @Override
  public void run() {
    Cache cache =
SecurityTestUtils.createCacheClient("authRegionUser", "1234567",
serverPort, SecurityTestUtils.NO_EXCEPTION);
    final Region region = cache.getRegion(SecurityTestUtils.REGION_NAME);
    region.clear();
    cache.close();
  }
};
client2.invoke(clearAuthorized);

Reply via email to