Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set gRPC message options and keepalive. #4269

Merged
merged 12 commits into from
Oct 30, 2017

Conversation

lukesneeringer
Copy link
Contributor

@lukesneeringer lukesneeringer commented Oct 26, 2017

Fixes #4083, although the UNAVAILABLE errors still occur sometimes for other reasons.

That will need to be handled with new retry logic, and is being tracked as #4234.

Addendum: Fixes #3886.

@lukesneeringer lukesneeringer self-assigned this Oct 26, 2017
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Oct 26, 2017
@lukesneeringer
Copy link
Contributor Author

Ignore the long list of commits that included #4265; squash will fix it. :-)

Copy link
Contributor

@dhermes dhermes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but I'd love it if you addressed my nits 😀

target = '{host}:{port}'.format(
host=subscriber_client.SubscriberClient.SERVICE_ADDRESS,
port=subscriber_client.SubscriberClient.DEFAULT_SERVICE_PORT,
)

This comment was marked as spam.

'grpc.max_send_message_length': -1,
'grpc.max_receive_message_length': -1,
'grpc.keepalive_time_ms': 30000,
}.items(),

This comment was marked as spam.

host=subscriber_client.SubscriberClient.SERVICE_ADDRESS,
port=subscriber_client.SubscriberClient.DEFAULT_SERVICE_PORT,
)
kwargs.setdefault('channel', grpc_helpers.create_channel(

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

import grpc

from google import auth
from google.api_core import grpc_helpers

This comment was marked as spam.

host=subscriber_client.SubscriberClient.SERVICE_ADDRESS,
port=subscriber_client.SubscriberClient.DEFAULT_SERVICE_PORT,
)
kwargs.setdefault('channel', grpc_helpers.create_channel(

This comment was marked as spam.

@lukesneeringer lukesneeringer merged commit 743ade4 into googleapis:master Oct 30, 2017
@lukesneeringer lukesneeringer deleted the custom-channel branch October 30, 2017 15:51
@@ -66,6 +91,18 @@ def __init__(self, batch_settings=(), batch_class=thread.Batch, **kwargs):
self._batch_lock = threading.Lock()
self._batches = {}

@property
def target(self):

This comment was marked as spam.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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