pabloem commented on a change in pull request #14767:
URL: https://github.com/apache/beam/pull/14767#discussion_r630506263
##########
File path: sdks/python/apache_beam/io/gcp/pubsub.py
##########
@@ -294,6 +327,9 @@ def message_to_proto_str(element):
raise TypeError(
'Unexpected element. Type: %s (expected: PubsubMessage), '
'value: %r' % (type(element), element))
+ # message_id and publish_time cannot be written back to pubsub
Review comment:
makes sense. thanks! Can you link that URL in your comment?
Also, just to be safe, I think it will be better to copy rather than mutate.
Beam often fuses different ptransforms, and executes them in the same worker.
Another option is to change `_to_proto_str` to accept an argument about whether
to include the extra attributes. WDYT about that?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]