DataProvider with seek pagination

I am using the Vaadin Grid to display data from my backend.
At the moment I am using setItems with a custom pagination.
This way, I can tell the Grid, which data it should display, but the drawback is, that I can’t navigate past the page using the keyboard.
Therefore, I wanted to switch to using the DataProvider but the DataProvider seems to be made for offset pagination, while I need seek pagination.
The issues I am facing are the following:

  • I don’t know the size of the dataset.
    The DataProvider needs the total size of the dataset, for a given Query but in my case, the total size is unknown.
    I tryed to work around this issue, by setting the size to pageSize + 1 to be able to navigate one item further, but the count is only queried once, so I can’t increase it’s size with each page.
    Then I tryed to set it to Integer.MAX_VALUE, but this results in a lot of empty rows at the end of the dataset.
  • I can’t use the offset.
    Since I would like to use seek paginagion, I can’t use the offset provided by the Query.
    Instead, I would like to get the currentObject, the direction and the limit.
  • The offset is wrong, when the order or filter changes.
    When the order or filter changes, I try to keep the focus on the selected item.
    Since the order and/or filter changed, the item is not at the same position in the dataset anymore.
    That means, the offset I get from the Query does not represent the objects position in the dataset anymore.

Did anyone try to use the DataProvider for seek pagination?
Are there any plans on supporting that in future?