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
Schemaregistrytimeoutoption #906
Schemaregistrytimeoutoption #906
Conversation
It looks like @petebids hasn't signed our Contributor License Agreement, yet.
You can read and sign our full Contributor License Agreement here. Once you've signed reply with Appreciation of efforts, clabot |
[clabot:check]
…On Wed, Jul 1, 2020 at 8:44 PM Confluent CLA Bot ***@***.***> wrote:
It looks like @petebids <https://github.com/petebids> hasn't signed our
*C*ontributor *L*icense *A*greement, yet.
The purpose of a CLA is to ensure that the guardian of a project's outputs
has the necessary ownership or grants of rights over all contributions to
allow them to distribute under the chosen licence.
Wikipedia <http://en.wikipedia.org/wiki/Contributor_License_Agreement>
You can read and sign our full Contributor License Agreement here
<http://clabot.confluent.io/cla>.
Once you've signed reply with [clabot:check] to prove it.
Appreciation of efforts,
clabot
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#906 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AMTSVGWZJQYXGRH7GCCOQEDRZMHP3ANCNFSM4ONJA33Q>
.
|
@confluentinc It looks like @petebids just signed our Contributor License Agreement. 👍 Always at your service, clabot |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your PR!
Needs a test and documentation (where other config properties are documented).
@@ -95,6 +95,8 @@ def __init__(self, conf): | |||
raise ValueError("ssl.certificate.location required when" | |||
" configuring ssl.key.location") | |||
|
|||
self.timeout = conf_copy.pop('timeout', 30.00) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about "request.timeout", since timeout is a bit too generic?
| | | | | ||
| ``request.timeout`` |float | | | ||
| | | By default timeout is 30.00 seconds | | ||
| | | the URL if present. | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"the URL if present." should probably be removed.
@@ -282,7 +282,12 @@ class SchemaRegistryClient(object): | |||
| | | By default userinfo is extracted from | | |||
| | | the URL if present. | | |||
+------------------------------+------+-------------------------------------------------+ | |||
|
|||
| | | Timeout for HTTP/S calls to Schema registry | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Timeout in seconds for ..
|
||
def test_timeout_exception_thrown_when_unreasonably_low_timeout_set(mock_schema_registry): | ||
conf = {'url': TEST_URL, | ||
'request.timeout' : 0.01 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if TEST_URL is a valid URL I don't think a request timeout of 10ms is sufficienctly reliable to be exceeded.
Instead suggest creating a TCP listener that you connect to.
sr = mock_schema_registry(conf) | ||
with pytest.raises(ConnectTimeoutError) as e : | ||
sr.get_schema() | ||
assert isinstance(e, ConnectTimeoutError) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why is this assert needed? I believe pytest.raises already check this
Thanks for the feedback, will get working on it :) |
cant get the librdkafka to build & test locally, withdrawing |
What errors were you seeing with librdkafka? |
when in try to run the tests as per the instructions i get this error |
proposed fix for #905