Compare commits

...

2 Commits

Author SHA1 Message Date
  liuyuecai 9383d21ca9 rename module 1 year ago
  liuyuecai 9d47af12bb rename module 1 year ago
100 changed files with 346 additions and 346 deletions
Split View
  1. +10
    -10
      .github/workflows/integrate-test.yml
  2. +1
    -1
      go.mod
  3. +12
    -12
      pkg/client/client.go
  4. +9
    -9
      pkg/client/config.go
  5. +1
    -1
      pkg/compressor/deflate_compress.go
  6. +1
    -1
      pkg/datasource/init.go
  7. +6
    -6
      pkg/datasource/sql/async_worker.go
  8. +6
    -6
      pkg/datasource/sql/at_resource_manager.go
  9. +3
    -3
      pkg/datasource/sql/conn.go
  10. +4
    -4
      pkg/datasource/sql/conn_at.go
  11. +5
    -5
      pkg/datasource/sql/conn_at_test.go
  12. +4
    -4
      pkg/datasource/sql/conn_xa.go
  13. +5
    -5
      pkg/datasource/sql/conn_xa_test.go
  14. +1
    -1
      pkg/datasource/sql/connector.go
  15. +4
    -4
      pkg/datasource/sql/connector_test.go
  16. +1
    -1
      pkg/datasource/sql/datasource/base/meta_cache.go
  17. +3
    -3
      pkg/datasource/sql/datasource/datasource_manager.go
  18. +2
    -2
      pkg/datasource/sql/datasource/mysql/meta_cache.go
  19. +2
    -2
      pkg/datasource/sql/datasource/mysql/trigger.go
  20. +7
    -7
      pkg/datasource/sql/db.go
  21. +6
    -6
      pkg/datasource/sql/driver.go
  22. +4
    -4
      pkg/datasource/sql/driver_test.go
  23. +5
    -5
      pkg/datasource/sql/exec/at/at_executor.go
  24. +4
    -4
      pkg/datasource/sql/exec/at/base_executor.go
  25. +1
    -1
      pkg/datasource/sql/exec/at/config.go
  26. +7
    -7
      pkg/datasource/sql/exec/at/delete_executor.go
  27. +4
    -4
      pkg/datasource/sql/exec/at/delete_executor_test.go
  28. +2
    -2
      pkg/datasource/sql/exec/at/escape.go
  29. +1
    -1
      pkg/datasource/sql/exec/at/escape_test.go
  30. +5
    -5
      pkg/datasource/sql/exec/at/insert_executor.go
  31. +6
    -6
      pkg/datasource/sql/exec/at/insert_executor_test.go
  32. +5
    -5
      pkg/datasource/sql/exec/at/insert_on_update_executor.go
  33. +3
    -3
      pkg/datasource/sql/exec/at/insert_on_update_executor_test.go
  34. +5
    -5
      pkg/datasource/sql/exec/at/multi_delete_executor.go
  35. +5
    -5
      pkg/datasource/sql/exec/at/multi_delete_executor_test.go
  36. +3
    -3
      pkg/datasource/sql/exec/at/multi_executor.go
  37. +7
    -7
      pkg/datasource/sql/exec/at/multi_update_excutor.go
  38. +7
    -7
      pkg/datasource/sql/exec/at/multi_update_excutor_test.go
  39. +2
    -2
      pkg/datasource/sql/exec/at/plain_executor.go
  40. +3
    -3
      pkg/datasource/sql/exec/at/plain_executor_test.go
  41. +10
    -10
      pkg/datasource/sql/exec/at/select_for_update_executor.go
  42. +2
    -2
      pkg/datasource/sql/exec/at/select_for_update_executor_test.go
  43. +7
    -7
      pkg/datasource/sql/exec/at/update_executor.go
  44. +8
    -8
      pkg/datasource/sql/exec/at/update_executor_test.go
  45. +2
    -2
      pkg/datasource/sql/exec/config/config.go
  46. +2
    -2
      pkg/datasource/sql/exec/executor.go
  47. +1
    -1
      pkg/datasource/sql/exec/hook.go
  48. +8
    -8
      pkg/datasource/sql/exec/select_for_update_executor.go
  49. +3
    -3
      pkg/datasource/sql/hook/logger_hook.go
  50. +5
    -5
      pkg/datasource/sql/hook/undo_log_hook.go
  51. +4
    -4
      pkg/datasource/sql/mock/mock_datasource_manager.go
  52. +2
    -2
      pkg/datasource/sql/parser/parse_factory_test.go
  53. +1
    -1
      pkg/datasource/sql/parser/parser_factory.go
  54. +7
    -7
      pkg/datasource/sql/plugin.go
  55. +3
    -3
      pkg/datasource/sql/stmt.go
  56. +6
    -6
      pkg/datasource/sql/tx.go
  57. +1
    -1
      pkg/datasource/sql/tx_at.go
  58. +1
    -1
      pkg/datasource/sql/types/executor.go
  59. +1
    -1
      pkg/datasource/sql/types/types.go
  60. +8
    -8
      pkg/datasource/sql/undo/base/undo.go
  61. +1
    -1
      pkg/datasource/sql/undo/builder/basic_undo_log_builder.go
  62. +1
    -1
      pkg/datasource/sql/undo/builder/basic_undo_log_builder_test.go
  63. +5
    -5
      pkg/datasource/sql/undo/builder/mysql_delete_undo_log_builder.go
  64. +1
    -1
      pkg/datasource/sql/undo/builder/mysql_delete_undo_log_builder_test.go
  65. +4
    -4
      pkg/datasource/sql/undo/builder/mysql_insert_undo_log_builder.go
  66. +4
    -4
      pkg/datasource/sql/undo/builder/mysql_insert_undo_log_builder_test.go
  67. +4
    -4
      pkg/datasource/sql/undo/builder/mysql_insertonduplicate_update_undo_log_builder.go
  68. +2
    -2
      pkg/datasource/sql/undo/builder/mysql_insertonduplicate_update_undo_log_builder_test.go
  69. +4
    -4
      pkg/datasource/sql/undo/builder/mysql_multi_delete_undo_log_builder.go
  70. +2
    -2
      pkg/datasource/sql/undo/builder/mysql_multi_undo_log_builder.go
  71. +4
    -4
      pkg/datasource/sql/undo/builder/mysql_multi_update_undo_log_builder.go
  72. +2
    -2
      pkg/datasource/sql/undo/builder/mysql_multi_update_undo_log_builder_test.go
  73. +5
    -5
      pkg/datasource/sql/undo/builder/mysql_update_undo_log_builder.go
  74. +5
    -5
      pkg/datasource/sql/undo/builder/mysql_update_undo_log_builder_test.go
  75. +1
    -1
      pkg/datasource/sql/undo/config.go
  76. +4
    -4
      pkg/datasource/sql/undo/executor/executor.go
  77. +2
    -2
      pkg/datasource/sql/undo/executor/mysql_undo_delete_executor.go
  78. +1
    -1
      pkg/datasource/sql/undo/executor/mysql_undo_executor_holder.go
  79. +2
    -2
      pkg/datasource/sql/undo/executor/mysql_undo_insert_executor.go
  80. +2
    -2
      pkg/datasource/sql/undo/executor/mysql_undo_update_executor.go
  81. +2
    -2
      pkg/datasource/sql/undo/executor/sql.go
  82. +1
    -1
      pkg/datasource/sql/undo/executor/sql_test.go
  83. +3
    -3
      pkg/datasource/sql/undo/executor/utils.go
  84. +3
    -3
      pkg/datasource/sql/undo/factor/undo_executor_factory.go
  85. +3
    -3
      pkg/datasource/sql/undo/factor/undo_executor_holder_factor.go
  86. +2
    -2
      pkg/datasource/sql/undo/mysql/default.go
  87. +3
    -3
      pkg/datasource/sql/undo/mysql/undo.go
  88. +1
    -1
      pkg/datasource/sql/undo/parser/parser_api.go
  89. +1
    -1
      pkg/datasource/sql/undo/parser/parser_json.go
  90. +1
    -1
      pkg/datasource/sql/undo/parser/parser_json_test.go
  91. +1
    -1
      pkg/datasource/sql/undo/undo.go
  92. +1
    -1
      pkg/datasource/sql/undo/undo_executor.go
  93. +2
    -2
      pkg/datasource/sql/undo_test.go
  94. +1
    -1
      pkg/datasource/sql/xa/mysql_xa_connection.go
  95. +1
    -1
      pkg/datasource/sql/xa/mysql_xa_connection_test.go
  96. +2
    -2
      pkg/datasource/sql/xa/xa_resource_factory.go
  97. +5
    -5
      pkg/datasource/sql/xa_resource_manager.go
  98. +1
    -1
      pkg/discovery/config.go
  99. +1
    -1
      pkg/discovery/etcd3.go
  100. +1
    -1
      pkg/discovery/etcd3_test.go

