Update production

This commit is contained in:
thomashii 2021-05-18 17:42:21 +08:00
parent 718064ad66
commit 80ec2e10a8
4 changed files with 13 additions and 8 deletions

View file

@ -1,3 +1,6 @@
# 3.0.1
* Fixed static analysis warnings
# 3.0.0
* Migrated to support Dart SDK 2.12.x NNBD

View file

@ -1,5 +1,5 @@
# angel3_production
[![version](https://img.shields.io/badge/pub-v3.0.0-brightgreen)](https://pub.dartlang.org/packages/angel3_production)
[![version](https://img.shields.io/badge/pub-v3.0.1-brightgreen)](https://pub.dartlang.org/packages/angel3_production)
[![Null Safety](https://img.shields.io/badge/null-safety-brightgreen)](https://dart.dev/null-safety)
[![Gitter](https://img.shields.io/gitter/room/angel_dart/discussion)](https://gitter.im/angel_dart/discussion)
@ -26,7 +26,7 @@ import 'dart:isolate';
import 'package:angel3_framework/angel3_framework.dart';
import 'package:angel3_production/angel3_production.dart';
main(List<String> args) => Runner('example', configureServer).run(args);
void main(List<String> args) => Runner('example', configureServer).run(args);
Future configureServer(Angel app) async {
app.get('/', (req, res) => 'Hello, production world!');

View file

@ -94,7 +94,11 @@ _ ___ | /| / / /_/ / _ /___ _ /___
onError: onError.sendPort,
errorsAreFatal: true && false)
.then((isolate) {})
.catchError(c.completeError);
//.catchError(c.completeError);
.catchError((e) {
c.completeError(e as Object);
return null;
});
onLogRecord.listen((msg) => handleLogRecord(msg as LogRecord?, options));
@ -213,10 +217,8 @@ _ ___ | /| / / /_/ / _ /___ _ /___
await app.configure(args.configureServer);
if (app.logger == null) {
app.logger = Logger(args.loggerName)
..onRecord.listen((rec) => Runner.handleLogRecord(rec, args.options));
}
app.logger ??= Logger(args.loggerName)
..onRecord.listen((rec) => Runner.handleLogRecord(rec, args.options));
AngelHttp http;
late SecurityContext securityContext;

View file

@ -1,5 +1,5 @@
name: angel3_production
version: 3.0.0
version: 3.0.1
description: Helpers for concurrency, message-passing, rotating loggers, and other production functionality in Angel.
homepage: https://github.com/dukefirehawk/angel/tree/angel3/packages/production
environment: