]> git.openstreetmap.org Git - nominatim.git/commitdiff
dont include polling time for batch duration for non-minutely updates, log name of...
authorIrlJidel <donal.diamond@gmail.com>
Wed, 2 Oct 2013 09:53:21 +0000 (10:53 +0100)
committerIrlJidel <donal.diamond@gmail.com>
Wed, 2 Oct 2013 09:53:21 +0000 (10:53 +0100)
utils/update.php

index 7fa8e73c94d5be020f8b53b8ccd5799de530a719..42a7b59e9c2a673243fd472281d6cebd29cf70dc 100755 (executable)
                                                // There are new replication files - use osmosis to download the file
                                                echo "\n".date('Y-m-d H:i:s')." Replication Delay is ".$aReplicationLag[0]."\n";
                                        }
+                                       $fStartTime = time();
                                        $fCMDStartTime = time();
                                        echo $sCMDDownload."\n";
                                        exec($sCMDDownload, $sJunk, $iErrorLevel);
                                        $sSQL = "INSERT INTO import_osmosis_log values ('$sBatchEnd',$iFileSize,'".date('Y-m-d H:i:s',$fCMDStartTime)."','".date('Y-m-d H:i:s')."','osmosis')";
                                        var_Dump($sSQL);
                                        $oDB->query($sSQL);
-                                       echo date('Y-m-d H:i:s')." Completed for $sBatchEnd in ".round((time()-$fCMDStartTime)/60,2)." minutes\n";
+                                       echo date('Y-m-d H:i:s')." Completed osmosis step for $sBatchEnd in ".round((time()-$fCMDStartTime)/60,2)." minutes\n";
                                }
 
                                $iFileSize = filesize($sImportFile);
                                        echo "Error: $iErrorLevel\n";
                                        exit($iErrorLevel);
                                }
-                               echo date('Y-m-d H:i:s')." Completed for $sBatchEnd in ".round((time()-$fCMDStartTime)/60,2)." minutes\n";
                                $sSQL = "INSERT INTO import_osmosis_log values ('$sBatchEnd',$iFileSize,'".date('Y-m-d H:i:s',$fCMDStartTime)."','".date('Y-m-d H:i:s')."','osm2pgsql')";
                                var_Dump($sSQL);
                                $oDB->query($sSQL);
-                               echo date('Y-m-d H:i:s')." Completed for $sBatchEnd in ".round((time()-$fCMDStartTime)/60,2)." minutes\n";
+                               echo date('Y-m-d H:i:s')." Completed osm2pgsql step for $sBatchEnd in ".round((time()-$fCMDStartTime)/60,2)." minutes\n";
 
                                // Archive for debug?
                                unlink($sImportFile);
                        $sSQL = "INSERT INTO import_osmosis_log values ('$sBatchEnd',$iFileSize,'".date('Y-m-d H:i:s',$fCMDStartTime)."','".date('Y-m-d H:i:s')."','index')";
                        var_Dump($sSQL);
                        $oDB->query($sSQL);
-                       echo date('Y-m-d H:i:s')." Completed for $sBatchEnd in ".round((time()-$fCMDStartTime)/60,2)." minutes\n";
+                       echo date('Y-m-d H:i:s')." Completed index step for $sBatchEnd in ".round((time()-$fCMDStartTime)/60,2)." minutes\n";
 
                        $sSQL = "update import_status set lastimportdate = '$sBatchEnd'";
                        $oDB->query($sSQL);
 
                        $fDuration = time() - $fStartTime;
-                       echo date('Y-m-d H:i:s')." Completed for $sBatchEnd in ".round($fDuration/60,2)."\n";
+                       echo date('Y-m-d H:i:s')." Completed all for $sBatchEnd in ".round($fDuration/60,2)." minutes\n";
                        if (!$aResult['import-osmosis-all']) exit;
 
                        if ( CONST_Replication_Update_Interval > 60 )