+ 10
- 10
.github/workflows/integrate-test.yml View File

@@ -62,13 +62,13 @@ jobs:
${{ runner.os }}-go-

# This step only runs when the event type is a pull_request
- name: Integrate Test
if: ${{ github.event_name == 'pull_request' }}
run: |
chmod +x integrate_test.sh && [[ -n "${{github.event.pull_request.head.repo.full_name}}" ]] && [[ -n "${{github.event.pull_request.head.sha}}" ]] && [[ -n "${{github.base_ref}}" ]] && ./integrate_test.sh ${{github.event.pull_request.head.repo.full_name}} ${{github.event.pull_request.head.sha}} ${{github.base_ref}}
# This step only runs when the event type is a push
- name: Integrate Test
if: ${{ github.event_name == 'push' }}
run: |
chmod +x integrate_test.sh && ./integrate_test.sh $GITHUB_REPOSITORY $GITHUB_SHA $GITHUB_BASE_REF
# - name: Integrate Test
# if: ${{ github.event_name == 'pull_request' }}
# run: |
# chmod +x integrate_test.sh && [[ -n "${{github.event.pull_request.head.repo.full_name}}" ]] && [[ -n "${{github.event.pull_request.head.sha}}" ]] && [[ -n "${{github.base_ref}}" ]] && ./integrate_test.sh ${{github.event.pull_request.head.repo.full_name}} ${{github.event.pull_request.head.sha}} ${{github.base_ref}}
#
# # This step only runs when the event type is a push
# - name: Integrate Test
# if: ${{ github.event_name == 'push' }}
# run: |
# chmod +x integrate_test.sh && ./integrate_test.sh $GITHUB_REPOSITORY $GITHUB_SHA $GITHUB_BASE_REF

+ 1
- 1
go.mod View File

@@ -1,4 +1,4 @@
module github.com/seata/seata-go
module github.com/apache/seata-go

go 1.18



+ 12
- 12
pkg/client/client.go View File

