Skip to content

zookeeper: parse server responses#7574

Merged
snowp merged 12 commits intoenvoyproxy:masterfrom
rgs1:zk-filter-parse-responses
Aug 2, 2019
Merged

zookeeper: parse server responses#7574
snowp merged 12 commits intoenvoyproxy:masterfrom
rgs1:zk-filter-parse-responses

Conversation

@rgs1
Copy link
Member

@rgs1 rgs1 commented Jul 14, 2019

This adds support for parsing server responses and watch events. One
or more follow-up PRs will add support for latency measurements and
access log.

Signed-off-by: Raul Gutierrez Segales rgs@pinterest.com

This adds support for parsing server respones and watch events. One
or more follow-up PRs will add support for latency measurements and
access log.

Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
@rgs1 rgs1 requested a review from snowp as a code owner July 14, 2019 15:59
@snowp snowp self-assigned this Jul 14, 2019
Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
@rgs1
Copy link
Member Author

rgs1 commented Jul 14, 2019

Note: docs & tests still missing, will follow-up later today/tomorrow.

@rgs1
Copy link
Member Author

rgs1 commented Jul 14, 2019

@mattklein123 got this twice in a row now:

//test/extensions/filters/http/dynamic_forward_proxy:proxy_filter_integration_test TIMEOUT in 315.0s
  /build/tmp/_bazel_bazel/b570b5ccd0454dc9af9f65ab1833764d/execroot/envoy/bazel-out/k8-dbg/testlogs/test/extensions/filters/http/dynamic_forward_proxy/proxy_filter_integration_test/test.log

@rgs1
Copy link
Member Author

rgs1 commented Jul 14, 2019

/retest

@repokitteh-read-only
Copy link

🔨 rebuilding ci/circleci: tsan (failed build)

🐱

Caused by: a #7574 (comment) was created by @rgs1.

see: more, trace.

@stale
Copy link

stale bot commented Jul 25, 2019

This pull request has been automatically marked as stale because it has not had activity in the last 7 days. It will be closed in 7 days if no further activity occurs. Please feel free to give a status update now, ping for review, or re-open when it's ready. Thank you for your contributions!

@stale stale bot added the stale stalebot believes this issue/PR has not been touched recently label Jul 25, 2019
@rgs1
Copy link
Member Author

rgs1 commented Jul 25, 2019

I'll push tests today/tomorrow.

@stale stale bot removed the stale stalebot believes this issue/PR has not been touched recently label Jul 25, 2019
Raul Gutierrez Segales added 3 commits July 28, 2019 10:18
This should cover most of it, I still need to test some
corner cases.

Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
@rgs1
Copy link
Member Author

rgs1 commented Jul 28, 2019

hmm, unrelated failure:

//test/common/runtime:runtime_impl_test                                 TIMEOUT in 315.0s
  /build/tmp/_bazel_bazel/b570b5ccd0454dc9af9f65ab1833764d/execroot/envoy/bazel-out/k8-dbg/testlogs/test/common/runtime/runtime_impl_test/test.log

@rgs1
Copy link
Member Author

rgs1 commented Jul 28, 2019

/retest

@repokitteh-read-only
Copy link

🔨 rebuilding ci/circleci: asan (failed build)

🐱

Caused by: a #7574 (comment) was created by @rgs1.

see: more, trace.

@rgs1
Copy link
Member Author

rgs1 commented Jul 28, 2019

another timeout for the same unrelated integration test:

//test/common/runtime:runtime_impl_test                                 TIMEOUT in 315.0s
  /build/tmp/_bazel_bazel/b570b5ccd0454dc9af9f65ab1833764d/execroot/envoy/bazel-out/k8-dbg/testlogs/test/common/runtime/runtime_impl_test/test.log

cc: @alyssawilk since maybe this is related to e61681d ?

@rgs1
Copy link
Member Author

rgs1 commented Jul 28, 2019

/retest

@repokitteh-read-only
Copy link

🔨 rebuilding ci/circleci: asan (failed build)

🐱

Caused by: a #7574 (comment) was created by @rgs1.

see: more, trace.

@rgs1
Copy link
Member Author

rgs1 commented Jul 28, 2019

Yeah it does time out in the test case added by e61681d:

[----------] 3 tests from StaticLoaderImplTest
[ RUN      ] StaticLoaderImplTest.All
[       OK ] StaticLoaderImplTest.All (95 ms)
[ RUN      ] StaticLoaderImplTest.ProtoParsing
[       OK ] StaticLoaderImplTest.ProtoParsing (147 ms)
[ RUN      ] StaticLoaderImplTest.RuntimeFromNonWorkerThreads
Terminated
-- Test timed out at 2019-07-28 19:03:52 UTC --

rgs1 pushed a commit to rgs1/envoy that referenced this pull request Jul 28, 2019
This is a follow-up to e61681d. While working on envoyproxy#7574, I am getting
consistent timeouts for this test.

I think it happens because the code on the main thread runs slower
than the code on the reader thread.

My fix is to properly acquire and release the lock on each step,
to ensure they are properly interlaced. That is:

1) read from reader
2) write from writer
3) read new value from reader
4) read new value from writer

To repro the timeout, I added a sleep before step 2. After this change,
I can't repro anymore.

Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
@rgs1
Copy link
Member Author

rgs1 commented Jul 28, 2019

Possible fix for timeouts: #7746.

alyssawilk pushed a commit that referenced this pull request Jul 29, 2019
While working on #7574, I am getting
consistent timeouts for this test.

To repro the timeout, I added a sleep before step 2. After this change,
I can't repro anymore.

Risk: n/a (test only)
Copy link
Contributor

@snowp snowp left a comment

Choose a reason for hiding this comment

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

This looks pretty good, just a few comments

Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
@rgs1
Copy link
Member Author

rgs1 commented Jul 31, 2019

/retest

@repokitteh-read-only
Copy link

🔨 rebuilding ci/circleci: compile_time_options (failed build)

🐱

Caused by: a #7574 (comment) was created by @rgs1.

see: more, trace.

Copy link
Contributor

@snowp snowp left a comment

Choose a reason for hiding this comment

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

One minor comment otherwise LGTM

Signed-off-by: Raul Gutierrez Segales <rgs@pinterest.com>
Copy link
Contributor

@snowp snowp left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@snowp snowp merged commit 266252e into envoyproxy:master Aug 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants