googleapis / googleapis/google-cloud-java

[java-logging] Improve the Write logEntry sample

未关闭
#11,923 0 条评论 0 个 reaction 已指派 1 人 已被 @arbrown 认领 在 GitHub 查看
api: logging good first issue lang: java priority: p3 samples type: feature request
主要语言
Java
星标
2.1k
派生
1.2k
平均合并
1 天 23 小时
30 天内合并 PR
154

描述

Improve the Write logEntry sample on [this page](https://cloud.google.com/logging/docs/samples/logging-write-log-entry)

This page is referenced by [docs](https://cloud.google.com/logging/docs/api/tasks/creating-logs) that explicitly talk about LogEntries. So we should demo this “advanced” logging technique, even though we do recommend the standard log wrapper approach in the quickstarts.

Criteria:
- [ ] Demo how to write a text logEntry (textPayload)
- [ ] Demo how to write a struct logEntry (jsonPayload)
- [ ] Include: severity level, labels, resource type (“global”)
- [ ] Demo: batch logging vs writing one log at a time
- [ ] Update accompanying tests

Region tag: `logging_write_log_entry`

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。