GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Upgrade finagle to version that includes tls tracing compatible netty-tcnative by ddelnano · Pull Request #562 · pixie-io/pixie

Conversation

@ddelnano

@ddelnano ddelnano commented Aug 8, 2022 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

This PR upgrades finagle to install a version that includes the netty changes I upstreamed (netty/netty#12438, netty/netty-tcnative#731) to support #407. Once this is upgraded, the next step is to refresh #463.

Testing

  • Ran the thriftmux container and verified that the logs of the client show that netty tcnative is used (improperly installed netty tcnative will silently succeed)
vagrant@vagrant:/vagrantbazel run -c dbg src/stirling/source_connectors/socket_tracer/testing/containers/thriftmux:server_image

vagrant@vagrant:/vagrant$ docker run -it bazel/src/stirling/source_connectors/socket_tracer/testing/containers/thriftmux:server_image --use-tls true

# Run client inside the server container and see netty-tcnative is used successfully
/ # /usr/bin/java -cp @/app/px/src/stirling/source_connectors/socket_tracer/testing/containers/thriftmux/server_image.classpath Client --use-tls true 2>&1 | grep -i tcnative
01:03:03.586 [finagle/netty4-1-1] DEBUG io.netty.util.internal.NativeLibraryLoader - Successfully loaded the library /tmp/libnetty_tcnative_linux_x86_64685160139595718633.so
01:03:03.587 [finagle/netty4-1-1] DEBUG io.netty.util.internal.NativeLibraryLoader - Loaded library with name 'netty_tcnative_linux_x86_64'
01:03:03.587 [finagle/netty4-1-1] DEBUG io.netty.handler.ssl.OpenSsl - Initialize netty-tcnative using engine: 'default'

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@pixie-io-buildbot

pixie-io-buildbot commented Aug 8, 2022

Copy link
Copy Markdown
Member

Can one of the admins verify this patch?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

Dom Del Nano
Upgrade finagle to version that includes tls tracing compatible netty…
7c3cce6
…-tcnative

Signed-off-by: Dom Del Nano <[email protected]>
@ddelnano
ddelnano force-pushed the ddelnano/upgrade-finagle-to-use-mtls-tracing-capable-netty branch from ab4a43e to 6019324 Compare August 8, 2022 01:19
@ddelnano ddelnano mentioned this pull request Aug 8, 2022
Cyclic dependency error with multi-classifier POMs bazel-contrib/rules_jvm_external#704
Closed
Dom Del Nano
Fix linting issues
29c3d4d
Signed-off-by: Dom Del Nano <[email protected]>
@ddelnano
ddelnano force-pushed the ddelnano/upgrade-finagle-to-use-mtls-tracing-capable-netty branch from d33b4f3 to 4d50f9a Compare August 15, 2022 04:57
@zasgar

zasgar commented Aug 17, 2022

Copy link
Copy Markdown
Member

ok to test

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@ddelnano ddelnano mentioned this pull request Aug 17, 2022
Add support for tracing tls traffic from finagle (netty based) services #569
Closed
4 tasks done
@yzhao1012

yzhao1012 commented Aug 17, 2022

Copy link
Copy Markdown
Contributor

Run

make buildifier

To reform the build file. The Jenkins failure is because of BUILD.bazel file's line's ordering are not sorted according to the style guide.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@philkuz

philkuz commented Aug 17, 2022

Copy link
Copy Markdown
0 / 1,544] [Prepa] BazelWorkspaceStatusAction stable-status.txt ... (3 actions, 0 running)
ERROR: /root/.cache/bazel/_bazel_root/4b2a6651efb8be1e285d05f4edee89cf/external/maven/BUILD:1040:11: Creating compile jar for @maven//:io_netty_netty_codec_http2 failed: (Aborted): AddJarManifestEntry failed: error executing command
  (cd /root/.cache/bazel/_bazel_root/4b2a6651efb8be1e285d05f4edee89cf/sandbox/linux-sandbox/1410/execroot/px && \
  exec env - \
  bazel-out/k8-opt-exec-50AE0418-ST-d2f0ea542b71/bin/external/rules_jvm_external/private/tools/java/rules/jvm/external/jar/AddJarManifestEntry --source external/maven/v1/https/repo1.maven.org/maven2/io/netty/netty-codec-http2/4.1.78.Final/netty-codec-http2-4.1.78.Final.jar --output bazel-out/k8-opt-ST-4a519fd6d3e4/bin/external/maven/v1/https/repo1.maven.org/maven2/io/netty/netty-codec-http2/4.1.78.Final/header_netty-codec-http2-4.1.78.Final.jar --remove-entry Class-Path)
# Configuration: 122cfd117844598832e157b473675f04e637a4ebad9f6e1a4695ba9a512508d8
# Execution platform: @local_execution_config_platform//:platform

