Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[azdatalake] upgrade azblob version to 1.21 #22196

Merged
merged 8 commits into from
Jan 3, 2024
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions sdk/storage/azdatalake/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
### Bugs Fixed

### Other Changes
* Updated version of azblob to 1.2.1

## 1.0.0 (2023-10-18)

Expand Down
2 changes: 1 addition & 1 deletion sdk/storage/azdatalake/assets.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
"AssetsRepo": "Azure/azure-sdk-assets",
"AssetsRepoPrefixPath": "go",
"TagPrefix": "go/storage/azdatalake",
"Tag": "go/storage/azdatalake_ba5bfaa832"
"Tag": "go/storage/azdatalake_abd1896b54"
}
65 changes: 45 additions & 20 deletions sdk/storage/azdatalake/file/client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4185,10 +4185,6 @@ func (s *RecordedTestSuite) TestFileUploadDownloadSmallFile() {
err = os.Remove(name)
_require.NoError(err)
}(destFileName)
defer func(destFile *os.File) {
err = destFile.Close()
_require.NoError(err)
}(destFile)

cnt, err := fClient.DownloadFile(context.Background(), destFile, &file.DownloadFileOptions{
ChunkSize: 2 * 1024,
Expand All @@ -4197,8 +4193,18 @@ func (s *RecordedTestSuite) TestFileUploadDownloadSmallFile() {
_require.NoError(err)
_require.Equal(cnt, fileSize)

err = destFile.Close()
_require.NoError(err)

newDestFileHandle, err := os.Open(destFileName)
_require.NoError(err)
defer func(file *os.File) {
err = file.Close()
_require.NoError(err)
}(newDestFileHandle)

destHash := md5.New()
_, err = io.Copy(destHash, destFile)
_, err = io.Copy(destHash, newDestFileHandle)
_require.NoError(err)
downloadedContentMD5 := destHash.Sum(nil)

Expand All @@ -4207,6 +4213,7 @@ func (s *RecordedTestSuite) TestFileUploadDownloadSmallFile() {
gResp2, err := fClient.GetProperties(context.Background(), nil)
_require.NoError(err)
_require.Equal(*gResp2.ContentLength, fileSize)

}

func (s *RecordedTestSuite) TestFileUploadDownloadSmallFileWithRange() {
Expand Down Expand Up @@ -4264,10 +4271,6 @@ func (s *RecordedTestSuite) TestFileUploadDownloadSmallFileWithRange() {
err = os.Remove(name)
_require.NoError(err)
}(destFileName)
defer func(destFile *os.File) {
err = destFile.Close()
_require.NoError(err)
}(destFile)

cnt, err := fClient.DownloadFile(context.Background(), destFile, &file.DownloadFileOptions{
ChunkSize: 2 * 1024,
Expand All @@ -4280,8 +4283,18 @@ func (s *RecordedTestSuite) TestFileUploadDownloadSmallFileWithRange() {
_require.NoError(err)
_require.Equal(cnt, fileSize)

err = destFile.Close()
_require.NoError(err)

newDestFileHandle, err := os.Open(destFileName)
_require.NoError(err)
defer func(file *os.File) {
err = file.Close()
_require.NoError(err)
}(newDestFileHandle)

destHash := md5.New()
_, err = io.Copy(destHash, destFile)
_, err = io.Copy(destHash, newDestFileHandle)
_require.NoError(err)
downloadedContentMD5 := destHash.Sum(nil)

Expand Down Expand Up @@ -4348,10 +4361,6 @@ func (s *RecordedTestSuite) TestFileUploadDownloadSmallFileWithAccessConditions(
err = os.Remove(name)
_require.NoError(err)
}(destFileName)
defer func(destFile *os.File) {
err = destFile.Close()
_require.NoError(err)
}(destFile)

cnt, err := fClient.DownloadFile(context.Background(), destFile, &file.DownloadFileOptions{
ChunkSize: 2 * 1024,
Expand All @@ -4369,8 +4378,18 @@ func (s *RecordedTestSuite) TestFileUploadDownloadSmallFileWithAccessConditions(
_require.NoError(err)
_require.Equal(cnt, fileSize)

err = destFile.Close()
_require.NoError(err)

newDestFileHandle, err := os.Open(destFileName)
_require.NoError(err)
defer func(file *os.File) {
err = file.Close()
_require.NoError(err)
}(newDestFileHandle)

destHash := md5.New()
_, err = io.Copy(destHash, destFile)
_, err = io.Copy(destHash, newDestFileHandle)
_require.NoError(err)
downloadedContentMD5 := destHash.Sum(nil)

Expand Down Expand Up @@ -4439,10 +4458,6 @@ func (s *RecordedTestSuite) TestFileUploadDownloadSmallFileWithCPK() {
err = os.Remove(name)
_require.NoError(err)
}(destFileName)
defer func(destFile *os.File) {
err = destFile.Close()
_require.NoError(err)
}(destFile)

cnt, err := fClient.DownloadFile(context.Background(), destFile, &file.DownloadFileOptions{
ChunkSize: 2 * 1024,
Expand All @@ -4456,8 +4471,18 @@ func (s *RecordedTestSuite) TestFileUploadDownloadSmallFileWithCPK() {
_require.NoError(err)
_require.Equal(cnt, fileSize)

err = destFile.Close()
_require.NoError(err)

newDestFileHandle, err := os.Open(destFileName)
_require.NoError(err)
defer func(file *os.File) {
err = file.Close()
_require.NoError(err)
}(newDestFileHandle)

destHash := md5.New()
_, err = io.Copy(destHash, destFile)
_, err = io.Copy(destHash, newDestFileHandle)
_require.NoError(err)
downloadedContentMD5 := destHash.Sum(nil)

Expand Down
14 changes: 7 additions & 7 deletions sdk/storage/azdatalake/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ module github.com/Azure/azure-sdk-for-go/sdk/storage/azdatalake
go 1.18

require (
github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.0
github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.1
github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.4.0
github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.0
github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.0.0
github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.1
github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.2.1
github.com/stretchr/testify v1.8.4
)

Expand All @@ -19,10 +19,10 @@ require (
github.com/kylelemons/godebug v1.1.0 // indirect
github.com/pkg/browser v0.0.0-20210911075715-681adbf594b8 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
golang.org/x/crypto v0.14.0 // indirect
golang.org/x/net v0.17.0 // indirect
golang.org/x/sys v0.13.0 // indirect
golang.org/x/text v0.13.0 // indirect
golang.org/x/crypto v0.16.0 // indirect
golang.org/x/net v0.19.0 // indirect
golang.org/x/sys v0.15.0 // indirect
golang.org/x/text v0.14.0 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
29 changes: 15 additions & 14 deletions sdk/storage/azdatalake/go.sum
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.0 h1:fb8kj/Dh4CSwgsOzHeZY4Xh68cFVbzXx+ONXGMY//4w=
github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.0/go.mod h1:uReU2sSxZExRPBAg3qKzmAucSi51+SP1OhohieR821Q=
github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.1 h1:lGlwhPtrX6EVml1hO0ivjkUxsSyl4dsiw9qcA1k/3IQ=
github.com/Azure/azure-sdk-for-go/sdk/azcore v1.9.1/go.mod h1:RKUqNu35KJYcVG/fqTRqmuXJZYNhYkBrnC/hX7yGbTA=
github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.4.0 h1:BMAjVKJM0U/CYF27gA0ZMmXGkOcvfFtD0oHVZ1TIPRI=
github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.4.0/go.mod h1:1fXstnBMas5kzG+S3q8UoJcmyU6nUeunJcMDHcRYHhs=
github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.0 h1:d81/ng9rET2YqdVkVwkb6EXeRrLJIwyGnJcAlAWKwhs=
github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.0/go.mod h1:s4kgfzA0covAXNicZHDMN58jExvcng2mC/DepXiF1EI=
github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.0.0 h1:u/LLAOFgsMv7HmNL4Qufg58y+qElGOt5qv0z1mURkRY=
github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.0.0/go.mod h1:2e8rMJtl2+2j+HXbTBwnyGpm5Nou7KhvSfxOq8JpTag=
github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.1 h1:6oNBlSdi1QqM1PNW7FPA6xOGA5UNsXnkaYZz9vdPGhA=
github.com/Azure/azure-sdk-for-go/sdk/internal v1.5.1/go.mod h1:s4kgfzA0covAXNicZHDMN58jExvcng2mC/DepXiF1EI=
github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage v1.5.0 h1:AifHbc4mg0x9zW52WOpKbsHaDKuRhlI7TVl47thgQ70=
github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.2.1 h1:AMf7YbZOZIW5b66cXNHMWWT/zkjhz5+a+k/3x40EO7E=
github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.2.1/go.mod h1:uwfk06ZBcvL/g4VHNjurPfVln9NMbsk2XIZxJ+hu81k=
github.com/AzureAD/microsoft-authentication-library-for-go v1.1.1 h1:WpB/QDNLpMw72xHJc34BNNykqSOeEJDAWkhf0u12/Jk=
github.com/AzureAD/microsoft-authentication-library-for-go v1.1.1/go.mod h1:wP83P5OoQ5p6ip3ScPr0BAq0BvuPAvacpEuSzyouqAI=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
Expand All @@ -25,15 +26,15 @@ github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZb
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk=
github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo=
golang.org/x/crypto v0.14.0 h1:wBqGXzWJW6m1XrIKlAH0Hs1JJ7+9KBwnIO8v66Q9cHc=
golang.org/x/crypto v0.14.0/go.mod h1:MVFd36DqK4CsrnJYDkBA3VC4m2GkXAM0PvzMCn4JQf4=
golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM=
golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE=
golang.org/x/crypto v0.16.0 h1:mMMrFzRSCF0GvB7Ne27XVtVAaXLrPmgPC7/v0tkwHaY=
golang.org/x/crypto v0.16.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4=
golang.org/x/net v0.19.0 h1:zTwKpTd2XuCqf8huc7Fo2iSy+4RHPd10s4KzeTnVr1c=
golang.org/x/net v0.19.0/go.mod h1:CfAk/cbD4CthTvqiEl8NpboMuiuOYsAr/7NOjZJtv1U=
golang.org/x/sys v0.0.0-20210616045830-e2b7044e8c71/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE=
golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k=
golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE=
golang.org/x/sys v0.15.0 h1:h48lPFYpsTvQJZF4EKyI4aLHaev3CxivZmv7yZig9pc=
golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ=
golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
Expand Down
Loading