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 }}
This repository was archived by the owner on Feb 6, 2026. It is now read-only.
Specify the API at the beginning of the title. For example, "BigQuery: ...").
General, Core, and Other are also allowed as types
OS type and version:
Java version: 11
logging version(s): 2.3.1
Steps to reproduce
Deploy to Cloud Run
See error: java.lang.RuntimeException: java.util.concurrent.ExecutionException: com.google.cloud.logging.LoggingException: io.grpc.StatusRuntimeException: PERMISSION_DENIED: The caller does not have permission
Code example
Call MonitoredResourceUtil.getResource() directly or through using LoggingHandler.addHandler(LOGGER, new LoggingHandler()); for example with java.util.logging.Logger.
privatefinalstaticLoggerLOGGER = Logger.getLogger("HelloWorldApplication");
LoggingHandler.addHandler(LOGGER, newLoggingHandler());
LOGGER.log(newLogRecord(Level.FINEST, "my message!"));
Stack trace
java.lang.RuntimeException: java.util.concurrent.ExecutionException: com.google.cloud.logging.LoggingException: io.grpc.StatusRuntimeException: PERMISSION_DENIED: The caller does not have permission
at com.google.cloud.logging.LoggingImpl.flush(LoggingImpl.java:717)
at com.google.cloud.logging.LoggingImpl.write(LoggingImpl.java:699)
at com.google.cloud.logging.LoggingHandler.publish(LoggingHandler.java:237)
at java.logging/java.util.logging.Logger.log(Unknown Source)
at com.example.helloworld.HelloworldApplication$HelloworldController.hello(HelloworldApplication.java:59)
The docs need to be updated to mention that the service account of the Google Cloud service (for example Cloud Run) needs to be updated to have role Logs Writer,roles/logging.logWriter.
Environment details
General, Core, and Other are also allowed as types
Steps to reproduce
java.lang.RuntimeException: java.util.concurrent.ExecutionException: com.google.cloud.logging.LoggingException: io.grpc.StatusRuntimeException: PERMISSION_DENIED: The caller does not have permissionCode example
Call MonitoredResourceUtil.getResource() directly or through using LoggingHandler.addHandler(LOGGER, new LoggingHandler()); for example with java.util.logging.Logger.
Stack trace
The docs need to be updated to mention that the service account of the Google Cloud service (for example Cloud Run) needs to be updated to have role
Logs Writer,roles/logging.logWriter.