Happened when the following was ran:

bazel build //src/stirling/bpf_tools:bcc_symbolizer_bpf_test_lib //src/stirling/bpf_tools:bcc_wrapper_bpf_test_lib //src/stirling/bpf_tools:bpftrace_wrapper_bpf_test_lib //src/stirling/bpf_tools:uprobe_extra_trigger_bpf_test_lib //src/stirling/e2e_tests:bpf_map_leak_bpf_test_lib //src/stirling/e2e_tests:stirling_bpf_test_lib //src/stirling/obj_tools:elf_reader_symbolizer_bpf_test_lib //src/stirling/source_connectors/cpu_stat_bpftrace:cpu_stat_bpftrace_connector_bpf_test_lib //src/stirling/source_connectors/dynamic_bpftrace:dynamic_bpftrace_connector_bpf_test_lib //src/stirling/source_connectors/dynamic_tracer:dynamic_trace_bpf_test_lib //src/stirling/source_connectors/dynamic_tracer:stirling_dt_bpf_test_lib //src/stirling/source_connectors/perf_profiler:perf_profiler_bpf_test_lib //src/stirling/source_connectors/perf_profiler:stringifier_bpf_test_lib //src/stirling/source_connectors/proc_exit:proc_exit_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:amqp_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:conn_stats_bpf_test_lib //src/stirling/source_connectors/socket_tracer:cql_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:dns_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:dyn_lib_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:go_tls_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:grpc_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:http2_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:http_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:kafka_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:mux_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:mysql_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:nats_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:openssl_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:pgsql_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:redis_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:socket_trace_bpf_test_lib //src/stirling/source_connectors/stirling_error:stirling_error_bpf_test_lib //src/stirling/utils:detect_application_bpf_test_lib //src/stirling/utils:proc_path_tools_container_bpf_test_lib --compilation_mode=opt --config=bpf --build_metadata=COMMIT_SHA=eec5a47cac5f7619d4e9c86eb79209d726ae4c3a --target_pattern_file=bazel_buildables_bpf --build_metadata=CONFIG=bpf
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@ddelnano

ddelnano commented Aug 18, 2022

Copy link
Copy Markdown
Member Author

@philkuz thanks for identifying the issue. I ran the command you shared above (removing the --target_pattern_file flag since that cause an error) and I'm not able to reproduce that problem 🤔.

# Verify that the cli args without modification results in an error
vagrant@vagrant:/vagrant$ bazel build  //src/stirling/bpf_tools:bcc_symbolizer_bpf_test_lib //src/stirling/bpf_tools:bcc_wrapper_bpf_test_lib //src/stirling/bpf_tools:bpftrace_wrapper_bpf_test_lib //src/stirling/bpf_tools:uprobe_extra_trigger_bpf_test_lib //src/stirling/e2e_tests:bpf_map_leak_bpf_test_lib //src/stirling/e2e_tests:stirling_bpf_test_lib //src/stirling/obj_tools:elf_reader_symbolizer_bpf_test_lib //src/stirling/source_connectors/cpu_stat_bpftrace:cpu_stat_bpftrace_connector_bpf_test_lib //src/stirling/source_connectors/dynamic_bpftrace:dynamic_bpftrace_connector_bpf_test_lib //src/stirling/source_connectors/dynamic_tracer:dynamic_trace_bpf_test_lib //src/stirling/source_connectors/dynamic_tracer:stirling_dt_bpf_test_lib //src/stirling/source_connectors/perf_profiler:perf_profiler_bpf_test_lib //src/stirling/source_connectors/perf_profiler:stringifier_bpf_test_lib //src/stirling/source_connectors/proc_exit:proc_exit_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:amqp_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:conn_stats_bpf_test_lib //src/stirling/source_connectors/socket_tracer:cql_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:dns_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:dyn_lib_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:go_tls_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:grpc_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:http2_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:http_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:kafka_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:mux_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:mysql_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:nats_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:openssl_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:pgsql_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:redis_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:socket_trace_bpf_test_lib //src/stirling/source_connectors/stirling_error:stirling_error_bpf_test_lib //src/stirling/utils:detect_application_bpf_test_lib //src/stirling/utils:proc_path_tools_container_bpf_test_lib  --config=bpf --compilation_mode=opt --build_metadata=COMMIT_SHA=eec5a47cac5f7619d4e9c86eb79209d726ae4c3a  --target_pattern_file=bazel_buildables_bpf --build_metadata=CONFIG=bpf
ERROR: Command-line target pattern and --target_pattern_file cannot both be specified