@@ -20,18 +20,18 @@ package client
import (
"sync"

"github.com/seata/seata-go/pkg/datasource"
at "github.com/seata/seata-go/pkg/datasource/sql"
"github.com/seata/seata-go/pkg/datasource/sql/exec/config"
"github.com/seata/seata-go/pkg/discovery"
"github.com/seata/seata-go/pkg/integration"
remoteConfig "github.com/seata/seata-go/pkg/remoting/config"
"github.com/seata/seata-go/pkg/remoting/getty"
"github.com/seata/seata-go/pkg/remoting/processor/client"
"github.com/seata/seata-go/pkg/rm"
"github.com/seata/seata-go/pkg/rm/tcc"
"github.com/seata/seata-go/pkg/tm"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource"
at "github.com/apache/seata-go/pkg/datasource/sql"
"github.com/apache/seata-go/pkg/datasource/sql/exec/config"
"github.com/apache/seata-go/pkg/discovery"
"github.com/apache/seata-go/pkg/integration"
remoteConfig "github.com/apache/seata-go/pkg/remoting/config"
"github.com/apache/seata-go/pkg/remoting/getty"
"github.com/apache/seata-go/pkg/remoting/processor/client"
"github.com/apache/seata-go/pkg/rm"
"github.com/apache/seata-go/pkg/rm/tcc"
"github.com/apache/seata-go/pkg/tm"
"github.com/apache/seata-go/pkg/util/log"
)

// Init seata client client


+ 9
- 9
pkg/client/config.go View File

@@ -32,15 +32,15 @@ import (
"github.com/knadh/koanf/parsers/yaml"
"github.com/knadh/koanf/providers/rawbytes"

"github.com/seata/seata-go/pkg/discovery"
"github.com/seata/seata-go/pkg/datasource/sql"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
remoteConfig "github.com/seata/seata-go/pkg/remoting/config"
"github.com/seata/seata-go/pkg/rm"
"github.com/seata/seata-go/pkg/rm/tcc"
"github.com/seata/seata-go/pkg/tm"
"github.com/seata/seata-go/pkg/util/flagext"
"github.com/apache/seata-go/pkg/discovery"
"github.com/apache/seata-go/pkg/datasource/sql"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
remoteConfig "github.com/apache/seata-go/pkg/remoting/config"
"github.com/apache/seata-go/pkg/rm"
"github.com/apache/seata-go/pkg/rm/tcc"
"github.com/apache/seata-go/pkg/tm"
"github.com/apache/seata-go/pkg/util/flagext"
)

const (


+ 1
- 1
pkg/compressor/deflate_compress.go View File

@@ -22,7 +22,7 @@ import (
"compress/flate"
"io"

"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/util/log"
)

type DeflateCompress struct{}


+ 1
- 1
pkg/datasource/init.go View File

@@ -18,7 +18,7 @@
package datasource

import (
"github.com/seata/seata-go/pkg/datasource/sql"
"github.com/apache/seata-go/pkg/datasource/sql"
)

func Init() {


+ 6
- 6
pkg/datasource/sql/async_worker.go View File

@@ -22,16 +22,16 @@ import (
"flag"
"time"

"github.com/seata/seata-go/pkg/rm"
"github.com/apache/seata-go/pkg/rm"

"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/client_golang/prometheus/promauto"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/util/fanout"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/util/fanout"
"github.com/apache/seata-go/pkg/util/log"
)

type phaseTwoContext struct {


+ 6
- 6
pkg/datasource/sql/at_resource_manager.go View File

@@ -25,12 +25,12 @@ import (

"github.com/prometheus/client_golang/prometheus"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/rm"
serr "github.com/seata/seata-go/pkg/util/errors"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/rm"
serr "github.com/apache/seata-go/pkg/util/errors"
)

func InitAT(cfg undo.Config, asyncCfg AsyncWorkerConfig) {


+ 3
- 3
pkg/datasource/sql/conn.go View File

@@ -21,9 +21,9 @@ import (
"context"
"database/sql/driver"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
)

// Conn is a connection to a database. It is not used concurrently


+ 4
- 4
pkg/datasource/sql/conn_at.go View File

@@ -22,10 +22,10 @@ import (
gosql "database/sql"
"database/sql/driver"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/tm"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/tm"
"github.com/apache/seata-go/pkg/util/log"
)

// ATConn Database connection proxy object under XA transaction model


+ 5
- 5
pkg/datasource/sql/conn_at_test.go View File

@@ -28,11 +28,11 @@ import (
"github.com/google/uuid"
"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/mock"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/tm"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/mock"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/tm"
)

func TestMain(m *testing.M) {


+ 4
- 4
pkg/datasource/sql/conn_xa.go View File

@@ -25,10 +25,10 @@ import (
"fmt"
"time"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/xa"
"github.com/seata/seata-go/pkg/tm"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/xa"
"github.com/apache/seata-go/pkg/tm"
"github.com/apache/seata-go/pkg/util/log"
)

var xaConnTimeout time.Duration


+ 5
- 5
pkg/datasource/sql/conn_xa_test.go View File

@@ -31,11 +31,11 @@ import (
"github.com/google/uuid"
"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/mock"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/tm"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/mock"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/tm"
)

type mysqlMockRows struct {


+ 1
- 1
pkg/datasource/sql/connector.go View File

@@ -24,7 +24,7 @@ import (

"github.com/go-sql-driver/mysql"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

type seataATConnector struct {


+ 4
- 4
pkg/datasource/sql/connector_test.go View File

@@ -27,10 +27,10 @@ import (
"github.com/golang/mock/gomock"
"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/mock"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/util/reflectx"
"github.com/apache/seata-go/pkg/datasource/sql/mock"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/util/reflectx"
)

type initConnectorFunc func(t *testing.T, ctrl *gomock.Controller) driver.Connector


+ 1
- 1
pkg/datasource/sql/datasource/base/meta_cache.go View File

@@ -24,7 +24,7 @@ import (
"sync"
"time"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

type (


+ 3
- 3
pkg/datasource/sql/datasource/datasource_manager.go View File

@@ -23,9 +23,9 @@ import (
"fmt"
"sync"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/rm"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/rm"
)

var (


+ 2
- 2
pkg/datasource/sql/datasource/mysql/meta_cache.go View File

@@ -24,8 +24,8 @@ import (
"sync"
"time"

"github.com/seata/seata-go/pkg/datasource/sql/datasource/base"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/datasource/base"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

var (


+ 2
- 2
pkg/datasource/sql/datasource/mysql/trigger.go View File

@@ -25,8 +25,8 @@ import (

"github.com/pkg/errors"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo/executor"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo/executor"
)

type mysqlTrigger struct {


+ 7
- 7
pkg/datasource/sql/db.go View File

@@ -24,13 +24,13 @@ import (
"fmt"
"sync"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/datasource/sql/xa"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/datasource/sql/xa"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/util/log"
)

type dbOption func(db *DBResource)


+ 6
- 6
pkg/datasource/sql/driver.go View File

@@ -29,12 +29,12 @@ import (

"github.com/go-sql-driver/mysql"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
mysql2 "github.com/seata/seata-go/pkg/datasource/sql/datasource/mysql"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
mysql2 "github.com/apache/seata-go/pkg/datasource/sql/datasource/mysql"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/util/log"
)

const (


+ 4
- 4
pkg/datasource/sql/driver_test.go View File

@@ -24,14 +24,14 @@ import (
"reflect"
"testing"

"github.com/seata/seata-go/pkg/rm"
"github.com/apache/seata-go/pkg/rm"

"github.com/golang/mock/gomock"
"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/mock"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/util/reflectx"
"github.com/apache/seata-go/pkg/datasource/sql/mock"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/util/reflectx"
)

func initMockResourceManager(branchType branch.BranchType, ctrl *gomock.Controller) *mock.MockDataSourceManager {


+ 5
- 5
pkg/datasource/sql/exec/at/at_executor.go View File

@@ -20,11 +20,11 @@ package at
import (
"context"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/tm"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/tm"
)

func Init() {


+ 4
- 4
pkg/datasource/sql/exec/at/base_executor.go View File

@@ -29,10 +29,10 @@ import (
"github.com/arana-db/parser/test_driver"
gxsort "github.com/dubbogo/gost/sort"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/util/reflectx"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/util/reflectx"
)

type baseExecutor struct {


+ 1
- 1
pkg/datasource/sql/exec/at/config.go View File

@@ -17,6 +17,6 @@

package at

import "github.com/seata/seata-go/pkg/rm"
import "github.com/apache/seata-go/pkg/rm"

var LockConfig rm.LockConfig

+ 7
- 7
pkg/datasource/sql/exec/at/delete_executor.go View File

@@ -25,13 +25,13 @@ import (
"github.com/arana-db/parser/ast"
"github.com/arana-db/parser/format"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/util/bytes"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/util/bytes"
"github.com/apache/seata-go/pkg/util/log"
)

// deleteExecutor execute delete SQL


+ 4
- 4
pkg/datasource/sql/exec/at/delete_executor_test.go View File

@@ -23,10 +23,10 @@ import (

"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
)

func TestNewDeleteExecutor(t *testing.T) {


+ 2
- 2
pkg/datasource/sql/exec/at/escape.go View File

@@ -21,8 +21,8 @@ import (
"database/sql"
"strings"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
)

const (


+ 1
- 1
pkg/datasource/sql/exec/at/escape_test.go View File

@@ -21,7 +21,7 @@ import (
"log"
"testing"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"

"github.com/stretchr/testify/assert"
)


+ 5
- 5
pkg/datasource/sql/exec/at/insert_executor.go View File

@@ -25,11 +25,11 @@ import (

"github.com/arana-db/parser/ast"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/util/log"
)

const (


+ 6
- 6
pkg/datasource/sql/exec/at/insert_executor_test.go View File

@@ -29,12 +29,12 @@ import (
"github.com/arana-db/parser/test_driver"
"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/datasource/mysql"
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/datasource/mysql"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
)

func TestBuildSelectSQLByInsert(t *testing.T) {


+ 5
- 5
pkg/datasource/sql/exec/at/insert_on_update_executor.go View File

@@ -25,11 +25,11 @@ import (

"github.com/arana-db/parser/ast"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/util/log"
)

// insertOnUpdateExecutor execute insert on update SQL


+ 3
- 3
pkg/datasource/sql/exec/at/insert_on_update_executor_test.go View File

@@ -23,9 +23,9 @@ import (

"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
)

func TestInsertOnUpdateBeforeImageSQL(t *testing.T) {


+ 5
- 5
pkg/datasource/sql/exec/at/multi_delete_executor.go View File

@@ -26,11 +26,11 @@ import (
"github.com/arana-db/parser/ast"
"github.com/arana-db/parser/format"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/util/log"
)

type multiDeleteExecutor struct {


+ 5
- 5
pkg/datasource/sql/exec/at/multi_delete_executor_test.go View File

@@ -23,11 +23,11 @@ import (

"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/util/log"
)

func Test_multiDeleteExecutor_buildBeforeImageSQL(t *testing.T) {


+ 3
- 3
pkg/datasource/sql/exec/at/multi_executor.go View File

@@ -21,9 +21,9 @@ import (
"context"
"fmt"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/util/log"
)

type multiExecutor struct {


+ 7
- 7
pkg/datasource/sql/exec/at/multi_update_excutor.go View File

@@ -29,13 +29,13 @@ import (
"github.com/arana-db/parser/model"
"github.com/pkg/errors"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/util/bytes"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/util/bytes"
"github.com/apache/seata-go/pkg/util/log"
)

// multiUpdateExecutor execute multiple update SQL


+ 7
- 7
pkg/datasource/sql/exec/at/multi_update_excutor_test.go View File

@@ -23,13 +23,13 @@ import (

"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/datasource/mysql"
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/datasource/mysql"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/util"
)

func TestBuildSelectSQLByMultiUpdate(t *testing.T) {


+ 2
- 2
pkg/datasource/sql/exec/at/plain_executor.go View File

@@ -20,8 +20,8 @@ package at
import (
"context"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

type plainExecutor struct {


+ 3
- 3
pkg/datasource/sql/exec/at/plain_executor_test.go View File

@@ -26,9 +26,9 @@ import (
"github.com/DATA-DOG/go-sqlmock"
"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/mock"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/mock"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

func TestNewPlainExecutor(t *testing.T) {


+ 10
- 10
pkg/datasource/sql/exec/at/select_for_update_executor.go View File

@@ -27,21 +27,21 @@ import (
"reflect"
"time"

"github.com/seata/seata-go/pkg/tm"
"github.com/apache/seata-go/pkg/tm"

"github.com/arana-db/parser/ast"
"github.com/arana-db/parser/format"
"github.com/arana-db/parser/model"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/rm"
"github.com/seata/seata-go/pkg/util/backoff"
seatabytes "github.com/seata/seata-go/pkg/util/bytes"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/rm"
"github.com/apache/seata-go/pkg/util/backoff"
seatabytes "github.com/apache/seata-go/pkg/util/bytes"
"github.com/apache/seata-go/pkg/util/log"
)

var (


+ 2
- 2
pkg/datasource/sql/exec/at/select_for_update_executor_test.go View File

@@ -24,8 +24,8 @@ import (

"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

var (


+ 7
- 7
pkg/datasource/sql/exec/at/update_executor.go View File

@@ -27,13 +27,13 @@ import (
"github.com/arana-db/parser/format"
"github.com/arana-db/parser/model"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/seata/seata-go/pkg/util/bytes"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/util/bytes"
"github.com/apache/seata-go/pkg/util/log"
)

var (


+ 8
- 8
pkg/datasource/sql/exec/at/update_executor_test.go View File

@@ -26,14 +26,14 @@ import (
"github.com/agiledragon/gomonkey/v2"
"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/datasource/mysql"
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/util"
_ "github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/datasource/mysql"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/util"
_ "github.com/apache/seata-go/pkg/util/log"
)

func TestBuildSelectSQLByUpdate(t *testing.T) {


+ 2
- 2
pkg/datasource/sql/exec/config/config.go View File

@@ -18,8 +18,8 @@
package config

import (
"github.com/seata/seata-go/pkg/datasource/sql/exec/at"
"github.com/seata/seata-go/pkg/rm"
"github.com/apache/seata-go/pkg/datasource/sql/exec/at"
"github.com/apache/seata-go/pkg/rm"
)

func Init(config rm.LockConfig) {


+ 2
- 2
pkg/datasource/sql/exec/executor.go View File

@@ -21,8 +21,8 @@ import (
"context"
"database/sql/driver"

"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

var (


+ 1
- 1
pkg/datasource/sql/exec/hook.go View File

@@ -20,7 +20,7 @@ package exec
import (
"context"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

var (


+ 8
- 8
pkg/datasource/sql/exec/select_for_update_executor.go View File

@@ -25,19 +25,19 @@ import (
"io"
"time"

"github.com/seata/seata-go/pkg/tm"
"github.com/apache/seata-go/pkg/tm"

"github.com/arana-db/parser/ast"
"github.com/arana-db/parser/format"
"github.com/arana-db/parser/model"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo/builder"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/rm"
seatabytes "github.com/seata/seata-go/pkg/util/bytes"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo/builder"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/rm"
seatabytes "github.com/apache/seata-go/pkg/util/bytes"
"github.com/apache/seata-go/pkg/util/log"
)

const (


+ 3
- 3
pkg/datasource/sql/hook/logger_hook.go View File

@@ -20,12 +20,12 @@ package hook
import (
"context"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/exec"

"go.uber.org/zap"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/util/log"
)

func NewLoggerSQLHook() exec.SQLHook {


+ 5
- 5
pkg/datasource/sql/hook/undo_log_hook.go View File

@@ -20,11 +20,11 @@ package hook
import (
"context"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/tm"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/tm"
)

func NewUndoLogSQLHook() exec.SQLHook {


+ 4
- 4
pkg/datasource/sql/mock/mock_datasource_manager.go View File

@@ -29,10 +29,10 @@ import (

gomock "github.com/golang/mock/gomock"

datasource "github.com/seata/seata-go/pkg/datasource/sql/datasource"
types "github.com/seata/seata-go/pkg/datasource/sql/types"
branch "github.com/seata/seata-go/pkg/protocol/branch"
rm "github.com/seata/seata-go/pkg/rm"
datasource "github.com/apache/seata-go/pkg/datasource/sql/datasource"
types "github.com/apache/seata-go/pkg/datasource/sql/types"
branch "github.com/apache/seata-go/pkg/protocol/branch"
rm "github.com/apache/seata-go/pkg/rm"
)

// MockDataSourceManager is a mock of DataSourceManager interface.


+ 2
- 2
pkg/datasource/sql/parser/parse_factory_test.go View File

@@ -24,11 +24,11 @@ import (
aparser "github.com/arana-db/parser"
"github.com/arana-db/parser/format"

"github.com/seata/seata-go/pkg/util/bytes"
"github.com/apache/seata-go/pkg/util/bytes"

"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"

_ "github.com/arana-db/parser/test_driver"
)


+ 1
- 1
pkg/datasource/sql/parser/parser_factory.go View File

@@ -21,7 +21,7 @@ import (
aparser "github.com/arana-db/parser"
"github.com/arana-db/parser/ast"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

func DoParser(query string) (*types.ParseContext, error) {


+ 7
- 7
pkg/datasource/sql/plugin.go View File

@@ -18,13 +18,13 @@
package sql

import (
"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/exec/at"
"github.com/seata/seata-go/pkg/datasource/sql/hook"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/undo/builder"
"github.com/seata/seata-go/pkg/datasource/sql/undo/mysql"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/exec/at"
"github.com/apache/seata-go/pkg/datasource/sql/hook"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo/builder"
"github.com/apache/seata-go/pkg/datasource/sql/undo/mysql"
)

func Init() {


+ 3
- 3
pkg/datasource/sql/stmt.go View File

@@ -21,9 +21,9 @@ import (
"context"
"database/sql/driver"

"github.com/seata/seata-go/pkg/datasource/sql/exec"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/util"
"github.com/apache/seata-go/pkg/datasource/sql/exec"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/util"
)

type Stmt struct {


+ 6
- 6
pkg/datasource/sql/tx.go View File

@@ -24,12 +24,12 @@ import (
"sync"
"time"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/rm"
"github.com/seata/seata-go/pkg/util/backoff"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/rm"
"github.com/apache/seata-go/pkg/util/backoff"
"github.com/apache/seata-go/pkg/util/log"
)

var (


+ 1
- 1
pkg/datasource/sql/tx_at.go View File

@@ -20,7 +20,7 @@ package sql
import (
"github.com/pkg/errors"

"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
)

// ATTx


+ 1
- 1
pkg/datasource/sql/types/executor.go View File

@@ -23,7 +23,7 @@ import (
"github.com/arana-db/parser/ast"
"github.com/arana-db/parser/format"

seatabytes "github.com/seata/seata-go/pkg/util/bytes"
seatabytes "github.com/apache/seata-go/pkg/util/bytes"
)

type ExecutorType int32


+ 1
- 1
pkg/datasource/sql/types/types.go View File

@@ -24,7 +24,7 @@ import (

"github.com/google/uuid"

"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/protocol/branch"
)

type DBType int16


+ 8
- 8
pkg/datasource/sql/undo/base/undo.go View File

@@ -29,14 +29,14 @@ import (

"github.com/arana-db/parser/mysql"

"github.com/seata/seata-go/pkg/compressor"
"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/undo/factor"
"github.com/seata/seata-go/pkg/datasource/sql/undo/parser"
"github.com/seata/seata-go/pkg/util/collection"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/compressor"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo/factor"
"github.com/apache/seata-go/pkg/datasource/sql/undo/parser"
"github.com/apache/seata-go/pkg/util/collection"
"github.com/apache/seata-go/pkg/util/log"
)

const (


+ 1
- 1
pkg/datasource/sql/undo/builder/basic_undo_log_builder.go View File

@@ -29,7 +29,7 @@ import (
"github.com/arana-db/parser/test_driver"
gxsort "github.com/dubbogo/gost/sort"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

// todo the executor should be stateful


+ 1
- 1
pkg/datasource/sql/undo/builder/basic_undo_log_builder_test.go View File

@@ -22,7 +22,7 @@ import (

"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

func TestBuildWhereConditionByPKs(t *testing.T) {


+ 5
- 5
pkg/datasource/sql/undo/builder/mysql_delete_undo_log_builder.go View File

@@ -22,16 +22,16 @@ import (
"database/sql/driver"
"fmt"

"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo"

"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/parser"

"github.com/arana-db/parser/ast"
"github.com/arana-db/parser/format"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/util/bytes"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/util/bytes"
"github.com/apache/seata-go/pkg/util/log"
)

type MySQLDeleteUndoLogBuilder struct {


+ 1
- 1
pkg/datasource/sql/undo/builder/mysql_delete_undo_log_builder_test.go View File

@@ -21,7 +21,7 @@ import (
"database/sql/driver"
"testing"

"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/util/log"

"github.com/stretchr/testify/assert"
)


+ 4
- 4
pkg/datasource/sql/undo/builder/mysql_insert_undo_log_builder.go View File

@@ -25,10 +25,10 @@ import (

"github.com/arana-db/parser/ast"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/undo/executor"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo/executor"
"github.com/apache/seata-go/pkg/util/log"
)

const (


+ 4
- 4
pkg/datasource/sql/undo/builder/mysql_insert_undo_log_builder_test.go View File

@@ -22,7 +22,7 @@ import (
"database/sql/driver"
"testing"

_ "github.com/seata/seata-go/pkg/util/log"
_ "github.com/apache/seata-go/pkg/util/log"

"github.com/arana-db/parser/test_driver"

@@ -32,9 +32,9 @@ import (
"github.com/DATA-DOG/go-sqlmock"
"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/mock"
"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/mock"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

func TestBuildSelectSQLByInsert(t *testing.T) {


+ 4
- 4
pkg/datasource/sql/undo/builder/mysql_insertonduplicate_update_undo_log_builder.go View File

@@ -25,10 +25,10 @@ import (

"github.com/arana-db/parser/ast"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/undo/executor"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo/executor"
"github.com/apache/seata-go/pkg/util/log"
)

type MySQLInsertOnDuplicateUndoLogBuilder struct {


+ 2
- 2
pkg/datasource/sql/undo/builder/mysql_insertonduplicate_update_undo_log_builder_test.go View File

@@ -25,8 +25,8 @@ import (

"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

func TestInsertOnDuplicateBuildBeforeImageSQL(t *testing.T) {


+ 4
- 4
pkg/datasource/sql/undo/builder/mysql_multi_delete_undo_log_builder.go View File

@@ -26,10 +26,10 @@ import (
"github.com/arana-db/parser/ast"
"github.com/arana-db/parser/format"

"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/util/log"
)

type multiDelete struct {


+ 2
- 2
pkg/datasource/sql/undo/builder/mysql_multi_undo_log_builder.go View File

@@ -20,8 +20,8 @@ package builder
import (
"context"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
)

type MySQLMultiUndoLogBuilder struct {


+ 4
- 4
pkg/datasource/sql/undo/builder/mysql_multi_update_undo_log_builder.go View File

@@ -28,10 +28,10 @@ import (
"github.com/arana-db/parser/format"
"github.com/pkg/errors"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/util/bytes"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/util/bytes"
"github.com/apache/seata-go/pkg/util/log"
)

//func init() {


+ 2
- 2
pkg/datasource/sql/undo/builder/mysql_multi_update_undo_log_builder_test.go View File

@@ -25,8 +25,8 @@ import (
_ "github.com/arana-db/parser/test_driver"
"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/parser"
_ "github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/parser"
_ "github.com/apache/seata-go/pkg/util/log"
)

func TestBuildSelectSQLByMultiUpdate(t *testing.T) {


+ 5
- 5
pkg/datasource/sql/undo/builder/mysql_update_undo_log_builder.go View File

@@ -27,12 +27,12 @@ import (
"github.com/arana-db/parser/format"
"github.com/arana-db/parser/model"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/util/bytes"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/util/bytes"
"github.com/apache/seata-go/pkg/util/log"
)

const (


+ 5
- 5
pkg/datasource/sql/undo/builder/mysql_update_undo_log_builder_test.go View File

@@ -25,17 +25,17 @@ import (

"github.com/agiledragon/gomonkey/v2"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"

"github.com/seata/seata-go/pkg/datasource/sql/datasource/mysql"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/datasource/mysql"
"github.com/apache/seata-go/pkg/datasource/sql/types"

"github.com/seata/seata-go/pkg/datasource/sql/parser"
"github.com/apache/seata-go/pkg/datasource/sql/parser"

_ "github.com/arana-db/parser/test_driver"
"github.com/stretchr/testify/assert"

_ "github.com/seata/seata-go/pkg/util/log"
_ "github.com/apache/seata-go/pkg/util/log"
)

func TestBuildSelectSQLByUpdate(t *testing.T) {


+ 1
- 1
pkg/datasource/sql/undo/config.go View File

@@ -20,7 +20,7 @@ package undo
import (
"flag"

"github.com/seata/seata-go/pkg/compressor"
"github.com/apache/seata-go/pkg/compressor"
)

var (


+ 4
- 4
pkg/datasource/sql/undo/executor/executor.go View File

@@ -26,10 +26,10 @@ import (

"github.com/goccy/go-json"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/util/log"
)

var _ undo.UndoExecutor = (*BaseExecutor)(nil)


+ 2
- 2
pkg/datasource/sql/undo/executor/mysql_undo_delete_executor.go View File

@@ -23,8 +23,8 @@ import (
"fmt"
"strings"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
)

type mySQLUndoDeleteExecutor struct {


+ 1
- 1
pkg/datasource/sql/undo/executor/mysql_undo_executor_holder.go View File

@@ -18,7 +18,7 @@
package executor

import (
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
)

type MySQLUndoExecutorHolder struct {


+ 2
- 2
pkg/datasource/sql/undo/executor/mysql_undo_insert_executor.go View File

@@ -22,8 +22,8 @@ import (
"database/sql"
"fmt"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
)

type mySQLUndoInsertExecutor struct {


+ 2
- 2
pkg/datasource/sql/undo/executor/mysql_undo_update_executor.go View File

@@ -23,8 +23,8 @@ import (
"fmt"
"strings"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
)

type mySQLUndoUpdateExecutor struct {


+ 2
- 2
pkg/datasource/sql/undo/executor/sql.go View File

@@ -21,8 +21,8 @@ import (
"database/sql"
"strings"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
)

const (


+ 1
- 1
pkg/datasource/sql/undo/executor/sql_test.go View File

@@ -21,7 +21,7 @@ import (
"log"
"testing"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"

"github.com/stretchr/testify/assert"
)


+ 3
- 3
pkg/datasource/sql/undo/executor/utils.go View File

@@ -21,9 +21,9 @@ import (
"fmt"
"strings"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/util/log"
)

// IsRecordsEquals check before record and after record if equal


+ 3
- 3
pkg/datasource/sql/undo/factor/undo_executor_factory.go View File

@@ -20,9 +20,9 @@ package factor
import (
"fmt"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/util/log"
)

func GetUndoExecutor(dbType types.DBType, sqlUndoLog undo.SQLUndoLog) (res undo.UndoExecutor, err error) {


+ 3
- 3
pkg/datasource/sql/undo/factor/undo_executor_holder_factor.go View File

@@ -20,9 +20,9 @@ package factor
import (
"errors"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/undo/executor"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo/executor"
)

var undoExecutorHolderMap map[types.DBType]undo.UndoExecutorHolder


+ 2
- 2
pkg/datasource/sql/undo/mysql/default.go View File

@@ -20,8 +20,8 @@ package mysql
import (
"github.com/pkg/errors"

"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/undo/base"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo/base"
)

func InitUndoLogManager() {


+ 3
- 3
pkg/datasource/sql/undo/mysql/undo.go View File

@@ -22,9 +22,9 @@ import (
"database/sql"
"database/sql/driver"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/seata/seata-go/pkg/datasource/sql/undo/base"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo/base"
)

var _ undo.UndoLogManager = (*undoLogManager)(nil)


+ 1
- 1
pkg/datasource/sql/undo/parser/parser_api.go View File

@@ -17,7 +17,7 @@

package parser

import "github.com/seata/seata-go/pkg/datasource/sql/undo"
import "github.com/apache/seata-go/pkg/datasource/sql/undo"

// The interface Undo log parser.
type UndoLogParser interface {


+ 1
- 1
pkg/datasource/sql/undo/parser/parser_json.go View File

@@ -20,7 +20,7 @@ package parser
import (
"encoding/json"

"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
)

type JsonParser struct {


+ 1
- 1
pkg/datasource/sql/undo/parser/parser_json_test.go View File

@@ -22,7 +22,7 @@ import (

"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/undo"
"github.com/apache/seata-go/pkg/datasource/sql/undo"
)

func TestGetName(t *testing.T) {


+ 1
- 1
pkg/datasource/sql/undo/undo.go View File

@@ -24,7 +24,7 @@ import (
"fmt"
"sync"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

var (


+ 1
- 1
pkg/datasource/sql/undo/undo_executor.go View File

@@ -21,7 +21,7 @@ import (
"context"
"database/sql"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/datasource/sql/types"
)

type UndoExecutor interface {


+ 2
- 2
pkg/datasource/sql/undo_test.go View File

@@ -24,8 +24,8 @@ import (

"github.com/stretchr/testify/assert"

"github.com/seata/seata-go/pkg/datasource/sql/undo/base"
"github.com/seata/seata-go/pkg/datasource/sql/undo/mysql"
"github.com/apache/seata-go/pkg/datasource/sql/undo/base"
"github.com/apache/seata-go/pkg/datasource/sql/undo/mysql"
)

// TestBatchDeleteUndoLogs


+ 1
- 1
pkg/datasource/sql/xa/mysql_xa_connection.go View File

@@ -26,7 +26,7 @@ import (
"strings"
"time"

"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/util/log"
)

type MysqlXAConn struct {


+ 1
- 1
pkg/datasource/sql/xa/mysql_xa_connection_test.go View File

@@ -28,7 +28,7 @@ import (

"github.com/golang/mock/gomock"

"github.com/seata/seata-go/pkg/datasource/sql/mock"
"github.com/apache/seata-go/pkg/datasource/sql/mock"
)

func TestMysqlXAConn_Commit(t *testing.T) {


+ 2
- 2
pkg/datasource/sql/xa/xa_resource_factory.go View File

@@ -21,8 +21,8 @@ import (
"database/sql/driver"
"fmt"

"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/util/log"
)

// CreateXAResource create a connection for xa with the different db type.


+ 5
- 5
pkg/datasource/sql/xa_resource_manager.go View File

@@ -28,11 +28,11 @@ import (

"github.com/bluele/gcache"

"github.com/seata/seata-go/pkg/datasource/sql/datasource"
"github.com/seata/seata-go/pkg/datasource/sql/types"
"github.com/seata/seata-go/pkg/protocol/branch"
"github.com/seata/seata-go/pkg/rm"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/datasource/sql/datasource"
"github.com/apache/seata-go/pkg/datasource/sql/types"
"github.com/apache/seata-go/pkg/protocol/branch"
"github.com/apache/seata-go/pkg/rm"
"github.com/apache/seata-go/pkg/util/log"
)

var branchStatusCache gcache.Cache


+ 1
- 1
pkg/discovery/config.go View File

@@ -20,7 +20,7 @@ package discovery
import (
"flag"

"github.com/seata/seata-go/pkg/util/flagext"
"github.com/apache/seata-go/pkg/util/flagext"
)

type ServiceConfig struct {


+ 1
- 1
pkg/discovery/etcd3.go View File

@@ -20,7 +20,7 @@ package discovery
import (
"context"
"fmt"
"github.com/seata/seata-go/pkg/util/log"
"github.com/apache/seata-go/pkg/util/log"
etcd3 "go.etcd.io/etcd/client/v3"
"strconv"
"strings"


+ 1
- 1
pkg/discovery/etcd3_test.go View File

@@ -1,8 +1,8 @@
package discovery

import (
"github.com/apache/seata-go/pkg/discovery/mock"
"github.com/golang/mock/gomock"
"github.com/seata/seata-go/pkg/discovery/mock"
"github.com/stretchr/testify/assert"
"go.etcd.io/etcd/api/v3/mvccpb"
"go.etcd.io/etcd/client/v3"


Some files were not shown because too many files changed in this diff

Loading…
Cancel
Save