You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@opendal.apache.org by er...@apache.org on 2026/07/22 01:19:23 UTC

(opendal) 01/01: docs: correct layer behavior descriptions

This is an automated email from the ASF dual-hosted git repository.

erickguan pushed a commit to branch fix-reviewed-bugs
in repository https://gitbox.apache.org/repos/asf/opendal.git

commit b5ff158f1c28d40485acb1664e027c34e8ed1a2e
Author: Erick Guan <29...@users.noreply.github.com>
AuthorDate: Wed Jul 22 00:45:36 2026 +0800

    docs: correct layer behavior descriptions
---
 core/layers/capability-check/src/lib.rs | 8 ++++----
 core/layers/foyer/src/lib.rs            | 5 ++++-
 2 files changed, 8 insertions(+), 5 deletions(-)

diff --git a/core/layers/capability-check/src/lib.rs b/core/layers/capability-check/src/lib.rs
index fdc709809..f3b91cd7f 100644
--- a/core/layers/capability-check/src/lib.rs
+++ b/core/layers/capability-check/src/lib.rs
@@ -25,11 +25,11 @@ use std::sync::Arc;
 use opendal_core::raw::*;
 use opendal_core::*;
 
-/// Add an extra capability check layer for every operation
+/// Add extra capability checks for optional operation arguments.
 ///
-/// Similar to `CorrectnessChecker`, Before performing any operations, this layer will first verify
-/// its arguments against the capability of the underlying service. If the arguments is not supported,
-/// an error will be returned directly.
+/// Similar to `CorrectnessChecker`, this layer verifies selected optional arguments for write,
+/// copy, and list operations against the capabilities of the underlying service. If an argument is
+/// not supported, an error is returned directly.
 ///
 /// Notes
 ///
diff --git a/core/layers/foyer/src/lib.rs b/core/layers/foyer/src/lib.rs
index 9dbaf81ff..cd7f9d4fe 100644
--- a/core/layers/foyer/src/lib.rs
+++ b/core/layers/foyer/src/lib.rs
@@ -143,7 +143,10 @@ impl Code for FoyerValue {
 /// # Operation Behavior
 /// - `write`: [`FoyerLayer`] will write to the foyer hybrid cache after the service's write operation is completed.
 /// - `read`: [`FoyerLayer`] will first check the foyer hybrid cache for the data. If the data is not found, it will perform the read operation on the service and cache the result.
-/// - `delete`: [`FoyerLayer`] will remove the data from the foyer hybrid cache regardless of whether the service's delete operation is successful.
+/// - `delete`: [`FoyerLayer`] will remove successfully deleted data from the foyer hybrid cache
+///   when the deleter is closed. A failed delete is not invalidated. Cache invalidation happens
+///   before the underlying deleter is closed, so the data remains invalidated if closing the
+///   deleter fails.
 /// - Other operations: [`FoyerLayer`] will not cache the results of other operations, such as `list`, `copy`, `rename`, etc. They will be passed through to the underlying service without caching.
 ///
 /// # Examples