Created
June 29, 2021 04:54
-
-
Save karan9/a4d76c1c04e8f9eba92337bcfabc2314 to your computer and use it in GitHub Desktop.
Create a collection with zstd compression
This file contains hidden or 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
// Create a ZSTD Collection | |
db.createCollection("COLLNAME", {storageEngine: {wiredTiger: {configString: "block_compressor=zstd"}}}) | |
// Check which block compressor is being used for a collection | |
var wt_options = db.zlogs.stats().wiredTiger.creationString.split(',') | |
// filter the options | |
wt_options.filter((wt_options) => wt_options.startsWith('block_compressor')) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment