Skip to content

Commit

Permalink
Simplify README go example topology.
Browse files Browse the repository at this point in the history
  • Loading branch information
maksim.konovalov committed Jan 13, 2025
1 parent d0e58ea commit b31dfb6
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 48 deletions.
30 changes: 6 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,31 +108,13 @@ func main() {
DiscoveryTimeout: time.Minute,
DiscoveryMode: vshardrouter.DiscoveryModeOn,
TopologyProvider: static.NewProvider(map[vshardrouter.ReplicasetInfo][]vshardrouter.InstanceInfo{
vshardrouter.ReplicasetInfo{
Name: "replcaset_1",
UUID: uuid.New(),
}: {
{
Addr: "127.0.0.1:1001",
Name: "1_1",
},
{
Addr: "127.0.0.1:1002",
Name: "1_2",
},
{Name: "replcaset_1", UUID: uuid.New()}: {
{Addr: "127.0.0.1:1001", Name: "1_1"},
{Addr: "127.0.0.1:1002", Name: "1_2"},
},
vshardrouter.ReplicasetInfo{
Name: "replcaset_2",
UUID: uuid.New(),
}: {
{
Addr: "127.0.0.1:2001",
Name: "2_1",
},
{
Addr: "127.0.0.1:2002",
Name: "2_2",
},
{Name: "replcaset_2", UUID: uuid.New()}: {
{Addr: "127.0.0.1:2001", Name: "2_1"},
{Addr: "127.0.0.1:2002", Name: "2_2"},
},
}),
TotalBucketCount: 128000,
Expand Down
30 changes: 6 additions & 24 deletions README_ru.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,31 +107,13 @@ func main() {
DiscoveryTimeout: time.Minute,
DiscoveryMode: vshardrouter.DiscoveryModeOn,
TopologyProvider: static.NewProvider(map[vshardrouter.ReplicasetInfo][]vshardrouter.InstanceInfo{
vshardrouter.ReplicasetInfo{
Name: "replcaset_1",
UUID: uuid.New(),
}: {
{
Addr: "127.0.0.1:1001",
Name: "1_1",
},
{
Addr: "127.0.0.1:1002",
Name: "1_2",
},
{Name: "replcaset_1", UUID: uuid.New()}: {
{Addr: "127.0.0.1:1001", Name: "1_1"},
{Addr: "127.0.0.1:1002", Name: "1_2"},
},
vshardrouter.ReplicasetInfo{
Name: "replcaset_2",
UUID: uuid.New(),
}: {
{
Addr: "127.0.0.1:2001",
Name: "2_1",
},
{
Addr: "127.0.0.1:2002",
Name: "2_2",
},
{Name: "replcaset_2", UUID: uuid.New()}: {
{Addr: "127.0.0.1:2001", Name: "2_1"},
{Addr: "127.0.0.1:2002", Name: "2_2"},
},
}),
TotalBucketCount: 128000,
Expand Down

0 comments on commit b31dfb6

Please sign in to comment.