#harmony-os #open-harmony #tracing

hitrace

Safe bindings to the HiTrace tracing system of OpenHarmony

5 releases

0.1.4 Apr 20, 2024
0.1.3 Apr 19, 2024
0.1.2 Apr 19, 2024
0.1.1 Apr 19, 2024
0.1.0 Apr 19, 2024

#12 in #harmony-os

Download history 361/week @ 2024-11-30 455/week @ 2024-12-07 520/week @ 2024-12-14 349/week @ 2024-12-21 218/week @ 2024-12-28 597/week @ 2025-01-04 477/week @ 2025-01-11 636/week @ 2025-01-18 509/week @ 2025-01-25 770/week @ 2025-02-01 553/week @ 2025-02-08 630/week @ 2025-02-15 969/week @ 2025-02-22 867/week @ 2025-03-01 610/week @ 2025-03-08 437/week @ 2025-03-15

3,049 downloads per month

Apache-2.0

6KB
63 lines

HiTrace

Safe bindings for the HiTrace tracing system on OpenHarmony. This crate does nothing if not compiled for OpenHarmony (target_env = ohos).

Development

Contributions are welcome.

License

This project is licensed under the Apache-2.0 license, matching the license of OpenHarmony. See LICENSE for details.


lib.rs:

HiTrace

Safe bindings for the HiTrace tracing system on OpenHarmony. This crate does nothing if not compiled for OpenHarmony (target_env = ohos).

Usage

HiTrace allows tracing Spans in a synchronous and stack based fashion.

Examples

fn load_website() {
    start_trace(&c"step1");
    step1();
    finish_trace();
    start_trace(&CString::new("step2").unwrap());
    step2();
    finish_trace();
}
start_trace(&c"LoadingWebsite");
load_website();
finish_trace();

Dependencies