Uploaded image for project: 'Spring Data Neo4j'
  1. Spring Data Neo4j
  2. DATAGRAPH-1075

Page Totals Are Incorrect When Changing Page Size

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Complete
    • Affects Version/s: 5.1 RC1 (Lovelace), 5.0.9 (Kay SR9)
    • Fix Version/s: 5.1 RC2 (Lovelace)
    • Component/s: None
    • Labels:
      None

      Description

      When I request the exact same query, but with different page sizes, the results are often incorrect. For example, a query that matches 4 books will return the wrong number of elements and pages with this URL: /books?size=3

      This is what I expect when requesting the first page for various page sizes (the query matches 4 items):

      Size totalElements totalPages
      20 4 1
      1 4 4
      2 4 2
      3 4 2

      Note that the total elements should always be 4. However, what I receive back is the following:

      Size totalElements totalPages
      20 4 1
      1 2 2
      2 4 2
      3 6 2

      Note that requesting a size of 1 or 3 (and various other sizes) yields an incorrect number of elements and pages in the page response. A size of 3 yields 6 elements even though there are only 4 available to query.

      To be clear, the content of the page is always correct. The page metadata is what is incorrect.

        Attachments

          Activity

            People

            Assignee:
            gerrit.meier Gerrit Meier
            Reporter:
            singleshot Mike Whittemore
            Last updater:
            Mike Whittemore
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: