Skip to content

Commit

Permalink
Hide documentation for advanced memory management
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Haudum <christian.haudum@gmail.com>
  • Loading branch information
chaudum committed Jun 3, 2024
1 parent b7c1f97 commit 3cae039
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 13 deletions.
12 changes: 0 additions & 12 deletions docs/sources/shared/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -5389,18 +5389,6 @@ bloom_shipper:
# cache before they get purged.
# CLI flag: -bloom.metas-lru-cache.ttl
[ttl: <duration> | default = 1h]

memory_management:
# One of: simple (simple heap allocations using Go's make([]byte, n) and no
# re-cycling of buffers), dynamic (a buffer pool with variable sized buckets
# and best effort re-cycling of buffers using Go's sync.Pool), fixed (a
# fixed size memory pool with configurable slab sizes, see mem-pool-buckets)
# CLI flag: -bloom.memory-management.alloc-type
[bloom_page_alloc_type: <string> | default = "dynamic"]

# Comma separated list of buckets in the format {size}x{bytes}
# CLI flag: -bloom.memory-management.mem-pool-buckets
[bloom_page_mem_pool_buckets: <list of Buckets> | default = 128x64KB,512x2MB,128x8MB,32x32MB,8x128MB]
```
### swift_storage_config
Expand Down
3 changes: 2 additions & 1 deletion pkg/storage/stores/shipper/bloomshipper/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ type Config struct {
BlocksCache BlocksCacheConfig `yaml:"blocks_cache"`
MetasCache cache.Config `yaml:"metas_cache"`
MetasLRUCache cache.EmbeddedCacheConfig `yaml:"metas_lru_cache"`
MemoryManagement MemoryManagementConfig `yaml:"memory_management"`
MemoryManagement MemoryManagementConfig `yaml:"memory_management" doc:"hidden"`

// This will always be set to true when flags are registered.
// In tests, where config is created as literal, it can be set manually.
Expand Down Expand Up @@ -93,6 +93,7 @@ func (cfg *BlocksCacheConfig) Validate() error {
}

var (
// the default that describes a 4GiB memory pool
defaultMemPoolBuckets = mempool.Buckets{
{Size: 128, Capacity: 64 << 10}, // 8MiB -- for tests
{Size: 512, Capacity: 2 << 20}, // 1024MiB
Expand Down

0 comments on commit 3cae039

Please sign in to comment.