Skip to content

Commit 0bdee99

Browse files
committed
better logs
1 parent d583da7 commit 0bdee99

File tree

2 files changed

+23
-14
lines changed

2 files changed

+23
-14
lines changed

maintnotifications/e2e/notiftracker_test.go

Lines changed: 22 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -378,18 +378,27 @@ func (da *DiagnosticsAnalysis) Analyze() {
378378
}
379379

380380
func (a *DiagnosticsAnalysis) Print(t *testing.T) {
381-
t.Logf("Diagnostics Analysis results for %d events and %d connections:", len(a.diagnosticsLog), len(a.connIds))
382-
t.Logf("Connections: %v", a.connIds)
383-
t.Logf("Relaxed Timeout Count: %d", a.RelaxedTimeoutCount)
384-
t.Logf("Unrelaxed Timeout Count: %d", a.UnrelaxedTimeoutCount)
385-
t.Logf("Notification Processing Errors: %d", a.NotificationProcessingErrors)
386-
t.Logf("Connection Count: %d", a.ConnectionCount)
387-
t.Logf("Moving Count: %d", a.MovingCount)
388-
t.Logf("Migrating Count: %d", a.MigratingCount)
389-
t.Logf("Migrated Count: %d", a.MigratedCount)
390-
t.Logf("Failing Over Count: %d", a.FailingOverCount)
391-
t.Logf("Failed Over Count: %d", a.FailedOverCount)
392-
t.Logf("Unexpected Notification Count: %d", a.UnexpectedNotificationCount)
393-
t.Logf("Total Notifications: %d", a.TotalNotifications)
381+
t.Logf("Notification Analysis results for %d events and %d connections:", len(a.diagnosticsLog), len(a.connIds))
382+
t.Logf("-------------")
383+
t.Logf("-Timeout Analysis based on type of notification-")
384+
t.Logf("Note: MIGRATED and FAILED_OVER notifications are not tracked by the hook, so they are not included in the relaxed/unrelaxed count")
385+
t.Logf("Note: The hook only tracks timeouts that occur after the notification is processed, so timeouts that occur during processing are not included")
386+
t.Logf("-------------")
387+
t.Logf(" - Relaxed Timeout Count: %d", a.RelaxedTimeoutCount)
388+
t.Logf(" - Unrelaxed Timeout Count: %d", a.UnrelaxedTimeoutCount)
389+
t.Logf("-------------")
390+
t.Logf("-Notification Analysis-")
391+
t.Logf("-------------")
392+
t.Logf(" - MOVING: %d", a.MovingCount)
393+
t.Logf(" - MIGRATING: %d", a.MigratingCount)
394+
t.Logf(" - MIGRATED: %d", a.MigratedCount)
395+
t.Logf(" - FAILING_OVER: %d", a.FailingOverCount)
396+
t.Logf(" - FAILED_OVER: %d", a.FailedOverCount)
397+
t.Logf(" - Unexpected: %d", a.UnexpectedNotificationCount)
398+
t.Logf("-------------")
399+
t.Logf(" - Total Notifications: %d", a.TotalNotifications)
400+
t.Logf(" - Notification Processing Errors: %d", a.NotificationProcessingErrors)
401+
t.Logf(" - Connection Count: %d", a.ConnectionCount)
402+
t.Logf("-------------")
394403
t.Logf("Diagnostics Analysis completed successfully")
395404
}

maintnotifications/e2e/scenario_endpoint_types_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ func TestEndpointTypesPushNotifications(t *testing.T) {
283283
p("Bind action completed for %s: %s", endpointTest.name, bindStatus.Status)
284284

285285
// Continue traffic for analysis
286-
time.Sleep(5 * time.Second)
286+
time.Sleep(30 * time.Second)
287287
commandsRunner.Stop()
288288

289289
// Analyze results for this endpoint type

0 commit comments

Comments
 (0)