microsoftgraph / microsoftgraph/msgraph-sdk-dotnet

Add overload for CreatePageIterator with callback for "next page" (+CancellationToken)

Open
#1,919 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

P2 Request: enhancement
Dominant language
C#
Stars
789
Forks
264
Avg merge
15h 17m
Merged PRs (30d)
3

Description

With v4 of Graph, our custom paging had a callback to tell the calling code "we got a new page" - that is not possible now.

Also not possible is passing a CancellationToken for stopping iterating in IterateAsync - doing a manual check on every item's callback via the iterator is costly, per-page would be the best option (because that's where the asynchrony really is).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating CreatePageIterator and IterateAsync in the Microsoft Graph .NET SDK, then inspect how asynchronous page traversal currently exposes callbacks and cancellation. Compare existing paging tests or examples, if present, and define done as an overload that reports each new page and accepts a CancellationToken at page boundaries.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
api
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.