René's URL Explorer Experiment


Title: Use metadata server to detect GKE environment by liyanhui1228 · Pull Request #3856 · googleapis/google-cloud-python · GitHub

Open Graph Title: Use metadata server to detect GKE environment by liyanhui1228 · Pull Request #3856 · googleapis/google-cloud-python

X Title: Use metadata server to detect GKE environment by liyanhui1228 · Pull Request #3856 · googleapis/google-cloud-python

Description: Google Cloud Client Libraries for Python. Contribute to googleapis/google-cloud-python development by creating an account on GitHub.

Open Graph Description: For #3622. This fixes the get_default_handler() method to let it return the ContainerEngineHandler when in GKE environment using the cluster_name attribute from the metadata server. If this attribu...

X Description: For #3622. This fixes the get_default_handler() method to let it return the ContainerEngineHandler when in GKE environment using the cluster_name attribute from the metadata server. If this attribu...

Opengraph URL: https://github.com/googleapis/google-cloud-python/pull/3856

X: @github

direct link

Domain: github.com

route-pattern/_view_fragments/voltron/pull_requests/show/:user_id/:repository/:id/pull_request_layout(.:format)
route-controllervoltron_pull_requests_fragments
route-actionpull_request_layout
fetch-noncev2:610028cd-a281-0689-e9d7-4bbbe172579a
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id9E9A:1ECB:2693490:35ACD6D:6A5029AF
html-safe-nonce997afd2188afcf16c3c3e49f530e9f716a9174e49fcfaaffce9b1124cd837fa7
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5RTlBOjFFQ0I6MjY5MzQ5MDozNUFDRDZEOjZBNTAyOUFGIiwidmlzaXRvcl9pZCI6IjMwODA4MDc3MjQyNjg2NjExNjciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac222fe5cbc1dcf60785e4259bbbe7d84219cef3ff3f8446aedb7c7f1751b6e6cb
hovercard-subject-tagpull_request:137112370
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/pull_requests_fragments/pull_request_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/voltron/pull_requests/show/googleapis/google-cloud-python/3856/pull_request_layout
twitter:imagehttps://opengraph.githubassets.com/300592a96ea1a290f82b073db16f1705aa2d88bc8fdfdfb710be464411253a85/googleapis/google-cloud-python/pull/3856
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/300592a96ea1a290f82b073db16f1705aa2d88bc8fdfdfb710be464411253a85/googleapis/google-cloud-python/pull/3856
og:image:altFor #3622. This fixes the get_default_handler() method to let it return the ContainerEngineHandler when in GKE environment using the cluster_name attribute from the metadata server. If this attribu...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameliyanhui1228
hostnamegithub.com
expected-hostnamegithub.com
Noned6dc8294eb500fa36bbc57472d61fe87c522f9c3c1d64f70f4926f66a66a7efb
turbo-cache-controlno-cache
go-importgithub.com/googleapis/google-cloud-python git https://github.com/googleapis/google-cloud-python.git
octolytics-dimension-user_id16785467
octolytics-dimension-user_logingoogleapis
octolytics-dimension-repository_id16316451
octolytics-dimension-repository_nwogoogleapis/google-cloud-python
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id16316451
octolytics-dimension-repository_network_root_nwogoogleapis/google-cloud-python
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
released90666eaf032b7eb8975a378efe38e37f4ebb96c
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/googleapis/google-cloud-python/pull/3856#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fpull%2F3856
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fpull%2F3856
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fpull_requests_fragments%2Fpull_request_layout&source=header-repo&source_repo=googleapis%2Fgoogle-cloud-python
Reloadhttps://github.com/googleapis/google-cloud-python/pull/3856
Reloadhttps://github.com/googleapis/google-cloud-python/pull/3856
Reloadhttps://github.com/googleapis/google-cloud-python/pull/3856
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
googleapis https://github.com/googleapis
google-cloud-pythonhttps://github.com/googleapis/google-cloud-python
Notifications https://github.com/login?return_to=%2Fgoogleapis%2Fgoogle-cloud-python
Fork 1.7k https://github.com/login?return_to=%2Fgoogleapis%2Fgoogle-cloud-python
Star 5.3k https://github.com/login?return_to=%2Fgoogleapis%2Fgoogle-cloud-python
Code https://github.com/googleapis/google-cloud-python
Issues 444 https://github.com/googleapis/google-cloud-python/issues
Pull requests 137 https://github.com/googleapis/google-cloud-python/pulls
Discussions https://github.com/googleapis/google-cloud-python/discussions
Actions https://github.com/googleapis/google-cloud-python/actions
Projects https://github.com/googleapis/google-cloud-python/projects
Security and quality 0 https://github.com/googleapis/google-cloud-python/security
Insights https://github.com/googleapis/google-cloud-python/pulse
Code https://github.com/googleapis/google-cloud-python
Issues https://github.com/googleapis/google-cloud-python/issues
Pull requests https://github.com/googleapis/google-cloud-python/pulls
Discussions https://github.com/googleapis/google-cloud-python/discussions
Actions https://github.com/googleapis/google-cloud-python/actions
Projects https://github.com/googleapis/google-cloud-python/projects
Security and quality https://github.com/googleapis/google-cloud-python/security
Insights https://github.com/googleapis/google-cloud-python/pulse
theacodeshttps://github.com/theacodes
googleapis:masterhttps://github.com/googleapis/google-cloud-python/tree/master
liyanhui1228:gke-logginghttps://github.com/liyanhui1228/google-cloud-python/tree/gke-logging
Conversationhttps://github.com/googleapis/google-cloud-python/pull/3856
Commits6 (6)https://github.com/googleapis/google-cloud-python/pull/3856/commits
Checkshttps://github.com/googleapis/google-cloud-python/pull/3856/checks
Files changedhttps://github.com/googleapis/google-cloud-python/pull/3856/files
Use metadata server to detect GKE environmenthttps://github.com/googleapis/google-cloud-python/pull/3856#top
theacodeshttps://github.com/theacodes
googleapis:masterhttps://github.com/googleapis/google-cloud-python/tree/master
liyanhui1228:gke-logginghttps://github.com/liyanhui1228/google-cloud-python/tree/gke-logging
https://github.com/liyanhui1228
liyanhui1228https://github.com/liyanhui1228
Aug 23, 2017https://github.com/googleapis/google-cloud-python/pull/3856#issue-252133218
#3622https://github.com/googleapis/google-cloud-python/issues/3622
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
https://github.com/liyanhui1228
Use metadata server to detect GKE environmenthttps://github.com/googleapis/google-cloud-python/pull/3856/commits/7c3a4e7e528bcc39b622496415b4c5d039bc20d3
7c3a4e7https://github.com/googleapis/google-cloud-python/pull/3856/commits/7c3a4e7e528bcc39b622496415b4c5d039bc20d3
https://github.com/liyanhui1228
liyanhui1228https://github.com/liyanhui1228
api: logging https://github.com/googleapis/google-cloud-python/issues?q=state%3Aopen%20label%3A%22api%3A%20logging%22
Aug 23, 2017https://github.com/googleapis/google-cloud-python/pull/3856#event-1216981815
https://github.com/liyanhui1228
liyanhui1228https://github.com/liyanhui1228
dhermeshttps://github.com/dhermes
duggelzhttps://github.com/duggelz
lukesneeringerhttps://github.com/lukesneeringer
theacodeshttps://github.com/theacodes
August 23, 2017 01:24https://github.com/googleapis/google-cloud-python/pull/3856#event-1216981816
https://github.com/googlebot
googlebothttps://github.com/googlebot
cla: yes https://github.com/googleapis/google-cloud-python/issues?q=state%3Aopen%20label%3A%22cla%3A%20yes%22
Aug 23, 2017https://github.com/googleapis/google-cloud-python/pull/3856#event-1216981865
https://github.com/lukesneeringer
lukesneeringerhttps://github.com/lukesneeringer
Aug 23, 2017 https://github.com/googleapis/google-cloud-python/pull/3856#pullrequestreview-57967110
View reviewed changes https://github.com/googleapis/google-cloud-python/pull/3856/files/7c3a4e7e528bcc39b622496415b4c5d039bc20d3
https://github.com/theacodes
theacodeshttps://github.com/theacodes
Aug 23, 2017 https://github.com/googleapis/google-cloud-python/pull/3856#pullrequestreview-58135260
View reviewed changes https://github.com/googleapis/google-cloud-python/pull/3856/files/7c3a4e7e528bcc39b622496415b4c5d039bc20d3
logging/google/cloud/logging/_helpers.pyhttps://github.com/googleapis/google-cloud-python/pull/3856/files/7c3a4e7e528bcc39b622496415b4c5d039bc20d3#diff-1b8b551427876e50d2b08eef082eb8dd775ae1194f2a82527a76b1781c6dfa70
Sign in to viewhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fpull%2F3856
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
Sign in to viewhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fpull%2F3856
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
Sign in to viewhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fpull%2F3856
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
liyanhui1228https://github.com/liyanhui1228
August 23, 2017 12:24https://github.com/googleapis/google-cloud-python/pull/3856#commits-pushed-70a4ffb
https://github.com/liyanhui1228
Use raise_for_status to throw exception when request failedhttps://github.com/googleapis/google-cloud-python/pull/3856/commits/70a4ffbd9d3eb2617b86df51445500660fdd203d
70a4ffbhttps://github.com/googleapis/google-cloud-python/pull/3856/commits/70a4ffbd9d3eb2617b86df51445500660fdd203d
https://github.com/liyanhui1228
Only return response when status_code is 200https://github.com/googleapis/google-cloud-python/pull/3856/commits/dacba18dd88d7df3e47becaa08d282c23f125367
dacba18https://github.com/googleapis/google-cloud-python/pull/3856/commits/dacba18dd88d7df3e47becaa08d282c23f125367
https://github.com/liyanhui1228
Fix stuffhttps://github.com/googleapis/google-cloud-python/pull/3856/commits/67a48dcdc19d6a3a285bd69c0e696a8beb8c53c8
67a48dchttps://github.com/googleapis/google-cloud-python/pull/3856/commits/67a48dcdc19d6a3a285bd69c0e696a8beb8c53c8
https://github.com/liyanhui1228
Remove unused commentshttps://github.com/googleapis/google-cloud-python/pull/3856/commits/b79d6b945f7f0bf8eeb6c9d9b838355a74bf5dca
b79d6b9https://github.com/googleapis/google-cloud-python/pull/3856/commits/b79d6b945f7f0bf8eeb6c9d9b838355a74bf5dca
https://github.com/duggelz
duggelzhttps://github.com/duggelz
Aug 23, 2017 https://github.com/googleapis/google-cloud-python/pull/3856#pullrequestreview-58216903
View reviewed changes https://github.com/googleapis/google-cloud-python/pull/3856/files/b79d6b945f7f0bf8eeb6c9d9b838355a74bf5dca
logging/google/cloud/logging/_helpers.pyhttps://github.com/googleapis/google-cloud-python/pull/3856/files/b79d6b945f7f0bf8eeb6c9d9b838355a74bf5dca#diff-1b8b551427876e50d2b08eef082eb8dd775ae1194f2a82527a76b1781c6dfa70
Sign in to viewhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fpull%2F3856
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
Sign in to viewhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fpull%2F3856
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
logging/tests/unit/test__helpers.pyhttps://github.com/googleapis/google-cloud-python/pull/3856/files/b79d6b945f7f0bf8eeb6c9d9b838355a74bf5dca#diff-bdea4e59b5fb4ea87460e87275e171c4f6add590b22945f11dc07cf04ec526ed
Sign in to viewhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fpull%2F3856
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
Sign in to viewhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fpull%2F3856
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
https://github.com/liyanhui1228
Address commentshttps://github.com/googleapis/google-cloud-python/pull/3856/commits/2b430721b4fdfbe2a5a12167e97d4837beab13be
2b43072https://github.com/googleapis/google-cloud-python/pull/3856/commits/2b430721b4fdfbe2a5a12167e97d4837beab13be
https://github.com/duggelz
duggelzhttps://github.com/duggelz
Aug 23, 2017 https://github.com/googleapis/google-cloud-python/pull/3856#pullrequestreview-58225179
View reviewed changes https://github.com/googleapis/google-cloud-python/pull/3856/files/2b430721b4fdfbe2a5a12167e97d4837beab13be
https://github.com/liyanhui1228
liyanhui1228https://github.com/liyanhui1228
Aug 23, 2017https://github.com/googleapis/google-cloud-python/pull/3856#issuecomment-324472886
@dhermeshttps://github.com/dhermes
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
https://github.com/theacodes
theacodeshttps://github.com/theacodes
Aug 23, 2017 https://github.com/googleapis/google-cloud-python/pull/3856#pullrequestreview-58227565
View reviewed changes https://github.com/googleapis/google-cloud-python/pull/3856/files/2b430721b4fdfbe2a5a12167e97d4837beab13be
https://github.com/theacodes
theacodeshttps://github.com/theacodes
Aug 23, 2017https://github.com/googleapis/google-cloud-python/pull/3856#issuecomment-324473832
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
https://github.com/theacodes
theacodeshttps://github.com/theacodes
0dd7249https://github.com/googleapis/google-cloud-python/commit/0dd7249fb5224b721aaa432965aa9ed3df4c5287
Aug 23, 2017https://github.com/googleapis/google-cloud-python/pull/3856#event-1218734424
https://github.com/dhermes
dhermeshttps://github.com/dhermes
Aug 23, 2017https://github.com/googleapis/google-cloud-python/pull/3856#issuecomment-324486068
@jonparrotthttps://github.com/jonparrott
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
https://github.com/dhermes
dhermeshttps://github.com/dhermes
Aug 24, 2017 https://github.com/googleapis/google-cloud-python/pull/3856#ref-pullrequest-252727891
Updating 10 packages after google-cloud-core==0.27.0 #3866 https://github.com/googleapis/google-cloud-python/pull/3866
partheahttps://github.com/parthea
Nov 24, 2025 https://github.com/googleapis/google-cloud-python/pull/3856#ref-commit-bfd9442
https://github.com/liyanhui1228
Logging: Use metadata server to detect GKE environment (https://github.com/googleapis/google-cloud-python/commit/bfd9442099a3168c349a0d269e78839c23d224e3
#3856https://github.com/googleapis/google-cloud-python/pull/3856
)https://github.com/googleapis/google-cloud-python/commit/bfd9442099a3168c349a0d269e78839c23d224e3
bfd9442https://github.com/googleapis/google-cloud-python/commit/bfd9442099a3168c349a0d269e78839c23d224e3
https://github.co/hiddenchars
https://github.com/googleapis/google-cloud-python/pull/{{ revealButtonHref }}
Sign up for freehttps://github.com/join?source=comment-repo
Sign in to commenthttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgoogleapis%2Fgoogle-cloud-python%2Fpull%2F3856
https://github.com/dhermes
dhermes https://github.com/dhermes
https://github.com/lukesneeringer
lukesneeringer https://github.com/lukesneeringer
https://github.com/googleapis/google-cloud-python/pull/3856/files/7c3a4e7e528bcc39b622496415b4c5d039bc20d3
https://github.com/theacodes
theacodes https://github.com/theacodes
https://github.com/googleapis/google-cloud-python/pull/3856/files/2b430721b4fdfbe2a5a12167e97d4837beab13be
https://github.com/duggelz
duggelz https://github.com/duggelz
https://github.com/googleapis/google-cloud-python/pull/3856/files/2b430721b4fdfbe2a5a12167e97d4837beab13be
api: logging https://github.com/googleapis/google-cloud-python/issues?q=state%3Aopen%20label%3A%22api%3A%20logging%22
cla: yes https://github.com/googleapis/google-cloud-python/issues?q=state%3Aopen%20label%3A%22cla%3A%20yes%22
Please reload this pagehttps://github.com/googleapis/google-cloud-python/pull/3856
https://github.com/liyanhui1228
https://github.com/theacodes
https://github.com/dhermes
https://github.com/lukesneeringer
https://github.com/duggelz
https://github.com/googlebot
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.