mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-05-25 17:30:41 +00:00
chore: introduce user cache invalidation api (#8129)
* chore: introduce user cache invalidation api Signed-off-by: shuiyisong <xixing.sys@gmail.com> * chore: update using plugins hook Signed-off-by: shuiyisong <xixing.sys@gmail.com> --------- Signed-off-by: shuiyisong <xixing.sys@gmail.com>
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
|
||||
use auth::{DefaultPermissionChecker, PermissionCheckerRef, UserProviderRef};
|
||||
use common_base::Plugins;
|
||||
use common_meta::cache::CacheRegistryBuilder;
|
||||
use frontend::error::{IllegalAuthConfigSnafu, Result};
|
||||
use frontend::frontend::FrontendOptions;
|
||||
use snafu::ResultExt;
|
||||
@@ -54,6 +55,11 @@ pub async fn start_frontend_plugins(_plugins: Plugins) -> Result<()> {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
/// Allows frontend plugins to add cache invalidators to the layered registry.
|
||||
pub fn configure_cache_registry(_plugins: &Plugins) -> Option<CacheRegistryBuilder> {
|
||||
None
|
||||
}
|
||||
|
||||
pub mod context {
|
||||
use std::sync::Arc;
|
||||
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
// limitations under the License.
|
||||
|
||||
use common_base::Plugins;
|
||||
use common_meta::cache::CacheRegistryBuilder;
|
||||
use common_meta::kv_backend::KvBackendRef;
|
||||
use standalone::error::Result;
|
||||
use standalone::options::StandaloneOptions;
|
||||
@@ -34,6 +35,11 @@ pub async fn start_standalone_plugins(_plugins: Plugins) -> Result<()> {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
/// Allows standalone plugins to add cache invalidators to the layered registry.
|
||||
pub fn configure_cache_registry(_plugins: &Plugins) -> Option<CacheRegistryBuilder> {
|
||||
None
|
||||
}
|
||||
|
||||
pub mod context {
|
||||
use std::sync::Arc;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user