Collections.sort(out);
Assert.assertEquals(in, out);
}
@Test
public void testRollbackWithSink() throws Exception {
final NullSink nullSink = new NullSink();
Context ctx = new Context();
ctx.put("batchSize", "1");
nullSink.configure(ctx);
nullSink.setChannel(channel);
final int numItems = 99;
Thread t = new Thread() {
@Override
public void run() {
int count = 0;
while(count++ < numItems) {
try {
nullSink.process();
Thread.sleep(1);
} catch(EventDeliveryException e) {
break;
} catch (Exception e) {
Throwables.propagate(e);