Skip to content

Implement Continuation Token Pagination#11

Merged
fredvisser merged 4 commits intomainfrom
users/fvisser/fix-pagination-bahavior
Jul 30, 2025
Merged

Implement Continuation Token Pagination#11
fredvisser merged 4 commits intomainfrom
users/fvisser/fix-pagination-bahavior

Conversation

@fredvisser
Copy link
Collaborator

Fixes DFF config list pagination behavior and implements continuation tokens across all SystemLink CLI services

Key Changes:

  • DFF Service: Added _query_all_configurations(), _query_all_groups(), _query_all_fields() with continuation token pagination, replacing hardcoded Take=1000
  • Templates/Workflows: Added _query_all_templates() and _query_all_workflows() with continuation token support
  • Notebook Service: Enhanced _query_notebooks_http() with proper continuation token pagination
  • Workspace Utils: Updated helper functions to use continuation tokens for workspace filtering
  • User Service: Improved existing continuation token implementation

Benefits:

  • Better memory efficiency with smaller page sizes (100-500 vs 1000)
  • Improved scalability for workspaces with thousands of items
  • Consistent pagination patterns across all services
  • Maintains backward compatibility

Services Updated:

✅ Dynamic Form Fields, Templates, Workflows, Notebooks, User management, Workspace utilities
❌ Auth-mapping APIs (only support skip/take pagination)

@fredvisser fredvisser requested a review from Copilot July 30, 2025 15:48

This comment was marked as outdated.

@fredvisser fredvisser requested a review from Copilot July 30, 2025 16:13

This comment was marked as outdated.

@fredvisser fredvisser requested a review from Copilot July 30, 2025 17:11
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR implements continuation token pagination across SystemLink CLI services to replace hardcoded Take=1000 parameters with proper pagination. The change improves memory efficiency and scalability for workspaces with thousands of items while maintaining backward compatibility.

  • Replaces hardcoded large take values (1000) with continuation token pagination using smaller page sizes (100-500)
  • Adds new helper functions _query_all_* for each service to handle continuation token logic
  • Updates workspace utilities and test mocks to support filtered responses with the new pagination approach

Reviewed Changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
slcli/dff_click.py Added continuation token pagination for DFF configurations, groups, and fields with _query_all_* functions
slcli/templates_click.py Implemented _query_all_templates() with continuation token support and updated list command
slcli/workflows_click.py Added _query_all_workflows() function with continuation token pagination
slcli/notebook_click.py Enhanced _query_notebooks_http() to use continuation token pagination instead of single large request
slcli/user_click.py Improved existing continuation token implementation with proper filtering and pagination logic
slcli/workspace_click.py Updated workspace template/workflow queries to use continuation token pagination
slcli/universal_handlers.py Added FilteredResponse class to support mock responses with pagination results
tests/unit/test_templates_click.py Updated test mock to handle workspace filtering in paginated responses
.github/copilot-instructions.md Added HTTP API documentation guidelines and OpenAPI specification references

@fredvisser fredvisser merged commit 59fd00e into main Jul 30, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants