]> gitweb @ CieloNegro.org - Rakka.git/blobdiff - Rakka/Storage.hs
code relocation
[Rakka.git] / Rakka / Storage.hs
index 56b42da0ae57f8668685f86d1cd9bca08ebe0f60..55037f03712294efac4ec84c9565b0e8aab62882 100644 (file)
@@ -10,6 +10,8 @@ module Rakka.Storage
     , putPageA
 
     , searchPages
+
+    , rebuildIndex
     )
     where
 
@@ -26,8 +28,6 @@ import           System.IO
 import           Subversion.Repository
 import           Text.HyperEstraier hiding (WriteLock)
 
-logger = "Rakka.Storage"
-
 
 mkStorage :: FilePath -> Repository -> (Page -> IO Document) -> IO Storage
 mkStorage lsdir repos mkDraft
@@ -65,6 +65,11 @@ searchPages sto cond
          atomically $ takeTMVar var
 
 
+rebuildIndex :: MonadIO m => Storage -> m ()
+rebuildIndex sto
+    = liftIO $ atomically $ writeTChan (stoIndexChan sto) RebuildIndex
+
+
 syncIndex :: Storage -> IO ()
 syncIndex sto
     = atomically $ writeTChan (stoIndexChan sto) SyncIndex