implement lazy loading with Grid

Hi,
I am trying to implement lazy loading with Grid in Vaadin 8. But it only shows an empty table. What do I do wrong? Also, how do I set the number of items to load (limit) to for example 20 items?

private Grid makeLazyTable()
{
Grid grid = new Grid();
DataProvider<Image, Void> dataProvider = DataProvider.fromCallbacks(
query → {
int offset = query.getOffset();
int limit = query.getLimit();
OffsetRequest request = new OffsetRequest();
request.setLimit(limit);
request.setOffset(offset);
List sort = query.getSortOrders();
return ImagesRepository.findAll(request, sort);
},
query → ImagesRepository.getImageCount()
);
grid.setDataProvider(dataProvider);
return grid;
}

I found the answer myself.
I did not add any columns. This can be done for example with:

Grid grid = new Grid(Image.class);

This adds all columns.