[
https://issues.apache.org/jira/browse/CASSANDRA-17021?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18028426#comment-18028426
]
Jon Haddad commented on CASSANDRA-17021:
----------------------------------------
I wrote some data to a table last night, today I tried to compact it (trying to
figure out a different issue) and discovered this:
{noformat}
WARN [CompactionExecutor:869] 2025-10-08T17:16:05,033 SSTableWriter.java:157 -
Failed to open
/Users/jhaddad/dev/cassandra/bin/../data/data/chunk4_2/keyvalue-1b255f4def2540a600000000000000f6/pa-2-big
for writing
java.lang.IllegalStateException: Dictionary is being closed
at
org.apache.cassandra.io.compress.ZstdDictionaryCompressor.lambda$getOrCreate$1(ZstdDictionaryCompressor.java:100)
at
com.github.benmanes.caffeine.cache.BoundedLocalCache.lambda$doComputeIfAbsent$14(BoundedLocalCache.java:2688)
at
java.base/java.util.concurrent.ConcurrentHashMap.compute(ConcurrentHashMap.java:1955)
at
com.github.benmanes.caffeine.cache.BoundedLocalCache.doComputeIfAbsent(BoundedLocalCache.java:2686)
at
com.github.benmanes.caffeine.cache.BoundedLocalCache.computeIfAbsent(BoundedLocalCache.java:2669)
at
com.github.benmanes.caffeine.cache.LocalCache.computeIfAbsent(LocalCache.java:112)
at
com.github.benmanes.caffeine.cache.LocalManualCache.get(LocalManualCache.java:62)
at
org.apache.cassandra.io.compress.ZstdDictionaryCompressor.getOrCreate(ZstdDictionaryCompressor.java:94)
at
org.apache.cassandra.io.compress.ZstdDictionaryCompressor.getOrCopyWithDictionary(ZstdDictionaryCompressor.java:121)
at
org.apache.cassandra.io.compress.ZstdDictionaryCompressor.getOrCopyWithDictionary(ZstdDictionaryCompressor.java:42)
at
org.apache.cassandra.io.compress.CompressedSequentialWriter.<init>(CompressedSequentialWriter.java:129)
at
org.apache.cassandra.io.sstable.format.DataComponent.buildWriter(DataComponent.java:51)
at
org.apache.cassandra.io.sstable.format.big.BigTableWriter$Builder.openDataWriter(BigTableWriter.java:387)
at
org.apache.cassandra.io.sstable.format.SortedTableWriter.<init>(SortedTableWriter.java:102)
at
org.apache.cassandra.io.sstable.format.big.BigTableWriter.<init>(BigTableWriter.java:78)
at
org.apache.cassandra.io.sstable.format.big.BigTableWriter$Builder.buildInternal(BigTableWriter.java:440)
at
org.apache.cassandra.io.sstable.format.big.BigTableWriter$Builder.buildInternal(BigTableWriter.java:346)
at
org.apache.cassandra.io.sstable.format.SSTableWriter$Builder.build(SSTableWriter.java:582)
at
org.apache.cassandra.db.compaction.writers.CompactionAwareWriter.sstableWriter(CompactionAwareWriter.java:246)
at
org.apache.cassandra.db.compaction.writers.CompactionAwareWriter.switchCompactionWriter(CompactionAwareWriter.java:233)
at
org.apache.cassandra.db.compaction.writers.CompactionAwareWriter.maybeSwitchLocation(CompactionAwareWriter.java:212)
at
org.apache.cassandra.db.compaction.writers.CompactionAwareWriter.maybeSwitchWriter(CompactionAwareWriter.java:178)
at
org.apache.cassandra.db.compaction.writers.CompactionAwareWriter.append(CompactionAwareWriter.java:150)
at
org.apache.cassandra.db.compaction.CompactionTask.runMayThrow(CompactionTask.java:270)
at org.apache.cassandra.utils.WrappedRunnable.run(WrappedRunnable.java:26)
at
org.apache.cassandra.db.compaction.CompactionTask.executeInternal(CompactionTask.java:99)
at
org.apache.cassandra.db.compaction.AbstractCompactionTask.execute(AbstractCompactionTask.java:110)
at
org.apache.cassandra.db.compaction.CompactionManager$9.runMayThrow(CompactionManager.java:1181)
at org.apache.cassandra.utils.WrappedRunnable.run(WrappedRunnable.java:26)
at org.apache.cassandra.concurrent.FutureTask$3.call(FutureTask.java:141)
at org.apache.cassandra.concurrent.FutureTask.call(FutureTask.java:61)
at org.apache.cassandra.concurrent.FutureTask.run(FutureTask.java:71)
at
java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at
java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at
io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
at java.base/java.lang.Thread.run(Thread.java:840){noformat}
I remember I had changed compression strategies on the table back and forth a
few times, tried to run upgradesstables and compact, but I'm not sure what
order I did them. I'll try to reproduce. I wonder if this is something Harry
can help with?
> Enhance Zstd support in Cassandra with dictionaries
> ---------------------------------------------------
>
> Key: CASSANDRA-17021
> URL: https://issues.apache.org/jira/browse/CASSANDRA-17021
> Project: Apache Cassandra
> Issue Type: Improvement
> Components: Feature/Compression
> Reporter: Dinesh Joshi
> Assignee: Yifan Cai
> Priority: Normal
> Time Spent: 2h 50m
> Remaining Estimate: 0h
>
> Currently Cassandra supports zstd compression. However, Zstd also supports
> dictionaries to enhance not only the compression ratio but also the speed.
> Dictionaries can show 3-4x savings. We should add support to train
> dictionaries, ideally per SSTable this will yield the maximum gains.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]