Commit eb61dae3 authored by Alexandre Delanoë's avatar Alexandre Delanoë

[FIX] memory leak, useable ngrams table version (WIP)

parent 753a9b03
Pipeline #1270 failed with stage
...@@ -414,6 +414,7 @@ tableNgramsPostChartsAsync utn logStatus = do ...@@ -414,6 +414,7 @@ tableNgramsPostChartsAsync utn logStatus = do
-- printDebug "[tableNgramsPut] Terms, updating Metrics (Histo), cId" cId -- printDebug "[tableNgramsPut] Terms, updating Metrics (Histo), cId" cId
(logRef, logRefSuccess, getRef) <- runJobLog 6 logStatus (logRef, logRefSuccess, getRef) <- runJobLog 6 logStatus
logRef logRef
{-
_ <- Metrics.updateChart cId (Just listId) tabType Nothing _ <- Metrics.updateChart cId (Just listId) tabType Nothing
logRefSuccess logRefSuccess
_ <- Metrics.updatePie cId (Just listId) tabType Nothing _ <- Metrics.updatePie cId (Just listId) tabType Nothing
...@@ -425,6 +426,7 @@ tableNgramsPostChartsAsync utn logStatus = do ...@@ -425,6 +426,7 @@ tableNgramsPostChartsAsync utn logStatus = do
_ <- Metrics.updateTree cId (Just listId) tabType CandidateTerm _ <- Metrics.updateTree cId (Just listId) tabType CandidateTerm
logRefSuccess logRefSuccess
_ <- Metrics.updateTree cId (Just listId) tabType MapTerm _ <- Metrics.updateTree cId (Just listId) tabType MapTerm
-}
logRefSuccess logRefSuccess
getRef getRef
......
...@@ -48,6 +48,8 @@ runJobLog num logStatus = do ...@@ -48,6 +48,8 @@ runJobLog num logStatus = do
logStatus jl logStatus jl
logRefSuccessF ref = do logRefSuccessF ref = do
jl <- liftBase $ readIORef ref jl <- liftBase $ readIORef ref
liftBase $ writeIORef ref $ jobLogSuccess jl let jl' = jobLogSuccess jl
liftBase $ writeIORef ref jl'
logStatus jl'
getRefF ref = do getRefF ref = do
liftBase $ readIORef ref liftBase $ readIORef ref
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment