Skip to content

Commit eabbb78

Browse files
authored
Doc: Suggest customers to not use this library if on cloud environments (#1434)
1 parent 2d83b87 commit eabbb78

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,11 @@ Note that using the structured logging Json format you cannot control the log na
186186
The logs will be ingested into the project that hosts the environment where your application is running.
187187
The configuration `logDestinationProjectId` will be ignored.
188188

189-
189+
### Recommended way to ingest logs in Google Cloud managed environments
190+
If your application is running on Google Cloud Environments such as Google Kubernetes Engine, App Engine flexible environment, and Cloud Run functions, it is recommended to use [logging agent](https://cloud.google.com/logging/docs/agent)
191+
to send application logs to Cloud Logging. Logging agents send data written to a file, such as `stdout` or a file, as logs to Cloud Logging. Using logging agents and relying on logging files such as `stdout` and `stderr` will
192+
ensure that application crashes don't break sending logs to your project. It will also reduce complex coding to explicitly handle buffering and retries using client libraries. For a detailed comparison of logging agents and
193+
client libraries, see [Choosing an agent or client libraries](https://cloud.google.com/logging/docs/agent-or-library#choosing).
190194

191195

192196
## Samples

0 commit comments

Comments
 (0)