Skip to content

Commit

Permalink
Query all secure bundles for Astra token
Browse files Browse the repository at this point in the history
  • Loading branch information
lukasz-antoniak committed Jul 17, 2024
1 parent f23bf75 commit 85024c2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion astra/bundle.go
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,11 @@ func generateSecureBundleURLWithResponse(url, databaseID, token string, ctx cont
if err != nil {
return nil, err
}
res, err := client.GenerateSecureBundleURLWithResponse(ctx, databaseID, &astra.GenerateSecureBundleURLParams{})
// return all bundles, as returning only one causes issue with response deserializing
// client code generated by Go from Swagger definition does not support 'oneOf' clause
// (https://github.com/oapi-codegen/oapi-codegen/issues/1665)
returnAllBundles := true
res, err := client.GenerateSecureBundleURLWithResponse(ctx, databaseID, &astra.GenerateSecureBundleURLParams{All: &returnAllBundles})
if err != nil {
return nil, fmt.Errorf("error generating bundle urls: %v", err)
}
Expand Down

0 comments on commit 85024c2

Please sign in to comment.