Skip to content

Commit

Permalink
DFS: Cache gen. timeout check only when needed (ezsystems#1436)
Browse files Browse the repository at this point in the history
Only check cache generation timeout when generation has actually started. Avoids SQL error.
  • Loading branch information
glye authored Jul 12, 2019
1 parent a8d24e4 commit 98b8f48
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1371,6 +1371,12 @@ public function abortCacheGeneration()
*/
public function checkCacheGenerationTimeout()
{
if ( $this->generationStartTimestamp === false )
{
eZDebug::writeError( "Cache generation has not started, cannot check timeout", 'cluster.log' );
return true;
}

eZDebugSetting::writeDebug( 'kernel-clustering', 'Checking cache generation timeout', "dfs::checkCacheGenerationTimeout( '{$this->filePath}' )" );
return self::$dbbackend->_checkCacheGenerationTimeout( $this->filePath, $this->generationStartTimestamp );
}
Expand Down

0 comments on commit 98b8f48

Please sign in to comment.