breaking changes to google.golang.org/api/storage, androidpublisher

21 views
Skip to first unread message

Jonathan Amsterdam

unread,
Jul 10, 2017, 3:31:56 PM7/10/17
to google-api-...@googlegroups.com
This message is about changes to the generated clients under google.golang.org/api

Sometimes we learn that an API interprets a field's zero value differently than if the field is omitted entirely. We then change the field to a pointer, so we can use nil to represent "omitted".

We've just done that for three fields:
  • BucketLifecycleRuleCondition.IsLive in the storage client changed from bool to *bool.
  • CancelReason and PaymentState in the SubscriptionPurchase struct of the androidpublisher client. Both of these have changed from int64 to *int64.
The https://godoc.org/google.golang.org/api/googleapi package has helper functions Bool and Int64 for creating pointers to those types.

We normally recommend the storage client at cloud.google.com/go/storage over the one we've changed here--except that you can't use it for bucket lifecycle management yet. But that will change soon (CL pending).


Reply all
Reply to author
Forward
0 new messages