Skip to content

Skeleton of a tracer for AWS X-Ray#8526

Merged
htuch merged 19 commits intoenvoyproxy:masterfrom
marcomagdy:xray
Oct 22, 2019
Merged

Skeleton of a tracer for AWS X-Ray#8526
htuch merged 19 commits intoenvoyproxy:masterfrom
marcomagdy:xray

Conversation

@marcomagdy
Copy link
Copy Markdown
Contributor

Signed-off-by: Marco Magdy mmagdy@gmail.com

Description:
A skeleton tracer to incrementally add support for AWS X-Ray
Risk Level: Low
Testing: unit tests for functionality in util - the rest of files have no business logic to test yet
Docs Changes: N/A
Release Notes: N/A

@repokitteh-read-only
Copy link
Copy Markdown

CC @envoyproxy/api-shepherds: Your approval is needed for changes made to api/.

🐱

Caused by: #8526 was opened by marcomagdy.

see: more, trace.

Comment thread source/extensions/tracers/xray/util.cc Outdated
Comment thread test/extensions/tracers/xray/util_test.cc Outdated
Comment thread source/extensions/tracers/xray/util.h Outdated
Comment thread source/extensions/tracers/xray/xray_tracer_impl.cc Outdated
Comment thread api/envoy/config/trace/v2/trace.proto Outdated
Comment thread test/extensions/tracers/xray/util_test.cc Outdated
Comment thread source/extensions/tracers/xray/util.h Outdated
Comment thread source/extensions/tracers/xray/util.cc Outdated
jmarantz
jmarantz previously approved these changes Oct 9, 2019
Copy link
Copy Markdown
Contributor

@jmarantz jmarantz left a comment

Choose a reason for hiding this comment

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

lgtm modulo issues of consistency with envoy config practice (config with inlined data) vs AWS sdk practice (config with ref to filename).

I'll let @htuch make the call.

Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
@marcomagdy
Copy link
Copy Markdown
Contributor Author

I've changed the file_name to be a DataSource

Copy link
Copy Markdown
Member

@htuch htuch left a comment

Choose a reason for hiding this comment

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

/wait

Comment thread source/extensions/tracers/xray/sampling_strategy.h Outdated
Comment thread source/extensions/tracers/xray/tracer.h Outdated
Comment thread source/extensions/tracers/xray/util.cc Outdated
Comment thread source/extensions/tracers/xray/util.cc Outdated
Comment thread source/extensions/tracers/xray/util.h
Comment thread test/extensions/tracers/xray/util_test.cc Outdated
Comment thread api/envoy/config/trace/v2/trace.proto
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
@marcomagdy marcomagdy requested a review from htuch October 11, 2019 18:45
Copy link
Copy Markdown
Member

@htuch htuch left a comment

Choose a reason for hiding this comment

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

/wait

Comment thread source/extensions/tracers/xray/util.cc Outdated
Comment thread source/extensions/tracers/xray/config.cc Outdated
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Comment thread source/extensions/tracers/xray/config.cc Outdated
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
@marcomagdy marcomagdy requested a review from htuch October 15, 2019 02:19
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Copy link
Copy Markdown
Member

@htuch htuch left a comment

Choose a reason for hiding this comment

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

Great, LGTM modulo a couple of test asks. The differential fuzzing is optional, but an idea that would make sense long term, in particular if we want to use this elsewhere in Envoy.
/wait

}

private:
std::mt19937 rng_;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

FYI, this is totally fine for this PR, but for the real implementation, you should obtain randomness via a Runtime::RandomGenerator (I think from factory context), to allow proper dependency injection and deterministic tests.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I have a reasonable explanation for this. But we'll talk about it in the next PRs

Comment thread test/extensions/tracers/xray/fuzz_test.cc Outdated
Comment thread test/extensions/tracers/xray/util_test.cc
Comment thread test/extensions/tracers/xray/fuzz_test.cc Outdated
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
Signed-off-by: Marco Magdy <mmagdy@gmail.com>
@marcomagdy
Copy link
Copy Markdown
Contributor Author

macos build seems to be stuck.
/retest

@repokitteh-read-only
Copy link
Copy Markdown

🐴 hold your horses - no failures detected, yet.

🐱

Caused by: a #8526 (comment) was created by @marcomagdy.

see: more, trace.

@htuch
Copy link
Copy Markdown
Member

htuch commented Oct 18, 2019

/azp run

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 3 pipeline(s).

Copy link
Copy Markdown
Member

@htuch htuch left a comment

Choose a reason for hiding this comment

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

Thanks! I'd be keen to see the discussed improvements around glob parsing land, but given this is an opt-in extensions and a skeleton, let's merge and continue to iterate.

@marcomagdy
Copy link
Copy Markdown
Contributor Author

Is there anything I have to do to get this PR merged?
Also, should I squash the commits? or is the person merging this PR expected to do the squashing?

@jmarantz
Copy link
Copy Markdown
Contributor

Don't squash (or force-push); that will happen on merge. Probably we need to re-execute the MacOS tests which have most likely flaked; I'll do that now.

@jmarantz
Copy link
Copy Markdown
Contributor

/azp run envoy-macos

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

@htuch htuch merged commit f68368f into envoyproxy:master Oct 22, 2019
derekargueta pushed a commit to derekargueta/envoy that referenced this pull request Oct 24, 2019
A skeleton tracer to incrementally add support for AWS X-Ray

Risk Level: Low
Testing: unit tests for functionality in util - the rest of files have no business logic to test yet

Signed-off-by: Marco Magdy <mmagdy@gmail.com>
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.

4 participants