instances = changeList.poll(1, TimeUnit.SECONDS);
Assert.assertNotNull(instances, "Expecting a list of live instance");
Assert.assertEquals(instances.get(0).getRecord().getMapField("test"),
map,
"Wrong map data.");
manager.disconnect();
Thread.sleep(1000); // wait for callback finish
instances = changeList.poll(1, TimeUnit.SECONDS);
Assert.assertNotNull(instances, "Expecting a list of live instance");
Assert.assertTrue(instances.isEmpty(), "Expecting an empty list of live instance");