vagrant@vagrant:/vagrant$ bazel build  //src/stirling/bpf_tools:bcc_symbolizer_bpf_test_lib //src/stirling/bpf_tools:bcc_wrapper_bpf_test_lib //src/stirling/bpf_tools:bpftrace_wrapper_bpf_test_lib //src/stirling/bpf_tools:uprobe_extra_trigger_bpf_test_lib //src/stirling/e2e_tests:bpf_map_leak_bpf_test_lib //src/stirling/e2e_tests:stirling_bpf_test_lib //src/stirling/obj_tools:elf_reader_symbolizer_bpf_test_lib //src/stirling/source_connectors/cpu_stat_bpftrace:cpu_stat_bpftrace_connector_bpf_test_lib //src/stirling/source_connectors/dynamic_bpftrace:dynamic_bpftrace_connector_bpf_test_lib //src/stirling/source_connectors/dynamic_tracer:dynamic_trace_bpf_test_lib //src/stirling/source_connectors/dynamic_tracer:stirling_dt_bpf_test_lib //src/stirling/source_connectors/perf_profiler:perf_profiler_bpf_test_lib //src/stirling/source_connectors/perf_profiler:stringifier_bpf_test_lib //src/stirling/source_connectors/proc_exit:proc_exit_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:amqp_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:conn_stats_bpf_test_lib //src/stirling/source_connectors/socket_tracer:cql_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:dns_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:dyn_lib_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:go_tls_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:grpc_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:http2_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:http_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:kafka_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:mux_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:mysql_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:nats_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:openssl_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:pgsql_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:redis_trace_bpf_test_lib //src/stirling/source_connectors/socket_tracer:socket_trace_bpf_test_lib //src/stirling/source_connectors/stirling_error:stirling_error_bpf_test_lib //src/stirling/utils:detect_application_bpf_test_lib //src/stirling/utils:proc_path_tools_container_bpf_test_lib  --config=bpf --compilation_mode=opt --build_metadata=COMMIT_SHA=eec5a47cac5f7619d4e9c86eb79209d726ae4c3a  --build_metadata=CONFIG=bpf
INFO: Analyzed 34 targets (702 packages loaded, 89714 targets configured).
INFO: Found 34 targets...
INFO: From Building external/io_bazel_rules_scala/src/java/io/bazel/rulesscala/scalac/scalac.jar (4 source files):
warning: [path] bad path element "/home/vagrant/.cache/bazel/_bazel_vagrant/6ad5fdbcbf2eaa93bd62f92333a2e6e5/execroot/px/bazel-out/k8-opt-exec-50AE0418-ST-d2f0ea542b71/bin/external/io_bazel_rules_scala_scala_compiler/io_bazel_rules_scala_scala_compiler.stamp/scala-reflect.jar": no such file or directory
warning: [path] bad path element "/home/vagrant/.cache/bazel/_bazel_vagrant/6ad5fdbcbf2eaa93bd62f92333a2e6e5/execroot/px/bazel-out/k8-opt-exec-50AE0418-ST-d2f0ea542b71/bin/external/io_bazel_rules_scala_scala_compiler/io_bazel_rules_scala_scala_compiler.stamp/scala-library.jar": no such file or directory
INFO: From scala //src/stirling/source_connectors/socket_tracer/testing/containers/thriftmux:thrift_library:
warning: 3 deprecations (since 2.13.0); re-run with -deprecation for details
1 warning
INFO: From Executing genrule @com_github_antlr_grammars_v4//:mysql_parser_gen:
warning(154): MySQLParser.g4:1347:0: rule blockStatement contains an optional block with at least one alternative that can match an empty string
INFO: Elapsed time: 3242.679s, Critical Path: 358.46s
INFO: 6023 processes: 1152 internal, 4844 linux-sandbox, 27 worker.
INFO: Build completed successfully, 6023 total actions

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@zasgar

zasgar commented Aug 18, 2022

Copy link
Copy Markdown
Member

retest this please

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@ddelnano Dom Del Nano
Fix issue introduced during linting
a0a73ef
Signed-off-by: Dom Del Nano <[email protected]>
@ddelnano
ddelnano force-pushed the ddelnano/upgrade-finagle-to-use-mtls-tracing-capable-netty branch from 00e4e1d to a0a73ef Compare August 18, 2022 20:07
oazizi000
oazizi000 reviewed Aug 23, 2022
View reviewed changes
Comment thread bazel/netty.bzl Resolved

Uh oh!

There was an error while loading. Please reload this page.

Dom Del Nano
Remove osx and windows netty jars
977d2c0
Signed-off-by: Dom Del Nano <[email protected]>
@ddelnano

ddelnano commented Aug 25, 2022 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member Author

This appears to be merged in e577064 🥳

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@ddelnano ddelnano closed this Aug 25, 2022
@ddelnano ddelnano mentioned this pull request Jun 15, 2023
Upgrade rules_jvm_external to address maven install bugs #1506
Merged
vihangm pushed a commit that referenced this pull request Jun 15, 2023
@ddelnano
Upgrade rules_jvm_external to address maven install bugs (#1506)
9452e37
Summary: Upgrade rules_jvm_external to address maven install bugs

The thriftmux container used in the `netty_tls_trace_bpf` test
previously ran into
bazel-contrib/rules_jvm_external#686. This
required us to manually install maven dependencies and override things
to break the dependency loop (see TODO and `fetch_netty_tcnative_jars`
from #562). This issue was fixed
in rules_jvm_external v4.3, however, I opted to bump this to the latest
version.

After this is merged, I will follow up with the netty dependency install
cleanup.

Relevant Issues: N/A

Type of change: /kind cleanup

Test Plan: Verified that `netty_tls_trace_bpf_test` containers avoid
maven install issue and that antlr grammar builds and carnot tests pass
(`bazel build //... && bazel test //src/carnot/...`)

I believe the carnot sql parsing is the only production artifact that
relies on these jvm rules. Please let me know if the validation above
does not exercise the antlr dependency the way I expect.

Signed-off-by: Dom Del Nano <[email protected]>
ddelnano added a commit to k8sstormcenter/pixie that referenced this pull request Feb 25, 2026
@ddelnano
Upgrade rules_jvm_external to address maven install bugs (pixie-io#1506)
15b5a09
Summary: Upgrade rules_jvm_external to address maven install bugs

The thriftmux container used in the `netty_tls_trace_bpf` test
previously ran into
bazel-contrib/rules_jvm_external#686. This
required us to manually install maven dependencies and override things
to break the dependency loop (see TODO and `fetch_netty_tcnative_jars`
from pixie-io#562). This issue was fixed
in rules_jvm_external v4.3, however, I opted to bump this to the latest
version.

After this is merged, I will follow up with the netty dependency install
cleanup.

Relevant Issues: N/A

Type of change: /kind cleanup

Test Plan: Verified that `netty_tls_trace_bpf_test` containers avoid
maven install issue and that antlr grammar builds and carnot tests pass
(`bazel build //... && bazel test //src/carnot/...`)

I believe the carnot sql parsing is the only production artifact that
relies on these jvm rules. Please let me know if the validation above
does not exercise the antlr dependency the way I expect.

Signed-off-by: Dom Del Nano <[email protected]>
ddelnano added a commit to k8sstormcenter/pixie that referenced this pull request Feb 25, 2026
@ddelnano
Upgrade rules_jvm_external to address maven install bugs (pixie-io#1506)
2a854e6
Summary: Upgrade rules_jvm_external to address maven install bugs

The thriftmux container used in the `netty_tls_trace_bpf` test
previously ran into
bazel-contrib/rules_jvm_external#686. This
required us to manually install maven dependencies and override things
to break the dependency loop (see TODO and `fetch_netty_tcnative_jars`
from pixie-io#562). This issue was fixed
in rules_jvm_external v4.3, however, I opted to bump this to the latest
version.

After this is merged, I will follow up with the netty dependency install
cleanup.

Relevant Issues: N/A

Type of change: /kind cleanup

Test Plan: Verified that `netty_tls_trace_bpf_test` containers avoid
maven install issue and that antlr grammar builds and carnot tests pass
(`bazel build //... && bazel test //src/carnot/...`)

I believe the carnot sql parsing is the only production artifact that
relies on these jvm rules. Please let me know if the validation above
does not exercise the antlr dependency the way I expect.

Signed-off-by: Dom Del Nano <[email protected]>
entlein pushed a commit to k8sstormcenter/pixie that referenced this pull request Jun 2, 2026
@ddelnano
Upgrade rules_jvm_external to address maven install bugs (pixie-io#1506)
a740c6f
Summary: Upgrade rules_jvm_external to address maven install bugs

The thriftmux container used in the `netty_tls_trace_bpf` test
previously ran into
bazel-contrib/rules_jvm_external#686. This
required us to manually install maven dependencies and override things
to break the dependency loop (see TODO and `fetch_netty_tcnative_jars`
from pixie-io#562). This issue was fixed
in rules_jvm_external v4.3, however, I opted to bump this to the latest
version.

After this is merged, I will follow up with the netty dependency install
cleanup.

Relevant Issues: N/A

Type of change: /kind cleanup

Test Plan: Verified that `netty_tls_trace_bpf_test` containers avoid
maven install issue and that antlr grammar builds and carnot tests pass
(`bazel build //... && bazel test //src/carnot/...`)

I believe the carnot sql parsing is the only production artifact that
relies on these jvm rules. Please let me know if the validation above
does not exercise the antlr dependency the way I expect.

Signed-off-by: Dom Del Nano <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@oazizi000 oazizi000 oazizi000 left review comments

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

6 participants

@ddelnano @pixie-io-buildbot @zasgar @yzhao1012 @philkuz @oazizi000
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.