Skip to content

Phase 7c: pagination #81

Closed
Closed

Description

@Wahbeh-Mohammad

Summary

Implement phase 7c, pagination, per the design docs/work/mvp/phase7/phase7c/2026-10-09-phase7c-pagination-design.md and the plan docs/work/mvp/phase7/phase7c/2026-10-09-phase7c-pagination.md.

Scope (36 rows)

PAGE-1–PAGE-36 (33 built, 3 N/A). One feat! PR, grouped as:

  1. Internal: QuerySplice (case-sensitive, with property tests), LinkHeaderParser with its vector, LinkTarget.TryResolve.
  2. IPageStrategy<TPage,T>, Page<T>.Request, the built-in strategies and PaginationStrategies factories, single-use enumerables, the one fetch-and-parse step, the async cutover (AsyncPageable<T>, Pageable.Create), the blocking Pageable<T> / CreateBlocking, the lifecycle suite, architecture tests and the Link-origin Security class.
  3. FetchedPage<T>, PagingOptions, Pageable.FromFetchers (PAGE-34, PAGE-35); loopback wire tests; AOT smoke (paged round trip); docs/sdk-documentation/pagination.md; checklist, CHANGELOG, corrections, roadmap status note.

Breaking changes

  1. Pageable.Create takes IAsyncHttpClient, an IPageStrategy<TPage,T> and RequestOptions?.
  2. PaginationStrategies.* gain the item selector and a second type parameter; Cursor defaults to "cursor"; PageNumber loses hasMore and gains startPage; LinkHeader loses rel and gains headerName and allowCrossOrigin.
  3. PageNumber ends on an empty page (PAGE-17).
  4. LinkHeader ends on a cross-origin or invalid target, strips userinfo, reads every Link instance, resolves against the response URL.
  5. The splice matches names case-sensitively and drops duplicates.
  6. AsPages() loses pageSizeHint, becomes non-virtual and single-use per view; subclasses override WalkPagesAsync.
  7. Page<T>'s constructor requires the Request.
  8. maxPages <= 0 and a non-replayable template body throw at construction.
  9. A null envelope throws DeserializationException.

Open for the lead

  • P7c-3: pageSizeHint removed from AsPages().
  • P7c-6: per-call overrides are RequestOptions (removes a parameter type).
  • P7c-12: cross-origin Link targets end the stream unless allowCrossOrigin: true.
  • P7c-16: PagingOptions is a mutable class.

Done when

  • Every plan task is done, the checklist has one row per requirement ID, and build, format, tests, coverage, AOT smoke, dependency audit and the housekeeping probe all pass.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:coreCore HTTP, IO, body, context, encoding: HTTP-* IO-* BODY-* CTX-* UTF-*breaking-changeRequires a major versiontype:featureNew capability or enhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions