You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add more useful header info on HTTP requests #3006
Seems like we could override the USER_AGENT class attribute for the APIs which use JSONConnection, and derive it from pkg_resources (maybe add a helper for that?). E.g.:
It is actually moving to a new header, X-Goog-API-Client, and the client library is going to be abbreviated gccl (google cloud client library).
We also intend to track the language via gl-python/{v}, which should appear at the beginning of the string. GAX already does this, but the HTTP base client will need to add it, too.
We probably still need to set a User-Agent string (just because it is considered good practice), and it does not matter what it is. google-cloud-core/{v} seems appropriate for that but I will defer to whatever you folks want (provided it is sane).
Activity
tseaver commentedon Feb 13, 2017
Seems like we could override the
USER_AGENTclass attribute for the APIs which useJSONConnection, and derive it frompkg_resources(maybe add a helper for that?). E.g.:I don't know whether the
-pythonsuffix should be there. @lukesneeringer can you confirm?lukesneeringer commentedon Feb 13, 2017
It is actually moving to a new header,
X-Goog-API-Client, and the client library is going to be abbreviatedgccl(google cloud client library).We also intend to track the language via
gl-python/{v}, which should appear at the beginning of the string. GAX already does this, but the HTTP base client will need to add it, too.We probably still need to set a User-Agent string (just because it is considered good practice), and it does not matter what it is.
google-cloud-core/{v}seems appropriate for that but I will defer to whatever you folks want (provided it is sane).dhermes commentedon Feb 13, 2017
@lukesneeringer The value of
gcloud-pythonused to be deemed "sacred" to preserve some reporting internal to Google. That may no longer be true.lukesneeringer commentedon Feb 13, 2017
This is no longer true. The new header is superceding the old one.
dhermes commentedon Feb 17, 2017
#3035 is most of the "
intellectualconceptual way" towards thisdhermes commentedon Feb 21, 2017
Remaining APIs:
bigquerydatastorednserror_reportinglanguageloggingmonitoringpubsubresource_managerruntimeconfigspeechstoragetranslatevision