Closed matt-tyler-qoria closed 1 week ago
Hi @matt-tyler-qoria , Thanks for trying out the GO SDK. This looks like a service layer issue and not an SDK issue, the SDK uses an endpoint returned by the service, as seen here, to iterate over the pages.
For now, I'd suggests fetching the collection locally and sorting them after fetching them, also could you kindly report this bug here on Microsoft QnA so the relevant team can address is
This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment.
Describe the bug
I attempted to paginate over a very large number of groups using an iterator.
e.g.
However, I've noticed its not functioning correctly when ordering by display name. It skips over entire ranges and as such there are groups missing from the complete collection - as if its using the last ID to fetch a page, as opposed to the displayName.
If I do not specify the Orderby parameter, everything works correctly.
The entire collection consists of approximately 260,000 groups. When using Orderby, there were roughly 30,000 groups missing.
I'm unsure as to whether this is an issue with the SDK, or with the graph service itself.
I could this being perfectly reasonably behaviour but I was unable to find it documented anywhere.
Expected behavior
All groups are returned via pagination, regardless of the orderby clause
OR
there is some warning somewhere that pagination does not function correctly when specifying an orderby clause.
How to reproduce
Paginate over a group set as above.
I'm unsure as to level of the data that would be required for this to be noticeable.
SDK Version
v1.43.0
Latest version known to work for scenario above?
No response
Known Workarounds
Do not specify an orderby clause when attempting to paginate through a full set of groups.
Debug output
NA
Configuration
Mac OS / ARM 64 Debian x64
Other information
No response