Add throughput bucket samples for Cosmos Spark connector#48733
Closed
xinlian12 wants to merge 44 commits into
Closed
Add throughput bucket samples for Cosmos Spark connector#48733xinlian12 wants to merge 44 commits into
xinlian12 wants to merge 44 commits into
Conversation
Imports the shared review pipeline from xinlian12/sdk-auto-pr-review. Triggers on PR open/push/ready_for_review. Posts inline review comments with severity tags and AI disclaimer. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add sdkReviewAgent agentic workflow for automated PR review
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Recompile workflow with GH_TOKEN fix for mcp-scripts
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Feature/sdk review agent
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Feature/sdk review agent
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Feature/sdk review agent
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Imports the shared review pipeline from xinlian12/sdk-auto-pr-review. Triggers on PR open/push/ready_for_review. Posts inline review comments with severity tags and AI disclaimer. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add Python (.ipynb) and Scala sample notebooks demonstrating server-side throughput bucket configuration as an alternative to SDK-based global throughput control. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The throughput bucket number (1-5) does not indicate priority level. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add Python and Scala sample notebooks demonstrating server-side throughput bucket configuration for the Cosmos Spark connector (
azure-cosmos-spark_3).Changes
Samples/Python/NYC-Taxi-Data/04_ThroughputBucket.ipynb— PySpark notebookSamples/Scala/NYC-Taxi-Data/04_ThroughputBucket.scala— Scala Databricks notebookBoth samples are modeled after the existing
01_Batchsamples but replace the SDK-side global throughput control with the simpler server-sidethroughputBucketconfiguration:spark.cosmos.throughputControl.enabled"true"spark.cosmos.throughputControl.namespark.cosmos.throughputControl.throughputBucket1and5Key differences from
01_BatchThroughputControlmetadata container creation (not needed for server-side buckets)targetThroughputThreshold,globalControl.database,globalControl.containerwiththroughputBucket5; delete uses bucket1to demonstrate different priority levelsVerification
These are Databricks notebook samples and do not have associated unit tests. The structure and configuration keys were verified against the Spark connector source code (
CosmosConfig.scala,ThroughputControlHelper.scala).