@Test
  public void testRegionBulkGet() throws Exception {
    Cache cache = CacheUtils.getCache();
    AttributesFactory attributesFactory = new AttributesFactory();
    RegionAttributes regionAttributes = attributesFactory.create();

    Region region = cache.createRegion("pos", regionAttributes);

    region.put("6", 6);
    region.put("10", 10);
    region.put("12", 10);

    QueryService qs = cache.getQueryService();

    Query q;
    SelectResults results;
    Object[] keys;
    Set expectedResults;

    q = qs.newQuery("SELECT e.value FROM " + SEPARATOR + "pos.entrySet e WHERE e.key IN $1");
    keys = new Object[] {"5", "6", "10", "45"};
    results = (SelectResults) q.execute(new Object[] {keys});
    expectedResults = new HashSet();
    expectedResults.add(6);
    expectedResults.add(10);
    assertThat(results.asSet()).isEqualTo(expectedResults);

    q = qs.newQuery("SELECT e.value FROM " + SEPARATOR + "pos.entrySet e WHERE e.key IN $1");
    keys = new Object[] {"42"};
    results = (SelectResults) q.execute(new Object[] {keys});
    expectedResults = new HashSet();
    assertThat(results.asSet()).isEqualTo(expectedResults);

    for (int i = 0; i < 1000; i++) {
      region.put(String.valueOf(i), i);
    }
    q = qs.newQuery("SELECT e.value FROM " + SEPARATOR + "pos.entrySet e WHERE e.key IN $1");
    keys = new Object[] {"5", "6", "10", "45"};
    results = (SelectResults) q.execute(new Object[] {keys});
    expectedResults = new HashSet();
    expectedResults.add(5);
    expectedResults.add(6);
    expectedResults.add(10);
    expectedResults.add(45);
    assertThat(results.asSet()).isEqualTo(expectedResults);

    q = qs.newQuery("SELECT e.key, e.value FROM " + SEPARATOR + "pos.entrySet e WHERE e.key IN $1");
    keys = new Object[] {"5", "6", "10", "45"};
    results = (SelectResults) q.execute(new Object[] {keys});
    assertThat(results).hasSize(4);

    region.destroyRegion();
  }
Test the decomposition of IN SET(..) that gets decomposed into ORs so an index can be used
geode-core/src/integrationTest/java/org/apache/geode/cache/query/functional/INOperatorJUnitTest.java