-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[global cache] Draft e2e implementation
- Loading branch information
1 parent
50c0277
commit 813cb54
Showing
42 changed files
with
677 additions
and
224 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
[package] | ||
name = "aptos-global-cache-manager" | ||
description = "Aptos global module and environement cache manager" | ||
version = "0.0.1" | ||
|
||
# Workspace inherited keys | ||
authors = { workspace = true } | ||
edition = { workspace = true } | ||
homepage = { workspace = true } | ||
license = { workspace = true } | ||
publish = { workspace = true } | ||
repository = { workspace = true } | ||
rust-version = { workspace = true } | ||
|
||
[dependencies] | ||
aptos-crypto = { workspace = true } | ||
aptos-types = { workspace = true } | ||
aptos-vm-environment = { workspace = true } | ||
parking_lot = { workspace = true } | ||
move-binary-format = { workspace = true } | ||
move-core-types = { workspace = true } | ||
move-vm-runtime = { workspace = true } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
// Copyright © Aptos Foundation | ||
// SPDX-License-Identifier: Apache-2.0 | ||
|
||
/// Configuration used for global caches. | ||
pub struct GlobalCacheConfig { | ||
/// The maximum size of module cache. If module cache exceeds this capacity, it should be | ||
/// flushed. | ||
pub module_cache_capacity: usize, | ||
/// The maximum size of struct name re-indexing map stored in runtime environment. | ||
pub struct_name_index_map_capacity: usize, | ||
} | ||
|
||
impl Default for GlobalCacheConfig { | ||
fn default() -> Self { | ||
Self { | ||
module_cache_capacity: 100_000, | ||
struct_name_index_map_capacity: 100_000, | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
// Copyright © Aptos Foundation | ||
// SPDX-License-Identifier: Apache-2.0 | ||
|
||
pub(crate) mod config; | ||
mod manager; | ||
|
||
pub use manager::GlobalCacheManager; |
Oops, something went wrong.