Skip to content

Commit

Permalink
Upgrade Artie Transfer. (#483)
Browse files Browse the repository at this point in the history
  • Loading branch information
Tang8330 authored Sep 4, 2024
1 parent 7108f1b commit 3307cf6
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ go 1.23.0

require (
github.com/DataDog/datadog-go/v5 v5.5.0
github.com/artie-labs/transfer v1.26.19
github.com/artie-labs/transfer v1.26.25
github.com/aws/aws-sdk-go-v2 v1.30.3
github.com/aws/aws-sdk-go-v2/config v1.27.27
github.com/aws/aws-sdk-go-v2/credentials v1.17.27
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -93,8 +93,8 @@ github.com/apache/thrift v0.0.0-20181112125854-24918abba929/go.mod h1:cp2SuWMxlE
github.com/apache/thrift v0.14.2/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ=
github.com/apache/thrift v0.17.0 h1:cMd2aj52n+8VoAtvSvLn4kDC3aZ6IAkBuqWQ2IDu7wo=
github.com/apache/thrift v0.17.0/go.mod h1:OLxhMRJxomX+1I/KUw03qoV3mMz16BwaKI+d4fPBx7Q=
github.com/artie-labs/transfer v1.26.19 h1:mcSoEcfmvHyeu+gSXI3z0ZVSwH8diwMauR1154JBun0=
github.com/artie-labs/transfer v1.26.19/go.mod h1:+a/UhlQVRIpdz3muS1yhSvyX42RQL0LHOdovGZfEsDE=
github.com/artie-labs/transfer v1.26.25 h1:NnZ0eV7kpIDjf2jajJYuJksQl3B8Uy0ev7huSeeEP28=
github.com/artie-labs/transfer v1.26.25/go.mod h1:+a/UhlQVRIpdz3muS1yhSvyX42RQL0LHOdovGZfEsDE=
github.com/aws/aws-sdk-go v1.30.19/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0=
github.com/aws/aws-sdk-go-v2 v1.16.12/go.mod h1:C+Ym0ag2LIghJbXhfXZ0YEEp49rBWowxKzJLUoob0ts=
github.com/aws/aws-sdk-go-v2 v1.30.3 h1:jUeBtG0Ih+ZIFH0F4UkmL9w3cSpaMv9tYYDbzILP8dY=
Expand Down
9 changes: 7 additions & 2 deletions lib/debezium/converters/time_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"testing"
"time"

"github.com/artie-labs/transfer/lib/debezium"
"github.com/artie-labs/transfer/lib/typing"
"github.com/artie-labs/transfer/lib/typing/ext"
"github.com/stretchr/testify/assert"
)
Expand All @@ -26,7 +26,12 @@ func parseUsingTransfer(converter ValueConverter, value int64) (*ext.ExtendedTim
return extTime, nil
}

return debezium.FromDebeziumTypeToTime(converter.ToField("foo").DebeziumType, value)
parsedValue, err := converter.ToField("foo").ParseValue(value)
if err != nil {
return nil, err
}

return typing.AssertType[*ext.ExtendedTime](parsedValue)
}

func TestTimeConverter_Convert(t *testing.T) {
Expand Down

0 comments on commit 3307cf6

Please sign in to comment.