GeezerVison is showing github.com — Investigate novel pub/sub system test failures · Issue #1085 · googleapis/google-cloud-python
Investigate novel pub/sub system test failures #1085Description
Subscription.pull(return_immedately=False, max_messages=2) returns immediately (See 'Subscription.pull(return_immedately=False, max_messages=2)' returns immediately :( #893)
- Missing ACK ID
======================================================================
ERROR: test_message_pull_mode_e2e (pubsub.TestPubsub)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/travis/build/GoogleCloudPlatform/gcloud-python/system_tests/pubsub.py", line 123, in test_message_pull_mode_e2e
subscription.acknowledge(ack_ids)
File "/home/travis/build/GoogleCloudPlatform/gcloud-python/.tox/system-tests/lib/python2.7/site-packages/gcloud/pubsub/subscription.py", line 230, in acknowledge
method='POST', path='%s:acknowledge' % (self.path,), data=data)
File "/home/travis/build/GoogleCloudPlatform/gcloud-python/.tox/system-tests/lib/python2.7/site-packages/gcloud/connection.py", line 419, in api_request
error_info=method + ' ' + url)
gcloud.exceptions.BadRequest: 400 You have not specified an ack ID in the request. (POST https://pubsub.googleapis.com/v1/projects/precise-truck-742/subscriptions/subscribing-now:acknowledge)
----------------------------------------------------------------------
From:
- https://travis-ci.org/GoogleCloudPlatform/gcloud-python/builds/75334450
- https://travis-ci.org/GoogleCloudPlatform/gcloud-python/builds/77188348
- https://travis-ci.org/GoogleCloudPlatform/gcloud-python/builds/77564743
- https://travis-ci.org/GoogleCloudPlatform/gcloud-python/builds/94920686
- Only one message returned
======================================================================
ERROR: test_message_pull_mode_e2e (pubsub.TestPubsub)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/travis/build/GoogleCloudPlatform/gcloud-python/system_tests/pubsub.py", line 129, in test_message_pull_mode_e2e
message1, message2 = sorted(messages, key=_by_timestamp)
ValueError: need more than 1 value to unpack
----------------------------------------------------------------------
From:
- https://travis-ci.org/GoogleCloudPlatform/gcloud-python/builds/77052107
- https://travis-ci.org/GoogleCloudPlatform/gcloud-python/builds/98407178
- Eventual Consistency Error
======================================================================
FAIL: test_list_subscriptions (pubsub.TestPubsub)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/travis/build/GoogleCloudPlatform/gcloud-python/system_tests/pubsub.py", line 100, in test_list_subscriptions
self.assertEqual(len(created), len(subscriptions_to_create))
AssertionError: 2 != 3
======================================================================
FAIL: test_list_topics (pubsub.TestPubsub)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/travis/build/GoogleCloudPlatform/gcloud-python/system_tests/pubsub.py", line 62, in test_list_topics
self.assertEqual(len(created), len(topics_to_create))
AssertionError: 2 != 3
----------------------------------------------------------------------
Ran 5 tests in 66.301s
FAILED (failures=2)
From:
- https://travis-ci.org/GoogleCloudPlatform/gcloud-python/builds/77600321
- https://travis-ci.org/GoogleCloudPlatform/gcloud-python/builds/78109143
Activitychanged the title [-]Investigate novel test failure (missing ACK ID)[/-] [+]Investigate novel pub/sub system test failure (missing ACK ID)[/+] on Aug 27, 2015dhermes commented on Aug 27, 2015 ContributorAuthor More actions changed the title [-]Investigate novel pub/sub system test failure (missing ACK ID)[/-] [+]Investigate novel pub/sub system test failures[/+] on Aug 27, 2015dhermes commented on Dec 4, 2015 ContributorAuthor More actions @tseaver @tmatsuo The 1st error occurred again today.
@tmatsuo Not sure if there is a place to report this internally, but we are hitting this with a tiny amount of load and we've see this server-side flakiness 4 times now. 99% of the time it works (i.e. it knows there is an Ack ID in the request) but for some reason it doesn't always pick it up. tmatsuo commented on Dec 4, 2015 @dhermes
99%, I think it matches the end-to-end message delivery latency expectations at this point.
The tail latency is mainly caused by server crashes, disk crashes, or network cut etc (but we never lost any messages so far, that's great), as you can imagine, and it's almost inevitable.
Only thing I can think of is longer wait time (and more pull calls) for the tests. Is it possible to have a time limit, and pulls again and again until it reaches the time limit? dhermes commented on Dec 4, 2015 ContributorAuthor More actions Ah I see. So in the source
ack_ids = [recv[0] for recv in received]
subscription.acknowledge(ack_ids)
we should check that received / ack_ids is not empty and then never send the acknowledge request? tmatsuo commented on Dec 4, 2015 The response can be contain 0 message, 1 message, or 2 messages. You can repeatedly call pull until you get the right amount of messages. sg? dhermes commented on Dec 4, 2015 ContributorAuthor More actions
can be contain message
You mean 0 messages? dhermes commented on Dec 4, 2015 ContributorAuthor More actions Also
repeatedly call pull until you get the right amount of messages
does sound good tmatsuo commented on Dec 4, 2015 @dhermes
You mean 0 messages?
Yes, I corrected my comment :)
dhermes commented on Dec 4, 2015 ContributorAuthor More actions daspecster commented on Aug 3, 2016 @dhermes, for point 4, I tried playing with @Retry in those methods and retrying didn't seem to work.
test_create_subscription_defaults (pubsub.TestPubsub) ... ok
test_create_subscription_w_ack_deadline (pubsub.TestPubsub) ... ok
test_create_topic (pubsub.TestPubsub) ... ok
test_fetch_delete_subscription_w_deleted_topic (pubsub.TestPubsub) ... 0 != 1, Trying again in 30 seconds...
0 != 1, Trying again in 60 seconds...
0 != 1, Trying again in 120 seconds...
FAIL
test_list_subscriptions (pubsub.TestPubsub) ... 2 != 3, Trying again in 30 seconds...
2 != 3, Trying again in 60 seconds...
2 != 3, Trying again in 120 seconds...
2 != 3, Trying again in 30 seconds...
True is not false, Trying again in 60 seconds...
True is not false, Trying again in 120 seconds...
FAIL
test_list_topics (pubsub.TestPubsub) ... 2 != 3, Trying again in 30 seconds...
2 != 3, Trying again in 60 seconds...
2 != 3, Trying again in 120 seconds...
FAIL
test_message_pull_mode_e2e (pubsub.TestPubsub) ... ok
test_subscription_iam_policy (pubsub.TestPubsub) ... ok
test_topic_iam_policy (pubsub.TestPubsub) ... ok daspecster commented on Aug 3, 2016 @dhermes just the asserts actually.
@tseaver fantastic! I'm excited for master to turn green again. tseaver commented on Aug 9, 2016 Point 3) now tracked in #2077. Point 1) is really the same issue, with the failure in parsing the empty response already fixed in #899. Point 2) is also a symptom of #2077.
MetadataMetadataDevelopmentNo branches or pull requestsIssue actions
|