Browse Source

docs(aya-log): reword rustdocs a bit

Alessandro Decina 10 months ago
parent
commit
8830c0bc20
1 changed files with 8 additions and 10 deletions
  1. 8 10
      aya-log/src/lib.rs

+ 8 - 10
aya-log/src/lib.rs

@@ -119,20 +119,18 @@ impl EbpfLogger {
         Ok(EbpfLogger {})
     }
 
-    /// Attaches to an existing `aya-log-ebpf` log created by a running ebpf
-    /// program identified by `program_id`. The log records will be written
-    /// to the default logger. See [log::logger].
-    /// It can be used to review the log for a pinned program after the user
-    /// application exits.
+    /// Attaches to an existing `aya-log-ebpf` instance.
+    ///
+    /// Attaches to the logs produced by `program_id`. Can be used to read logs generated by a
+    /// pinned program. The log records will be written to the default logger. See [log::logger].
     pub fn init_from_id(program_id: u32) -> Result<EbpfLogger, Error> {
         Self::init_from_id_with_logger(program_id, log::logger())
     }
 
-    /// Attaches to an existing `aya-log-ebpf` log created by a running ebpf
-    /// program identified by `program_id`. The log records will be written
-    /// to the user provided logger.
-    /// It can be used to review the log for a pinned program after the user
-    /// application exits.
+    /// Attaches to an existing `aya-log-ebpf` instance and logs with the given logger.
+    ///
+    /// Attaches to the logs produced by `program_id`. Can be used to read logs generated by a
+    /// pinned program. The log records will be written to the given logger.
     pub fn init_from_id_with_logger<T: Log + 'static>(
         program_id: u32,
         logger: T,