Commit c62d1b5452c57395b6639af9dcdd7548472927f9
Merge branch 'master' of http://gitlab.gaoxiaobang.com/zygj/huike-eaas-config
Showing
1 changed file
with
12 additions
and
2 deletions
account-service.yml
| ... | ... | @@ -75,11 +75,21 @@ sharding.jdbc: |
| 75 | 75 | username: test |
| 76 | 76 | password: ENC(8aea42e66b0928c44cd8f861a9d558e6) |
| 77 | 77 | masterSlaveRule: |
| 78 | - name: ds_ms | |
| 78 | + name: ms_ds | |
| 79 | 79 | masterDataSourceName: ds_master |
| 80 | 80 | slaveDataSourceNames: ds_slave0 |
| 81 | 81 | props: |
| 82 | - sql.show: true | |
| 82 | + sql.show: true | |
| 83 | + shardingRule: | |
| 84 | + tables: | |
| 85 | + Account: | |
| 86 | + actualDataNodes: ms_ds.Account${0..1} | |
| 87 | + tableStrategy: | |
| 88 | + inline: | |
| 89 | + shardingColumn: UUID | |
| 90 | + algorithmExpression: Account${UUID.hashCode() % 2} | |
| 91 | + | |
| 92 | + | |
| 83 | 93 | |
| 84 | 94 | #mybatis: |
| 85 | 95 | #configLocation: classpath:mybatis-config.xml | ... | ... |