-
Notifications
You must be signed in to change notification settings - Fork 11
Description
The current implementation of SwiftLogglyDestination will lose log messages if there is no network connection when it wants to push the logs, or if the program is terminated or crashes before it posts the logs. The crash case is probably the time you most want the logs.
I'm reworking the destination to write to log files, which are then handed off to NSURLSessionUploadTask to upload these files in the background when the system can and feels it's appropriate. See https://github.com/pushd/BackgroundUpload-CocoaLumberjack for an example of this approach for Lumberjack.
Would you prefer this as a separate repository, a new destination (SwiftLogglyBackgroundDestination? getting a bit wordy, but consistent), or as a replacement for SwiftLogglyDestination? I'm adapting this from the current SwiftLogglyDestination code, and plan to use the same fields, etc (so there would be a lot of code duplication that may need to be refactored out).