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

Update module github.com/aerospike/aerospike-client-go/v6 to v7 #30093

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Dec 19, 2023

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
github.com/aerospike/aerospike-client-go/v6 v6.13.0 -> v7.0.0 age adoption passing confidence

Release Notes

aerospike/aerospike-client-go (github.com/aerospike/aerospike-client-go/v6)

v7.0.0: Major Feature Release

Compare Source

[!CAUTION]
This is a breaking release. It is required to allow upgrading your programs to the Aerospike Server v7. This program upgrade process required as a prerequisite to upgrading your cluster, otherwise seemless cluster upgrade will not be possible. The changes and their rationale are documented in the following section.

  • Breaking Changes

    • [CLIENT-2713] Handle Normalized Integers in Maps and Lists.
      Aerospike Server v7 normalizes all positive integers in Maps and Lists into unsigned values for various efficiency reasons, and returns them as uint64. This effectively means that the type of positive int64 values will be lost. Go client supported uint64 types in lists and maps, and this change breaks that functionality by normalizing the values and removing the sign bits in case they are not needed. To support all versions of the server before and after the v7 consistently, the Go client will now behave like other Aerospike smart clients and automatically convert all unsigned int64 values inside maps and lists into signed values. This means a math.MaxUint64 value in a List or Map will return as two's compliment: -1.
      Example:

        client.Put(wpolicy, key, BinMap{"map": map[any]any{"max": uint64(math.MaxUint64), "typed": uint64(0)}})

      will return as:

        rec, err := client.Get(rpolicy, key)
        // rec.Bins will be:
        // BinMap{"map": map[any]any{"max": int64(-1), "typed": int64(0)}}

    This will break all code that used to cast rec.Bins["map"].(map[any]any)["max].(uin64). As a result, all such code should cast to int64 and then convert back to uint64 via a sign switch.
    If you didn't use uint64 values in Maps and Lists, you should not be affected by this change.
    All the test cases that depended on the old behavior have been adapted to the new behavior.

    • [CLIENT-2719] Typed GeoJSON and HLL deserialization.
      The Go client would read GeoJSON and HLL values back as string and []byte respectively. So if you read a record with bins of these types and wrote it directly back to the database, the type of these fields would be lost.
      The new version addresses this issue, but could be a breaking change if you have code that casts the values to the old string and []byte. You now need to cast these values to GeoJSONValue and HLLValue types respectively.

    • [CLIENT-2484] Add returnType to supported ExpMapRemoveBy* and ExpListRemoveBy* methods.

    • [CLIENT-2319] Revise BatchReadAPIs to accept BatchReadPolicy argument. NewBatchReadOps no longer takes binNames and changes ops parameter to variadic for consistency.

      Changes the following Public API:

        func NewBatchRead(key *Key, binNames []string) *BatchRead {
        func NewBatchReadOps(key *Key, binNames []string, ops []*Operation) *BatchRead {
        func NewBatchReadHeader(key *Key) *BatchRead {

      to

        func NewBatchRead(policy *BatchReadPolicy, key *Key, binNames []string) *BatchRead {
        func NewBatchReadOps(policy *BatchReadPolicy, key *Key, ops ...*Operation) *BatchRead {
        func NewBatchReadHeader(policy *BatchReadPolicy, key *Key) *BatchRead {
    • Replace WritePolicy with InfoPolicy in client.Truncate.

    • Remove the deprecated ClientPolicy.RackId. Use Policy.RackIds instead.

  • New Features

    • [CLIENT-2712] [CLIENT-2710] Support read replica policy in scan/query.
      This includes PREFER_RACK which allows scan/query to be directed at local rack nodes when possible.
    • [CLIENT-2434] Use 'sindex-exists' command in DropIndexTask.
    • [CLIENT-2573] Support ExpRecordSize().
    • [CLIENT-2588] SINDEX Support for 'Blob' Type Elements.
  • Improvements

    • [CLIENT-2694] Use RawURLEncoding instead of RawStdEncoding in proxy authenticator.
    • [CLIENT-2616] Update dependencies to the latest, require Go 1.21
    • Remove HyperLogLog tests from the Github Actions suite
    • Remove Go v1.18-v1.20 from the Github Actions Matrix
    • Rename grpc proto definition files due to compiler limitations. Resolves #​414
  • Fixes

    • [CLIENT-2318] Fixes an issue where Expression in BatchPolicy takes precedence rather than BatchDeletePolicy in BatchDelete.

v6.14.1

Compare Source

Hotfix.

  • Fixes

    • [CLIENT-2624] BatchGetOperate triggering SIGSEGV nil pointer in the Go client.
      Caching of the operation is faulty and causes race conditions when used concurrently.
      This commit removes the caching which included a useless allocation and rarely, if ever, had any practical influence on performance.

v6.14.0

Compare Source

  • New Features

    • Adds support for the AerospikeProxy and DBAAS service.

Configuration

📅 Schedule: Branch creation - "on tuesday" (UTC), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate. View repository job log here.

@renovate renovate bot requested a review from djaglowski as a code owner December 19, 2023 15:19
@renovate renovate bot requested a review from a team December 19, 2023 15:19
@renovate renovate bot added dependencies Pull requests that update a dependency file renovatebot labels Dec 19, 2023
@TylerHelmuth
Copy link
Member

pinging @djaglowski @antonblock as code owners

@antonblock
Copy link
Contributor

This looks like the same issue in #29810 based on the failures, I'll take a look at this one

@antonblock
Copy link
Contributor

@TylerHelmuth I think we'll be unable to upgrade the aerospike package until we support Go 1.21. The root cause is conflicting proto names were introduced in v6.14.0, which we first hit here: #26265

It looks like that issue was fixed, but is only available in the major 7.0 release. That release also make Go 1.21 a requirement, which I think we can't require yet. I can comment on the original issue to see if the fix might be backported for v6.

This is the error from the e2e tests:

2023-12-19T19:56:36.855510338Z stderr F panic: proto: file "kv.proto" has a name conflict over DEFAULT
2023-12-19T19:56:36.857152379Z stderr F 	previously from: "github.com/checkpoint-restore/go-criu/v5/rpc"
2023-12-19T19:56:36.857169296Z stderr F 	currently from:  "github.com/aerospike/aerospike-client-go/v6/proto/kvs"
2023-12-19T19:56:36.857176796Z stderr F See https://protobuf.dev/reference/go/faq#namespace-conflict
2023-12-19T19:56:36.857183296Z stderr F
2023-12-19T19:56:36.857190171Z stderr F
2023-12-19T19:56:36.862113004Z stderr F goroutine 1 [running]:
2023-12-19T19:56:36.862874046Z stderr F google.golang.org/protobuf/reflect/protoregistry.glob..func1({0x8ffba00?, 0xc0026e4c50?}, {0x8ffba00?, 0xc0026e4c90})
2023-12-19T19:56:36.862889213Z stderr F 	google.golang.org/protobuf@v1.31.0/reflect/protoregistry/registry.go:56 +0x1e5
2023-12-19T19:56:36.862893629Z stderr F google.golang.org/protobuf/reflect/protoregistry.(*Files).RegisterFile.func1({0x90adcc0, 0xc001d2de00})
2023-12-19T19:56:36.862897463Z stderr F 	google.golang.org/protobuf@v1.31.0/reflect/protoregistry/registry.go:154 +0x263
2023-12-19T19:56:36.862900921Z stderr F google.golang.org/protobuf/reflect/protoregistry.rangeTopLevelDescriptors({0x90cf790, 0xc00277e1c0}, 0xc00257f970)
2023-12-19T19:56:36.862904171Z stderr F 	google.golang.org/protobuf@v1.31.0/reflect/protoregistry/registry.go:412 +0x2ce
2023-12-19T19:56:36.862907546Z stderr F google.golang.org/protobuf/reflect/protoregistry.(*Files).RegisterFile(0xc000010678, {0x90cf790?, 0xc00277e1c0?})
2023-12-19T19:56:36.862910754Z stderr F 	google.golang.org/protobuf@v1.31.0/reflect/protoregistry/registry.go:149 +0x73e
2023-12-19T19:56:36.862958421Z stderr F google.golang.org/protobuf/internal/filedesc.Builder.Build({{0x6746316, 0x35}, {0xe057160, 0x20ac, 0x20ac}, 0x9, 0x13, 0x0, 0x4, {0x902f808, ...}, ...})
2023-12-19T19:56:36.862964463Z stderr F 	google.golang.org/protobuf@v1.31.0/internal/filedesc/build.go:112 +0x1d6
2023-12-19T19:56:36.862967713Z stderr F google.golang.org/protobuf/internal/filetype.Builder.Build({{{0x6746316, 0x35}, {0xe057160, 0x20ac, 0x20ac}, 0x9, 0x13, 0x0, 0x4, {0x0, ...}, ...}, ...})
2023-12-19T19:56:36.862971421Z stderr F 	google.golang.org/protobuf@v1.31.0/internal/filetype/build.go:138 +0x199
2023-12-19T19:56:36.862979421Z stderr F github.com/aerospike/aerospike-client-go/v6/proto/kvs.file_kv_proto_init()
2023-12-19T19:56:36.862983546Z stderr F 	github.com/aerospike/aerospike-client-go/v6@v6.14.1/proto/kvs/kv.pb.go:3361 +0x518
2023-12-19T19:56:36.862987254Z stderr F github.com/aerospike/aerospike-client-go/v6/proto/kvs.init.0()
2023-12-19T19:56:36.863490463Z stderr F 	github.com/aerospike/aerospike-client-go/v6@v6.14.1/proto/kvs/kv.pb.go:3099 +0xf

@TylerHelmuth
Copy link
Member

@antonblock thank you for investigating!

@TylerHelmuth
Copy link
Member

Blocked for now #30101

Copy link
Contributor Author

renovate bot commented Dec 19, 2023

Renovate Ignore Notification

Because you closed this PR without merging, Renovate will ignore this update. You will not get PRs for any future 7.x releases. But if you manually upgrade to 7.x then Renovate will re-enable minor and patch updates automatically.

If you accidentally closed this PR, or if you changed your mind: rename this PR to get a fresh replacement PR.

@renovate renovate bot deleted the renovate/gh.neting.cc-aerospike-aerospike-client-go-v6-7.x branch December 19, 2023 21:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file dependency issue receiver/aerospike
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants