Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/service-core/src/api/diagnostics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -149,15 +149,15 @@ export async function getSyncRulesStatus(
);
const lagSeconds = Math.round((Date.now() - lastTime) / 1000);
// On idle instances, keepalive messages are only persisted every 60 seconds.
// So we use 2 minutes as a threshold for warnings, and 15 minutes for critical.
// So we use 5 minutes as a threshold for warnings, and 15 minutes for critical.
// The replication lag metric should give a more granular value, but that is not available directly
// in the API containers used for diagnostics, and this should give a good enough indication.
if (lagSeconds > 15 * 60) {
errors.push({
level: 'fatal',
message: `No replicated commit in more than ${lagSeconds}s`
});
} else if (lagSeconds > 120) {
} else if (lagSeconds > 5 * 60) {
errors.push({
level: 'warning',
message: `No replicated commit in more than ${lagSeconds}s`
Expand Down