feat: Implement ETag-based conditional caching for API and HTML, add immutable caching for images, and introduce concurrency control with resizing for picture syncing.
This commit is contained in:
@@ -61,12 +61,11 @@ class CategorySyncer extends EventEmitter {
|
||||
try {
|
||||
await this._syncFromDb();
|
||||
const duration = Date.now() - startTime;
|
||||
console.log(`✅ Sync completed successfully in ${duration}ms.`);
|
||||
|
||||
// Log next sync time
|
||||
// Log completion and next sync time
|
||||
const syncInterval = parseInt(process.env.SYNC_INTERVAL_MS) || 60000;
|
||||
const minutes = Math.round(syncInterval / 60000);
|
||||
console.log(`⏰ Next sync in ${minutes} minute${minutes !== 1 ? 's' : ''}`);
|
||||
console.log(`✅ Sync completed in ${duration}ms. Next sync in ${minutes} minute${minutes !== 1 ? 's' : ''}`);
|
||||
} catch (err) {
|
||||
console.error('❌ Sync failed:', err);
|
||||
} finally {
|
||||
|
||||
Reference in New Issue
Block a user