public CacheSerializableRunnable getCacheSerializableRunnableForPRCreate(
      final String regionName) {
    SerializableRunnable prIndexCreator = new CacheSerializableRunnable("PrRegionCreator") {
      @Override
      public void run2() {
        try {
          Cache cache = getCache();
          LogWriter logger = cache.getLogger();
          PartitionedRegion region = (PartitionedRegion) cache.getRegion(regionName);
          Map indexMap = region.getIndex();
          Set indexSet = indexMap.entrySet();
          for (final Object o : indexSet) {
            Map.Entry entry = (Map.Entry) o;
            Index index = (Index) entry.getValue();
            logger.info("The partitioned index created on this region " + " " + index);
            logger.info("Current number of buckets indexed : " + ""
                + ((PartitionedIndex) index).getNumberOfIndexedBuckets());
          }
        } finally {
          GemFireCacheImpl.testCacheXml = null;
        }

      }
    };
    return (CacheSerializableRunnable) prIndexCreator;
  }
Creats a partiotioned region using an xml file descriptions.
geode-core/src/distributedTest/java/org/apache/geode/cache/query/partitioned/PRQueryDUnitHelper.java