FZambia / rotor

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Start developer backend

tarantoolctl rocks install cartridge 2.5.0
tarantoolctl rocks install https://raw.githubusercontent.com/moonlibs/indexpiration/master/rockspecs/indexpiration-scm-1.rockspec

Pure Tarantool

Single node

tarantool init.lua 1

Sentinel

  • First replica
tarantool init.lua 1
  • Second replica
tarantool init.lua 2
  • Warning without replication now!!!

Sharded

  • First shard
tarantool init.lua 1
  • Second shard
tarantool init.lua 2

Cartridge

Single node ready to work on 127.0.0.1

tarantool init_cartridge.lua --bootstrap true

Multinode

tarantool init_cartridge.lua --advertise-uri 127.0.0.1:3301 --workdir one
tarantool init_cartridge.lua --advertise-uri 127.0.0.1:3302 --http-enabled false --workdir two

Sentinel

  • Configure topology on web ui http://127.0.0.1:8081
    • Configure on first node
      • Enable centrifuge
      • Create replicaset
    • Configure on second node
      • Join replicaset
    • Enable failover (eventual or stateful)

Sharded

  • Configure topology on web ui http://127.0.0.1:8081
    • Configure on first node
      • Enable centrifuge
      • Create replicaset
    • Configure on second node
      • Enable centrifuge
      • Create replicaset

Combined

  • Sharded + Sentinel

Start centrifuge

git clone  https://github.com/centrifugal/centrifuge.git
cd centrifuge/_examples/custom_engine_tarantool

Pure Tarantool

Single node

go run main.go

Multinode

Sentinel

go run main.go -ha

Sharded

go run main.go -sharded

Cartridge

Single

go run main.go -user admin -password secret-cluster-cookie

Multinode

Sentinel

go run main.go -ha -user admin -password secret-cluster-cookie

Sharded

go run main.go -sharded -user admin -password secret-cluster-cookie

Tests

tarantoolctl rocks install luatest
  • Run
.rocks/bin/luatest

About


Languages

Language:Lua 100.0%