Skip to content

Instantly share code, notes, and snippets.

@FooBarWidget
Created October 19, 2012 09:55
Show Gist options
  • Save FooBarWidget/3917241 to your computer and use it in GitHub Desktop.
Save FooBarWidget/3917241 to your computer and use it in GitHub Desktop.
diff --git a/ext/common/ApplicationPool2/Pool.h b/ext/common/ApplicationPool2/Pool.h
index e5cd3a8..82ca754 100644
--- a/ext/common/ApplicationPool2/Pool.h
+++ b/ext/common/ApplicationPool2/Pool.h
@@ -482,6 +482,14 @@ public:
typedef shared_ptr<ProcessAnalyticsLogEntry> ProcessAnalyticsLogEntryPtr;
void collectAnalytics(ev::timer &timer, int revents) {
+ try {
+ realCollectAnalytics(timer);
+ } catch (const tracable_exception &e) {
+ P_WARN("ERROR: " << e.what() << "\n Backtrace:\n" << e.backtrace());
+ }
+ }
+
+ void realCollectAnalytics(ev::timer &timer) {
PoolPtr self = shared_from_this(); // Keep pool object alive.
TRACE_POINT();
this_thread::disable_interruption di;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment