RestUtils.refresh("cascading-local");
}
@Test
public void testReadFromES() throws Exception {
Tap in = new EsTap("cascading-local/artists", query);
Pipe pipe = new Pipe("copy");
pipe = new Each(pipe, new FilterNotNull());
pipe = new Each(pipe, AssertionLevel.STRICT, new AssertSizeLessThan(5));
// can't select when using unknown
//pipe = new Each(pipe, new Fields("name"), AssertionLevel.STRICT, new AssertNotNull());
pipe = new GroupBy(pipe);
pipe = new Every(pipe, new Count());
// print out
Tap out = new OutputStreamTap(new TextLine(), OUT);
build(cfg(), in, out, pipe);
}