MonitoredResourceUtil#getResource non-uniformly throws exceptions on missing/malformed values #512
Labels
api: logging
Issues related to the googleapis/java-logging API.
type: question
Request for information or clarification. Not an issue.
I use
MonitoredResourceUtil#getResource
to load resource in our log4j2 appender implementation (basically migrated logback implementation). Container in which application is running is missing some of the expected labels for "k8s_container" resource type, namely the zone is missing which leads togetCloudRunLocation
to throw NPE.Shouldn't
getResource
behave lenient against this kind of problems and try to initialize and work with as much data as possible? Especially considering that missing most of the labels will indeed not cause any issues - it's only some of them that lead to exceptions.The text was updated successfully, but these errors were encountered: