Skip to content

chore: replace anymap with a simple hashmap#19335

Merged
StephenWakely merged 4 commits intomasterfrom
stephen/remove_anymap
Dec 11, 2023
Merged

chore: replace anymap with a simple hashmap#19335
StephenWakely merged 4 commits intomasterfrom
stephen/remove_anymap

Conversation

@StephenWakely
Copy link
Contributor

#18929 introduced a dependency on anymap, which according to https://rustsec.org/advisories/RUSTSEC-2021-0065.html is unmaintained.

This PR removes the dependency and replaces it with a simple HashMap of TypeId -> Any.

Signed-off-by: Stephen Wakely <fungus.humungus@gmail.com>
Signed-off-by: Stephen Wakely <fungus.humungus@gmail.com>
@datadog-vectordotdev
Copy link

datadog-vectordotdev bot commented Dec 7, 2023

Datadog Report

Branch report: stephen/remove_anymap
Commit report: 57ffd6b

vector: 0 Failed, 0 New Flaky, 2035 Passed, 0 Skipped, 1m 23.32s Wall Time

greptimedb-client = { git = "https://github.com/GreptimeTeam/greptimedb-client-rust.git", rev = "bc32362adf0df17a41a95bae4221d6d8f1775656", optional = true }

# External libs
anymap = { version = "0.12", default-features = false }
Copy link
Member

Choose a reason for hiding this comment

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

Would it be worth adding a ban to deny.toml for this?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Would it be worth adding a ban to deny.toml for this?

That's a good idea 👍

@StephenWakely StephenWakely added this pull request to the merge queue Dec 11, 2023
@github-actions
Copy link

Regression Detector Results

Run ID: 203f31ad-9b5a-43e5-a25d-a224c975701d
Baseline: 77353fc
Comparison: 1d5b881
Total CPUs: 7

Performance changes are noted in the perf column of each table:

  • ✅ denotes better comparison variant performance
  • ❌ denotes worse comparison variant performance

Explanation

A regression test is an A/B test of target performance in a repeatable rig, where "performance" is measured as "comparison variant minus baseline variant" for an optimization goal (e.g., ingress throughput). Due to intrinsic variability in measuring that goal, we can only estimate its mean value for each experiment; we report uncertainty in that value as a 90.00% confidence interval denoted "Δ mean % CI".

For each experiment, we decide whether a change in performance is a "regression" -- a change worth investigating further -- if all of the following criteria are true:

  1. Its estimated |Δ mean %| ≥ 5.00%, indicating the change is big enough to merit a closer look.

  2. Its 90.00% confidence interval "Δ mean % CI" does not contain zero, indicating that if our statistical model is accurate, there is at least a 90.00% chance there is a difference in performance between baseline and comparison variants.

  3. Its configuration does not mark it "erratic".

No interesting changes in experiment optimization goals with confidence ≥ 90.00% and |Δ mean %| ≥ 5.00%.

Declared stable experiments that are now erratic

An experiment is erratic (i.e., not stable) if its coefficient of variation is at least 0.10.

perf experiment goal Δ mean % Δ mean % CI confidence
file_to_blackhole egress throughput +0.97 [-1.49, +3.44] 48.45%
http_to_http_acks ingress throughput +0.21 [-1.10, +1.51] 20.49%
splunk_hec_route_s3 ingress throughput -0.40 [-0.92, +0.12] 79.34%
fluent_elasticsearch ingress throughput -1.87 [-2.35, -1.39] 100.00%

Fine details of change detection per experiment

perf experiment goal Δ mean % Δ mean % CI confidence
syslog_log2metric_humio_metrics ingress throughput +4.08 [+3.93, +4.23] 100.00%
otlp_http_to_blackhole ingress throughput +2.73 [+2.59, +2.87] 100.00%
datadog_agent_remap_datadog_logs_acks ingress throughput +2.54 [+2.45, +2.63] 100.00%
otlp_grpc_to_blackhole ingress throughput +2.51 [+2.41, +2.61] 100.00%
syslog_loki ingress throughput +2.33 [+2.27, +2.39] 100.00%
http_text_to_http_json ingress throughput +2.32 [+2.18, +2.45] 100.00%
socket_to_socket_blackhole ingress throughput +2.30 [+2.22, +2.38] 100.00%
syslog_splunk_hec_logs ingress throughput +2.05 [+2.01, +2.10] 100.00%
datadog_agent_remap_datadog_logs ingress throughput +1.17 [+1.08, +1.27] 100.00%
syslog_humio_logs ingress throughput +1.17 [+1.08, +1.26] 100.00%
file_to_blackhole egress throughput +0.97 [-1.49, +3.44] 48.45%
syslog_log2metric_tag_cardinality_limit_blackhole ingress throughput +0.87 [+0.74, +0.99] 100.00%
datadog_agent_remap_blackhole_acks ingress throughput +0.33 [+0.23, +0.43] 100.00%
http_to_http_acks ingress throughput +0.21 [-1.10, +1.51] 20.49%
http_to_http_noack ingress throughput +0.15 [+0.06, +0.24] 99.47%
datadog_agent_remap_blackhole ingress throughput +0.08 [-0.02, +0.18] 82.81%
http_to_http_json ingress throughput +0.02 [-0.05, +0.10] 41.53%
splunk_hec_indexer_ack_blackhole ingress throughput +0.00 [-0.14, +0.14] 1.32%
splunk_hec_to_splunk_hec_logs_acks ingress throughput +0.00 [-0.14, +0.14] 0.08%
splunk_hec_to_splunk_hec_logs_noack ingress throughput -0.01 [-0.12, +0.10] 12.28%
syslog_regex_logs2metric_ddmetrics ingress throughput -0.03 [-0.12, +0.06] 38.95%
enterprise_http_to_http ingress throughput -0.08 [-0.14, -0.01] 93.01%
syslog_log2metric_splunk_hec_metrics ingress throughput -0.28 [-0.41, -0.14] 99.93%
splunk_hec_route_s3 ingress throughput -0.40 [-0.92, +0.12] 79.34%
http_to_s3 ingress throughput -0.42 [-0.69, -0.14] 98.69%
http_elasticsearch ingress throughput -1.07 [-1.14, -1.00] 100.00%
fluent_elasticsearch ingress throughput -1.87 [-2.35, -1.39] 100.00%

Merged via the queue into master with commit 1d5b881 Dec 11, 2023
@StephenWakely StephenWakely deleted the stephen/remove_anymap branch December 11, 2023 14:28
AndrooTheChen pushed a commit to discord/vector that referenced this pull request Sep 23, 2024
* Replace anymap with a simple hashmap

Signed-off-by: Stephen Wakely <fungus.humungus@gmail.com>

* Slight tidy

Signed-off-by: Stephen Wakely <fungus.humungus@gmail.com>

* Still need the license

Signed-off-by: Stephen Wakely <fungus.humungus@gmail.com>

---------

Signed-off-by: Stephen Wakely <fungus.humungus@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.

3 participants