Skip to content

Commit 18d4867

Browse files
committed
refactor: remove defaultBloomFilterAlloc and defaultMergeSchedule
1 parent 8ea9048 commit 18d4867

File tree

2 files changed

+1
-13
lines changed

2 files changed

+1
-13
lines changed

bench/macro/lsm-tree-bench-wp8.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ cmdP = O.subparser $ mconcat
227227

228228
setupOptsP :: O.Parser SetupOpts
229229
setupOptsP = pure SetupOpts
230-
<*> O.option O.auto (O.long "bloom-filter-alloc" <> O.value LSM.defaultBloomFilterAlloc <> O.showDefault <> O.help "Bloom filter allocation method [AllocFixed n | AllocRequestFPR d]")
230+
<*> O.option O.auto (O.long "bloom-filter-alloc" <> O.value (LSM.confBloomFilterAlloc LSM.defaultTableConfig) <> O.showDefault <> O.help "Bloom filter allocation method [AllocFixed n | AllocRequestFPR d]")
231231

232232
runOptsP :: O.Parser RunOpts
233233
runOptsP = pure RunOpts

src/Database/LSMTree/Internal/Config.hs

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ module Database.LSMTree.Internal.Config (
1616
, WriteBufferAlloc (..)
1717
-- * Bloom filter allocation
1818
, BloomFilterAlloc (..)
19-
, defaultBloomFilterAlloc
2019
, bloomFilterAllocForLevel
2120
-- * Fence pointer index
2221
, FencePointerIndexType (..)
@@ -27,7 +26,6 @@ module Database.LSMTree.Internal.Config (
2726
, diskCachePolicyForLevel
2827
-- * Merge schedule
2928
, MergeSchedule (..)
30-
, defaultMergeSchedule
3129
) where
3230

3331
import Control.DeepSeq (NFData (..))
@@ -183,9 +181,6 @@ instance NFData BloomFilterAlloc where
183181
rnf (AllocFixed n) = rnf n
184182
rnf (AllocRequestFPR fpr) = rnf fpr
185183

186-
defaultBloomFilterAlloc :: BloomFilterAlloc
187-
defaultBloomFilterAlloc = confBloomFilterAlloc defaultTableConfig
188-
189184
bloomFilterAllocForLevel :: TableConfig -> RunLevelNo -> RunBloomFilterAlloc
190185
bloomFilterAllocForLevel conf _levelNo =
191186
case confBloomFilterAlloc conf of
@@ -327,10 +322,3 @@ data MergeSchedule =
327322
instance NFData MergeSchedule where
328323
rnf OneShot = ()
329324
rnf Incremental = ()
330-
331-
-- | The default 'MergeSchedule'.
332-
--
333-
-- >>> defaultMergeSchedule
334-
-- Incremental
335-
defaultMergeSchedule :: MergeSchedule
336-
defaultMergeSchedule = confMergeSchedule defaultTableConfig

0 commit comments

Comments
 (0)