Skip to content

Commit fd3f9a2

Browse files
committed
Remove more logs
1 parent cafc1b8 commit fd3f9a2

File tree

2 files changed

+4
-9
lines changed

2 files changed

+4
-9
lines changed

bin/BedrockWorkerManager.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,6 @@
323323
$workerName = explode('/', $job['name'])[1];
324324
$workerFilename = $workerPath."/$workerName.php";
325325
$stats->timer('bedrockJob.lateBy.'.$job['name'], (time() - strtotime($job['nextRun'])) * 1000);
326-
$logger->info("Looking for worker '$workerFilename'");
327326
if (file_exists($workerFilename)) {
328327
// The file seems to exist -- fork it so we can run it.
329328
//
@@ -355,9 +354,7 @@
355354
$safeJobName = SQLite3::escapeString($job['name']);
356355
$safeRetryAfter = SQLite3::escapeString($job['retryAfter'] ?? '');
357356
$jobStartTime = microtime(true);
358-
$stats->benchmark('bedrockWorkerManager.db.write.insert', function () use ($localDB, $job, $safeJobName, $safeRetryAfter, $jobStartTime, $myPid) {
359-
$localDB->write("INSERT INTO localJobs (jobID, jobName, started, workerPID, retryAfter) VALUES ({$job['jobID']}, '$safeJobName', '$jobStartTime', $myPid, '$safeRetryAfter');");
360-
});
357+
$localDB->write("INSERT INTO localJobs (jobID, jobName, started, workerPID, retryAfter) VALUES ({$job['jobID']}, '$safeJobName', '$jobStartTime', $myPid, '$safeRetryAfter');");
361358
$localJobID = $localDB->getLastInsertedRowID();
362359
}
363360

src/LocalDB.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,9 @@ public function __construct(string $location, LoggerInterface $logger, $stats)
4343
public function open()
4444
{
4545
if (!isset($this->handle)) {
46-
$this->stats->benchmark('bedrockWorkerManager.db.open', function () {
47-
$this->handle = new SQLite3($this->location);
48-
$this->handle->busyTimeout(15000);
49-
$this->handle->enableExceptions(true);
50-
});
46+
$this->handle = new SQLite3($this->location);
47+
$this->handle->busyTimeout(15000);
48+
$this->handle->enableExceptions(true);
5149
}
5250
}
5351

0 commit comments

Comments
 (0)