This is an automated email from the ASF dual-hosted git repository.
chaokunyang pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/fory.git
The following commit(s) were added to refs/heads/main by this push:
new daca4e341 docs: fix rust benchmark links (#2896)
daca4e341 is described below
commit daca4e34101e41263dd40c39c2267a57532a36d9
Author: Shawn Yang <[email protected]>
AuthorDate: Wed Nov 5 12:18:12 2025 +0800
docs: fix rust benchmark links (#2896)
<!--
**Thanks for contributing to Apache Fory™.**
**If this is your first time opening a PR on fory, you can refer to
[CONTRIBUTING.md](https://github.com/apache/fory/blob/main/CONTRIBUTING.md).**
Contribution Checklist
- The **Apache Fory™** community has requirements on the naming of pr
titles. You can also find instructions in
[CONTRIBUTING.md](https://github.com/apache/fory/blob/main/CONTRIBUTING.md).
- Apache Fory™ has a strong focus on performance. If the PR you submit
will have an impact on performance, please benchmark it first and
provide the benchmark result here.
-->
## Why?
<!-- Describe the purpose of this PR. -->
## What does this PR do?
<!-- Describe the details of this PR. -->
## Related issues
<!--
Is there any related issue? If this PR closes them you say say
fix/closes:
- #xxxx0
- #xxxx1
- Fixes #xxxx2
-->
## Does this PR introduce any user-facing change?
<!--
If any user-facing interface changes, please [open an
issue](https://github.com/apache/fory/issues/new/choose) describing the
need to do so and update the document if necessary.
Delete section if not applicable.
-->
- [ ] Does this PR introduce any public API change?
- [ ] Does this PR introduce any binary protocol compatibility change?
## Benchmark
<!--
When the PR has an impact on performance (if you don't know whether the
PR will have an impact on performance, you can submit the PR first, and
if it will have impact on performance, the code reviewer will explain
it), be sure to attach a benchmark data here.
Delete section if not applicable.
-->
---
AGENTS.md | 1 +
README.md | 2 +-
benchmarks/{rust_benchmarks => rust_benchmark}/Cargo.toml | 0
benchmarks/{rust_benchmarks => rust_benchmark}/README.md | 0
.../benches/buffer_read_bench.rs | 0
.../benches/buffer_write_bench.rs | 0
.../benches/serialization_bench.rs | 0
.../{rust_benchmarks => rust_benchmark}/benchmark_report.py | 0
benchmarks/{rust_benchmarks => rust_benchmark}/build.rs | 0
.../{rust_benchmarks => rust_benchmark}/proto/complex.proto | 0
.../{rust_benchmarks => rust_benchmark}/proto/medium.proto | 0
.../{rust_benchmarks => rust_benchmark}/proto/realworld.proto | 0
.../{rust_benchmarks => rust_benchmark}/proto/simple.proto | 0
benchmarks/{rust_benchmarks => rust_benchmark}/src/lib.rs | 0
benchmarks/{rust_benchmarks => rust_benchmark}/src/main.rs | 0
.../{rust_benchmarks => rust_benchmark}/src/models/complex.rs | 0
.../{rust_benchmarks => rust_benchmark}/src/models/medium.rs | 0
.../{rust_benchmarks => rust_benchmark}/src/models/mod.rs | 0
.../src/models/realworld.rs | 0
.../{rust_benchmarks => rust_benchmark}/src/models/simple.rs | 0
.../src/serializers/fory.rs | 0
.../src/serializers/json.rs | 0
.../{rust_benchmarks => rust_benchmark}/src/serializers/mod.rs | 0
.../src/serializers/protobuf.rs | 0
docs/README.md | 10 ++++++++++
docs/benchmarks/rust/README.md | 2 +-
rust/README.md | 4 ++--
27 files changed, 15 insertions(+), 4 deletions(-)
diff --git a/AGENTS.md b/AGENTS.md
index e3af36933..b3d7d8fe8 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -162,6 +162,7 @@ cargo fmt --check
cargo doc --lib --no-deps --all-features
# Run benchmarks
+cd $project_dir/benchmarks/rust_benchmark
cargo bench
```
diff --git a/README.md b/README.md
index 083b6672b..578cca683 100644
--- a/README.md
+++ b/README.md
@@ -118,7 +118,7 @@ Fory Rust demonstrates competitive performance compared to
other Rust serializat
<img src="docs/benchmarks/rust/system_data.png" width="70%">
</p>
-For more detailed benchmarks and methodology, see [Rust
Benchmarks](rust/benches).
+For more detailed benchmarks and methodology, see [Rust
Benchmarks](benchmarks/rust_benchmark).
## Installation
diff --git a/benchmarks/rust_benchmarks/Cargo.toml
b/benchmarks/rust_benchmark/Cargo.toml
similarity index 100%
rename from benchmarks/rust_benchmarks/Cargo.toml
rename to benchmarks/rust_benchmark/Cargo.toml
diff --git a/benchmarks/rust_benchmarks/README.md
b/benchmarks/rust_benchmark/README.md
similarity index 100%
rename from benchmarks/rust_benchmarks/README.md
rename to benchmarks/rust_benchmark/README.md
diff --git a/benchmarks/rust_benchmarks/benches/buffer_read_bench.rs
b/benchmarks/rust_benchmark/benches/buffer_read_bench.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/benches/buffer_read_bench.rs
rename to benchmarks/rust_benchmark/benches/buffer_read_bench.rs
diff --git a/benchmarks/rust_benchmarks/benches/buffer_write_bench.rs
b/benchmarks/rust_benchmark/benches/buffer_write_bench.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/benches/buffer_write_bench.rs
rename to benchmarks/rust_benchmark/benches/buffer_write_bench.rs
diff --git a/benchmarks/rust_benchmarks/benches/serialization_bench.rs
b/benchmarks/rust_benchmark/benches/serialization_bench.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/benches/serialization_bench.rs
rename to benchmarks/rust_benchmark/benches/serialization_bench.rs
diff --git a/benchmarks/rust_benchmarks/benchmark_report.py
b/benchmarks/rust_benchmark/benchmark_report.py
similarity index 100%
rename from benchmarks/rust_benchmarks/benchmark_report.py
rename to benchmarks/rust_benchmark/benchmark_report.py
diff --git a/benchmarks/rust_benchmarks/build.rs
b/benchmarks/rust_benchmark/build.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/build.rs
rename to benchmarks/rust_benchmark/build.rs
diff --git a/benchmarks/rust_benchmarks/proto/complex.proto
b/benchmarks/rust_benchmark/proto/complex.proto
similarity index 100%
rename from benchmarks/rust_benchmarks/proto/complex.proto
rename to benchmarks/rust_benchmark/proto/complex.proto
diff --git a/benchmarks/rust_benchmarks/proto/medium.proto
b/benchmarks/rust_benchmark/proto/medium.proto
similarity index 100%
rename from benchmarks/rust_benchmarks/proto/medium.proto
rename to benchmarks/rust_benchmark/proto/medium.proto
diff --git a/benchmarks/rust_benchmarks/proto/realworld.proto
b/benchmarks/rust_benchmark/proto/realworld.proto
similarity index 100%
rename from benchmarks/rust_benchmarks/proto/realworld.proto
rename to benchmarks/rust_benchmark/proto/realworld.proto
diff --git a/benchmarks/rust_benchmarks/proto/simple.proto
b/benchmarks/rust_benchmark/proto/simple.proto
similarity index 100%
rename from benchmarks/rust_benchmarks/proto/simple.proto
rename to benchmarks/rust_benchmark/proto/simple.proto
diff --git a/benchmarks/rust_benchmarks/src/lib.rs
b/benchmarks/rust_benchmark/src/lib.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/lib.rs
rename to benchmarks/rust_benchmark/src/lib.rs
diff --git a/benchmarks/rust_benchmarks/src/main.rs
b/benchmarks/rust_benchmark/src/main.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/main.rs
rename to benchmarks/rust_benchmark/src/main.rs
diff --git a/benchmarks/rust_benchmarks/src/models/complex.rs
b/benchmarks/rust_benchmark/src/models/complex.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/models/complex.rs
rename to benchmarks/rust_benchmark/src/models/complex.rs
diff --git a/benchmarks/rust_benchmarks/src/models/medium.rs
b/benchmarks/rust_benchmark/src/models/medium.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/models/medium.rs
rename to benchmarks/rust_benchmark/src/models/medium.rs
diff --git a/benchmarks/rust_benchmarks/src/models/mod.rs
b/benchmarks/rust_benchmark/src/models/mod.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/models/mod.rs
rename to benchmarks/rust_benchmark/src/models/mod.rs
diff --git a/benchmarks/rust_benchmarks/src/models/realworld.rs
b/benchmarks/rust_benchmark/src/models/realworld.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/models/realworld.rs
rename to benchmarks/rust_benchmark/src/models/realworld.rs
diff --git a/benchmarks/rust_benchmarks/src/models/simple.rs
b/benchmarks/rust_benchmark/src/models/simple.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/models/simple.rs
rename to benchmarks/rust_benchmark/src/models/simple.rs
diff --git a/benchmarks/rust_benchmarks/src/serializers/fory.rs
b/benchmarks/rust_benchmark/src/serializers/fory.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/serializers/fory.rs
rename to benchmarks/rust_benchmark/src/serializers/fory.rs
diff --git a/benchmarks/rust_benchmarks/src/serializers/json.rs
b/benchmarks/rust_benchmark/src/serializers/json.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/serializers/json.rs
rename to benchmarks/rust_benchmark/src/serializers/json.rs
diff --git a/benchmarks/rust_benchmarks/src/serializers/mod.rs
b/benchmarks/rust_benchmark/src/serializers/mod.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/serializers/mod.rs
rename to benchmarks/rust_benchmark/src/serializers/mod.rs
diff --git a/benchmarks/rust_benchmarks/src/serializers/protobuf.rs
b/benchmarks/rust_benchmark/src/serializers/protobuf.rs
similarity index 100%
rename from benchmarks/rust_benchmarks/src/serializers/protobuf.rs
rename to benchmarks/rust_benchmark/src/serializers/protobuf.rs
diff --git a/docs/README.md b/docs/README.md
index 34a7b8041..4f80300eb 100644
--- a/docs/README.md
+++ b/docs/README.md
@@ -12,6 +12,16 @@
- For Java Object Graph Format, see [java serialization
spec](specification/java_serialization_spec.md) doc.
- For Row Format, see [row format spec](specification/row_format_spec.md) doc.
+## Benchmarks
+
+- Benchmark source code:
+ - Java: [Java Benchmarks Source](../java/benchmark)
+ - Python: [Python Benchmarks Source](../benchmarks/cpython_benchmark)
+ - Rust: [Rust Benchmarks Source](../benchmarks/rust_benchmark/)
+- Benchmark result:
+ - Java: [Java Benchmarks](benchmarks/)
+ - Rust: [Rust Benchmarks](benchmarks/rust_benchmark).
+
## Development
- For cpp debug, see [cpp debug](cpp_debug.md) doc.
diff --git a/docs/benchmarks/rust/README.md b/docs/benchmarks/rust/README.md
index 02f6ccbaf..9ea07ebd9 100644
--- a/docs/benchmarks/rust/README.md
+++ b/docs/benchmarks/rust/README.md
@@ -5,7 +5,7 @@ _Generated on 2025-10-26 18:36:41_
How to generate performance report:
```bash
-cd rust/benches
+cd benchmarks/rust_benchmark
cargo bench 2>&1 | tee cargo_bench.log
python benchmark_report.py --log-file cargo_bench.log
--output-dir=report_output
```
diff --git a/rust/README.md b/rust/README.md
index bbfa27c55..d1d069453 100644
--- a/rust/README.md
+++ b/rust/README.md
@@ -939,8 +939,8 @@ Apache Fory™ Rust is designed for maximum performance:
Run benchmarks:
```bash
-cd rust
-cargo bench --package fory-benchmarks
+cd benchmarks/rust_benchmark
+cargo bench
```
## 📖 Documentation
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]