Compare commits
7 Commits
master
...
feature/su
Author | SHA1 | Date |
---|---|---|
m.malygina | d03e2f5985 | |
m.malygina | f0e9f59a90 | |
m.malygina | afebe294cd | |
m.malygina | e987b6aef9 | |
m.malygina | 2f00260594 | |
Maria Malygina | c71fc8970f | |
Maria Malygina | 82a02cc8d2 |
|
@ -6,9 +6,6 @@ import (
|
||||||
"crypto/sha256"
|
"crypto/sha256"
|
||||||
"encoding/hex"
|
"encoding/hex"
|
||||||
"fmt"
|
"fmt"
|
||||||
"strconv"
|
|
||||||
"time"
|
|
||||||
|
|
||||||
"git.frostfs.info/TrueCloudLab/xk6-frostfs/internal/stats"
|
"git.frostfs.info/TrueCloudLab/xk6-frostfs/internal/stats"
|
||||||
"github.com/aws/aws-sdk-go-v2/aws"
|
"github.com/aws/aws-sdk-go-v2/aws"
|
||||||
"github.com/aws/aws-sdk-go-v2/feature/s3/manager"
|
"github.com/aws/aws-sdk-go-v2/feature/s3/manager"
|
||||||
|
@ -17,6 +14,8 @@ import (
|
||||||
"github.com/dop251/goja"
|
"github.com/dop251/goja"
|
||||||
"go.k6.io/k6/js/modules"
|
"go.k6.io/k6/js/modules"
|
||||||
"go.k6.io/k6/metrics"
|
"go.k6.io/k6/metrics"
|
||||||
|
"strconv"
|
||||||
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
type (
|
type (
|
||||||
|
@ -61,6 +60,7 @@ func (c *Client) Put(bucket, key string, payload goja.ArrayBuffer) PutResponse {
|
||||||
Key: aws.String(key),
|
Key: aws.String(key),
|
||||||
Body: rdr,
|
Body: rdr,
|
||||||
})
|
})
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
stats.Report(c.vu, objPutFails, 1)
|
stats.Report(c.vu, objPutFails, 1)
|
||||||
return PutResponse{Success: false, Error: err.Error()}
|
return PutResponse{Success: false, Error: err.Error()}
|
||||||
|
|
|
@ -91,6 +91,7 @@ func (s *S3) Connect(endpoint string, params map[string]string) (*Client, error)
|
||||||
},
|
},
|
||||||
Timeout: timeout,
|
Timeout: timeout,
|
||||||
}
|
}
|
||||||
|
options.ClientLogMode = aws.LogResponseWithBody
|
||||||
})
|
})
|
||||||
|
|
||||||
// register metrics
|
// register metrics
|
||||||
|
|
Loading…
Reference in New Issue