Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix gc tool never compacts keys with hash-prefix #5277

Merged
merged 1 commit into from
Nov 5, 2024

Conversation

polyrabbit
Copy link
Contributor

GC tool hard-coded chunk.Config fields with:

chunkConf := chunk.Config{
	BlockSize:  format.BlockSize * 1024,
	Compress:   format.Compression,
	GetTimeout: time.Second * 60,
	PutTimeout: time.Second * 60,
	MaxUpload:  20,
	BufferSize: 300 << 20,
	CacheDir:   "memory",
}

This is error-prone - it may miss some fields from format added in the future. One such case is HashPrefix, where user sets it in the format but the gc tool doesnot pass it to chunkConf, which causes the compact sub-command never works.

@davies davies merged commit da1c8b6 into juicedata:main Nov 5, 2024
39 checks passed
jiefenghuang pushed a commit that referenced this pull request Nov 26, 2024
jiefenghuang pushed a commit that referenced this pull request Nov 26, 2024
@polyrabbit polyrabbit deleted the gc-hash-prefix branch December 4, 2024 07:05
@zhoucheng361 zhoucheng361 added missed missed bug priority/high The highest priority module/gc&fsck gc&fsck labels Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants