Skip to content

Commit

Permalink
stats: disable lifecycle-based stat flushing (#749)
Browse files Browse the repository at this point in the history
Description: disable until #748 is fixed.
Risk Level: low given stats are being flushed every 5 secs.

Signed-off-by: Jose Nino <[email protected]>
Signed-off-by: JP Simard <[email protected]>
  • Loading branch information
junr03 authored and jpsim committed Nov 29, 2022
1 parent 92a5078 commit bcd3117
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,17 @@ public EnvoyHTTPStream startStream(EnvoyHTTPCallbacks callbacks) {

@Override
public int runWithConfig(String configurationYAML, String logLevel) {
AndroidAppLifecycleMonitor monitor = new AndroidAppLifecycleMonitor();
application.registerActivityLifecycleCallbacks(monitor);
// re-enable lifecycle-based stat flushing when https://github.com/lyft/envoy-mobile/issues/748
// gets fixed. AndroidAppLifecycleMonitor monitor = new AndroidAppLifecycleMonitor();
// application.registerActivityLifecycleCallbacks(monitor);
return envoyEngine.runWithConfig(configurationYAML, logLevel);
}

@Override
public int runWithConfig(EnvoyConfiguration envoyConfiguration, String logLevel) {
AndroidAppLifecycleMonitor monitor = new AndroidAppLifecycleMonitor();
application.registerActivityLifecycleCallbacks(monitor);
// re-enable lifecycle-based stat flushing when https://github.com/lyft/envoy-mobile/issues/748
// gets fixed. AndroidAppLifecycleMonitor monitor = new AndroidAppLifecycleMonitor();
// application.registerActivityLifecycleCallbacks(monitor);
return envoyEngine.runWithConfig(envoyConfiguration, logLevel);
}
}
3 changes: 2 additions & 1 deletion mobile/library/objective-c/EnvoyEngineImpl.m
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ - (int)runWithConfig:(EnvoyConfiguration *)config logLevel:(NSString *)logLevel
}

- (int)runWithConfigYAML:(NSString *)configYAML logLevel:(NSString *)logLevel {
[self startObservingLifecycleNotifications];
// re-enable lifecycle-based stat flushing when https://github.com/lyft/envoy-mobile/issues/748
// gets fixed. [self startObservingLifecycleNotifications];

// Envoy exceptions will only be caught here when compiled for 64-bit arches.
// https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/Exceptions/Articles/Exceptions64Bit.html
Expand Down

0 comments on commit bcd3117

Please sign in to comment.