Skip to content

Commit 0a74c23

Browse files
committed
chore: update docs
1 parent fda57ec commit 0a74c23

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Pyroscope Profiler Agent for continuous profiling of Rust, Python and Ruby appli
55
"""
66
keywords = ["pyroscope", "profiler", "profiling", "pprof"]
77
authors = ["Abid Omar <[email protected]>"]
8-
version = "0.5.0"
8+
version = "0.5.1"
99
edition = "2021"
1010
license = "Apache-2.0"
1111
homepage = "https://pyroscope.io/docs/rust"

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,19 +36,19 @@ pyroscope = "0.5.0"
3636
pyroscope-pprofrs = "0.2"
3737
```
3838

39-
Configure and create the backend (pprof-rs)
39+
Include Pyroscope and pprof-rs dependencies:
4040

4141
```rust
42-
let pprof_config = PprofConfig::new().sample_rate(100);
43-
let pprof_backend = Pprof::new(pprof_config);
42+
use pyroscope::PyroscopeAgent;
43+
use pyroscope_pprofrs::{pprof_backend, PprofConfig};
4444
```
4545

4646
Configure the Pyroscope agent:
4747

4848
```rust
4949
let agent =
5050
PyroscopeAgent::builder("http://localhost:4040", "myapp-profile")
51-
.backend(pprof_backend)
51+
.backend(pprof_backend(PprofConfig::new().sample_rate(100)))
5252
.build()?;
5353
```
5454

0 commit comments

Comments
 (0)