Factory based instantiation + linux fixes
Changes:
- Fix crash related to
@autoreleasepool
on linux. - Fix log entries source location filepaths being fully logged, now only the relevant filepath information is logged.
- Add a configuration file from which you can control if timestamps are logged to your log file or not.
- Switch to a factory based instantiation system.
The bootstrapping now uses a factory and a config file, it looks like this:
try! StackdriverLogHandlerFactory.prepare(with: .init(logFilePath: "/var/log/my-app.log",
defaultLogLevel: .debug,
logTimestamps: true))
LoggingSystem.bootstrap { label in
return StackdriverLogHandlerFactory.make()
}