From e3ff13ee9344092382dd7bd72afce5d2bb3c8cb2 Mon Sep 17 00:00:00 2001 From: yedf2 <120050102@qq.com> Date: Wed, 8 Sep 2021 23:19:29 +0800 Subject: [PATCH] english docs updated --- README.md | 2 +- dtmsvr/api_http.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 0e9ca2b..55f5efe 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![Go Reference](https://pkg.go.dev/badge/github.com/yedf/dtm.svg)](https://pkg.go.dev/github.com/yedf/dtm) [![Mentioned in Awesome Go](https://awesome.re/mentioned-badge-flat.svg)](https://github.com/avelino/awesome-go#database) -# [English Docs](https://github.com/yedf/dtm/blob/main/README-en.md) +# [English Docs](https://en.dtm.pub) # GO语言分布式事务管理服务 DTM是首款golang的开源分布式事务管理器,优雅的解决了幂等、空补偿、悬挂等分布式事务难题。提供了简单易用、高性能、易水平扩展的分布式事务解决方案。 diff --git a/dtmsvr/api_http.go b/dtmsvr/api_http.go index 27d461c..ff3dea5 100644 --- a/dtmsvr/api_http.go +++ b/dtmsvr/api_http.go @@ -65,6 +65,7 @@ func query(c *gin.Context) (interface{}, error) { } trans := TransGlobal{} db := dbGet() + db.Begin() dbr := db.Must().Where("gid", gid).First(&trans) if dbr.Error == gorm.ErrRecordNotFound { return M{"transaction": nil, "branches": [0]int{}}, nil