Skip to content

Conversation

@tseaver
Copy link
Contributor

@tseaver tseaver commented Mar 28, 2016

Fetched entries expose labels set on the back-end.

When logging, labels can be passed in explicitly to the log_text, log_struct, or log_proto methods. If not passed, any default values configured on the logger instance will be used.

See: #1566.

@tseaver tseaver added the api: logging Issues related to the Cloud Logging API. label Mar 28, 2016
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Mar 28, 2016
tseaver added 3 commits March 28, 2016 13:55
Labels can be passed in explicitly to the 'log_text', 'log_struct', or
'log_proto' methods.  If not passed, any default values configured on
the logger instance will be used.

See: #1566.

labels = self._get_labels(labels)
if labels is not None:
data['entries'][0]['labels'] = labels

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

return Batch(self, client)

def log_text(self, text, client=None):
def _make_entry_resource(self, text=None, info=None, message=None,

This comment was marked as spam.

This comment was marked as spam.

@dhermes
Copy link
Contributor

dhermes commented Mar 28, 2016

LGTM. 7 commits seems like a lot?

@tseaver
Copy link
Contributor Author

tseaver commented Mar 28, 2016

7 commits seems like a lot?

Two of the commits are bugfixes for already-merged-to-logging-api code. :(

@dhermes
Copy link
Contributor

dhermes commented Mar 28, 2016

You can do with the commits as you see fit. You are go to merge on my end.

@tseaver tseaver merged commit f1b9261 into googleapis:logging-api Mar 28, 2016
@tseaver tseaver deleted the logging-support_entry_labels branch March 28, 2016 19:41
@tseaver
Copy link
Contributor Author

tseaver commented Mar 28, 2016

I merged as-is after aborting a rebase where I tried to clean it up.

parthea pushed a commit that referenced this pull request Nov 24, 2025
* fix: mock return_value should not populate oneof message fields
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: logging Issues related to the Cloud Logging API. cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants