diff --git a/example/handle_error.dart b/example/handle_error.dart index d4e6a799..d7d302a8 100644 --- a/example/handle_error.dart +++ b/example/handle_error.dart @@ -3,11 +3,12 @@ import 'dart:io'; import 'package:angel_container/mirrors.dart'; import 'package:angel_framework/angel_framework.dart'; import 'package:angel_framework/http.dart'; -import 'package:logging/logging.dart'; +import 'package:lumberjack/lumberjack.dart'; +import 'package:lumberjack/io.dart'; main() async { var app = new Angel(reflector: MirrorsReflector()) - ..logger = (new Logger('angel')..onRecord.listen(print)) + ..logger = (new Logger('angel')..pipe(new AnsiLogPrinter.toStdout())) ..encoders.addAll({'gzip': gzip.encoder}); app.fallback( diff --git a/example/http2/body_parsing.dart b/example/http2/body_parsing.dart index ffc3e57a..7a515f05 100644 --- a/example/http2/body_parsing.dart +++ b/example/http2/body_parsing.dart @@ -3,12 +3,13 @@ import 'package:angel_framework/angel_framework.dart'; import 'package:angel_framework/http.dart'; import 'package:angel_framework/http2.dart'; import 'package:file/local.dart'; -import 'package:logging/logging.dart'; -import 'pretty_logging.dart'; +import 'package:lumberjack/lumberjack.dart'; +import 'package:lumberjack/io.dart'; main() async { var app = new Angel(); - app.logger = new Logger('angel')..onRecord.listen(prettyLog); + app.logger = new Logger('angel'); + app.logger.pipe(new AnsiLogPrinter.toStdout()); var publicDir = new Directory('example/public'); var indexHtml = diff --git a/example/http2/main.dart b/example/http2/main.dart index 0f4ebf38..377ec6a6 100644 --- a/example/http2/main.dart +++ b/example/http2/main.dart @@ -2,8 +2,8 @@ import 'dart:io'; import 'package:angel_framework/angel_framework.dart'; import 'package:angel_framework/http.dart'; import 'package:angel_framework/http2.dart'; -import 'package:logging/logging.dart'; -import 'pretty_logging.dart'; +import 'package:lumberjack/lumberjack.dart'; +import 'package:lumberjack/io.dart'; main() async { var app = new Angel() @@ -11,7 +11,8 @@ main() async { 'gzip': gzip.encoder, 'deflate': zlib.encoder, }); - app.logger = new Logger('angel')..onRecord.listen(prettyLog); + app.logger = new Logger('angel'); + app.logger.pipe(new AnsiLogPrinter.toStdout()); app.get('/', (req, res) => 'Hello HTTP/2!!!'); diff --git a/example/http2/server_push.dart b/example/http2/server_push.dart index 3ebec6c5..15f1ce83 100644 --- a/example/http2/server_push.dart +++ b/example/http2/server_push.dart @@ -3,12 +3,13 @@ import 'package:angel_framework/angel_framework.dart'; import 'package:angel_framework/http.dart'; import 'package:angel_framework/http2.dart'; import 'package:file/local.dart'; -import 'package:logging/logging.dart'; -import 'pretty_logging.dart'; +import 'package:lumberjack/lumberjack.dart'; +import 'package:lumberjack/io.dart'; main() async { var app = new Angel(); - app.logger = new Logger('angel')..onRecord.listen(prettyLog); + app.logger = new Logger('angel'); + app.logger.pipe(new AnsiLogPrinter.toStdout()); var publicDir = new Directory('example/http2/public'); var indexHtml =