# # DTC configure file. v2 # props: log.level: debug listener.port.dtc: 20015 shm.mem.size: 100 #MB hash.custom: Yes hash.custom.module: ../lib/key-hash.so hash.custom.functon: "StringHash(1,128)" connector.procs: 10 data_lifecycle: single.query.count: 10 lifecycle.tablename: 'data_lifecycle_table' rule.cron: '0 */1 * * * ?' connection: &connection addr: 127.0.0.1:3307 user: username pwd: password primary: db: &db mydb table: &table name layered.rule: '(a>1 and a<3) or uid = 0' option.file.path: '../conf/my.conf' cache: field: - {name: &key uid, type: signed/unsigned/float/string/binary, size: 4} - {name: name, type: binary, size: 50, nullable: 1} - {name: city, type: string, size: 50, default: ""} - {name: sex, type: signed, size: 4, default: 0} - {name: age, type: signed, size: 4} hot: logic: {db: mydb_layer2, table: *table, connection: *connection} real: - {addr: mysql-01.local:3306, user: username, pwd: password, db: {prefix: &prefix [*db, _], start: 0, last: 10}} - {addr: mysql-02.local:3306, user: username, pwd: password, db: {prefix: *prefix, start: 11, last: 25}} - {addr: mysql-03.local:3306, user: username, pwd: password, db: {prefix: *prefix, start: 26, last: 29}} sharding: key: *key table: {prefix: [*table, _], start: 0, last: 9} full: logic: {db: mydb_layer3, table: *table, connection: *connection} real: - {addr: 127.0.0.1:3306, user: username, pwd: password, db: layer3} extension: - logic: {db: January, table: Monday, connection: *connection} real: - {addr: mysql-01.local:3306, user: username, pwd: password, db: January} - logic: {db: February, table: Tuesday, connection: *connection} real: - {addr: mysql-01.local:3306, user: username, pwd: password, db: February}