Repository navigation
examples: Concurrent Ideas Board demo (6 features) - #5
Merged
Merged
Conversation
Mirror the Java demo's metrics, follower-read, CDC, multi-region, and semantic-search features in Python idiom against this library's real API: - metrics: RetryEngine + InMemoryMetricsCollector count transactions/retries - follower-read: @follower_read + build_staleness, cooperative AS OF SYSTEM TIME - cdc: @changefeed_handler + ChangefeedHandlerRegistry webhook dispatch - multi-region: @regional_by_row + RegionContext, explicit crdb_region write - semantic-search: CockroachDBVectorStore + deterministic embedding provider Each feature ships a runnable unit test plus a Testcontainers integration test; multi-region and semantic ITs are gated (multi-region cluster / vector image). Tagged regions added for tutorial include.
The example/ideas-board tree never ran through CI before (first push of the branch), so ruff format --check and ruff check . flagged it. Apply ruff format to the example, auto-fix import sorting and stray noqa, and extend the examples per-file-ignores (TC, SIM105, N818) so demo code keeps a runtime pytest import and readable try/except without weakening library linting. No logic changes; unit tests still 15 passed / 5 skipped (ITs skip without Docker).
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.
Adds the Concurrent Ideas Board example (
examples/ideas-board/) for the Python library.Hero:
@crdb_retryon SQLSTATE 40001 under SERIALIZABLE. Includes metrics, follower reads, CDC, multi-region, and vector/semantic search. On the psycopg path the follower-read/regional decorators are declarative — the demo applies staleness / writescrdb_regionexplicitly, with the SQLAlchemy layer providing auto-injection. Unit tests pass; Testcontainers ITs skip without Docker; multi-region/vector ITs gated on cluster/image.