[ 
https://issues.apache.org/jira/browse/BEAM-7763?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17223979#comment-17223979
 ] 

Xinbin Huang edited comment on BEAM-7763 at 10/31/20, 4:11 AM:
---------------------------------------------------------------

My local_text_file is the beam README.md. I just tested again with 5 
publish_words  simultaneously, and I still didn't see anything related to 
0auth2. 

I took a look at the pubsub client, and I found that the current default 
transport instance is using gRPC protocol. I am not familiar with the 
difference between oauth2 and gRPC, does it have an influence on this? 
https://github.com/googleapis/python-pubsub/blob/c187245c98eef68f135442c6ba1f5dd2f47d591c/google/cloud/pubsub_v1/gapic/subscriber_client.py#L137-L144


was (Author: xbhuang):
My local_text_file is the beam README.md. I just tested again with 5 
publish_words  simultaneously, and I still didn't see anything related to 
0auth2. 

I took a look at the pubsub client, and I found that the current default 
transport instance is using gRPC protocol. I am not familiar with the 
difference between oauth2 and gRPC, but I suppose that it (gRPC) replaces 
oauth2. 
https://github.com/googleapis/python-pubsub/blob/c187245c98eef68f135442c6ba1f5dd2f47d591c/google/cloud/pubsub_v1/gapic/subscriber_client.py#L137-L144

> Python DirectRunner _PubSubReadEvaluator creates new client per bundle
> ----------------------------------------------------------------------
>
>                 Key: BEAM-7763
>                 URL: https://issues.apache.org/jira/browse/BEAM-7763
>             Project: Beam
>          Issue Type: Bug
>          Components: sdk-py-core
>            Reporter: Udi Meiri
>            Priority: P3
>              Labels: easy
>
> Lots of credential fetches.
> Similar to https://issues.apache.org/jira/browse/BEAM-2264
> but in this case the DirectRunner implementation seems to be creating a new 
> client for each bundle:
> https://github.com/apache/beam/blob/d5d7a7b7d0408d8435031e7bfce1abe2227115f5/sdks/python/apache_beam/runners/direct/transform_evaluator.py#L474
> From: 
> https://stackoverflow.com/questions/57010426/dataflow-access-to-pubsub-access-tokens



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to