Comments (7)
您好,这两天研究了一下postgresql的支持,结论是要想做到同时支持mysql和postgresql,那么就得把所有的sql,用多数据库支持的orm,这回导致dtm的客户端很重,预计不会那么快去做这方面的工作。
dtm的服务端使用了gorm,支持postgres,目前我在dtm加了postgres分支,这个分支下,能够跑通saga的例子。
from dtm.
这个在计划中,目前dtm仅仅依赖了gorm,不依赖底层具体是什么数据库。
后续会在postgresql上面做测试,给出示例
from dtm.
您好,这两天研究了一下postgresql的支持,结论是要想做到同时支持mysql和postgresql,那么就得把所有的sql,用多数据库支持的orm,这回导致dtm的客户端很重,预计不会那么快去做这方面的工作。
dtm的服务端使用了gorm,支持postgres,目前我在dtm加了postgres分支,这个分支下,能够跑通saga的例子。
是否可以考虑使用github.com/doug-martin/goqu 这样更轻量级的包而不是厚重的orm?
from dtm.
@XIELongDragon 对于dtm服务器来说,用gorm的代价还好,反正一个服务,最后生成的文件不大。dtmcli是单独拆出来的包,不依赖gorm的,对使用dtm的程序来说,不会因为dtm,引入gorm
看了你推荐的库,貌似没有对高级功能例如insert ignore的支持,而dtm用到了
from dtm.
insert ignore你是指记录如果存在就skip吗?有呀
tx.
Insert(yourTable).
Rows(yourData).
OnConflict(goqu.DoNothing()).
Executor().
Exec()
还是指某些field在插入是应该忽略?也是有的
type MyData struct {
ID uint64 `db:"id" goqu:"skipinsert,skipupdate"`
}
from dtm.
收到,这个留待后续优化,或者社区有人帮忙做了这个事情,可以合并进来
from dtm.
@sb-child postgresql已完整支持 https://dtm.pub/character/supported-db.html
from dtm.
Related Issues (20)
- C#客户端 saga执行事务时,demo设置了延时超过2秒之后,事务状态并没有更改为成功,反复重试 HOT 1
- The sql for creating the TDSql table is incorrect
- http_workflow_tcc_barrier 某种异常情况下,子事务 rollback 之后又会走到 commit 步骤 HOT 26
- saga grpc 加上ctx入参 HOT 5
- 关于异常信息的传递 HOT 5
- dtm真有管理后台? HOT 4
- 子事务屏障和幂等的问题?
- 能否将BranchBarrier中Call的提交和回滚提取出来 HOT 4
- clone run的时候出现的错误 HOT 5
- grpc_saga_passthroughHeaders 中间件设置header后接口中无法获取 HOT 5
- Can I provide a demo for accessing XA transactions in the go-zero framework HOT 1
- Azure MySQL SSL-mode requird
- XA全局事务成功后,DTM Admin 显示正常,但是本地数据库XA事务未提交,要修改的数据未变动,需要手动执行XA事务提交才生效 HOT 2
- Expect the Server to support SqlServer storage
- Lua not supported? HOT 1
- mod\github.com\dtm-labs\[email protected]\dtmimp\vars.go:48:22: undefined: dtmdriver.GetHTTPDriver HOT 2
- 并发情况下 偶尔会出现死锁 HOT 2
- 基于mysql做存储时间长了会不会影响性能? HOT 2
- 为什么二阶消息回查不直接由DTM HOT 2
- k8s部署时,如何配置MicroService的EndPoint? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dtm.