abelana
abelana copied to clipboard
update Google Cloud API client import paths and more
The Google Cloud API client libraries for Go are making some breaking changes:
- The import paths are changing from
google.golang.org/cloud/...
tocloud.google.com/go/...
. For example, if your code imports the BigQuery client it currently readsimport "google.golang.org/cloud/bigquery"
It should be changed toimport "cloud.google.com/go/bigquery"
- Client options are also moving, from
google.golang.org/cloud
togoogle.golang.org/api/option
. Two have also been renamed:-
WithBaseGRPC
is nowWithGRPCConn
-
WithBaseHTTP
is nowWithHTTPClient
-
- The
cloud.WithContext
andcloud.NewContext
methods are gone, as are the deprecated pubsub and container functions that required them. Use theClient
methods of these packages instead.
You should make these changes before September 12, 2016, when the packages at
google.golang.org/cloud
will go away.