03-sharded-read-write

command
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 20, 2026 License: MIT Imports: 8 Imported by: 0

README

Sharding with read/write splitting

This example maps 128 virtual shards over two physical replica sets. Generated routed methods derive the shard key through tenantResolver; reads use replicas by default and writes always use the selected primary.

Required variables are SHARD0_PRIMARY_DSN, SHARD0_REPLICA_DSN, SHARD1_PRIMARY_DSN, and SHARD1_REPLICA_DSN.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL