@@ -39,8 +39,8 @@ discard block |
||
39 | 39 | $started = $app->starting()->done(); |
40 | 40 | $shutdown = Promise::deferred(); |
41 | 41 | |
42 | - $app->starting()->add(static function () use ($dispatcher, $started, $shutdown) { |
|
43 | - $dispatcher->preparing($started, $shutdown)->catch(function (Throwable $e) { |
|
42 | + $app->starting()->add(static function() use ($dispatcher, $started, $shutdown) { |
|
43 | + $dispatcher->preparing($started, $shutdown)->catch(function(Throwable $e) { |
|
44 | 44 | logger('hrpc')->error( |
45 | 45 | 'Service startup failed when initialize', |
46 | 46 | ['ec' => get_class($e), 'em' => $e->getMessage()] |
@@ -48,7 +48,7 @@ discard block |
||
48 | 48 | }); |
49 | 49 | }); |
50 | 50 | |
51 | - $app->stopping()->add(static function () use ($shutdown) { |
|
51 | + $app->stopping()->add(static function() use ($shutdown) { |
|
52 | 52 | $shutdown->resolve(); |
53 | 53 | }); |
54 | 54 | } |
@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | // initial mark server "unavailable" |
50 | 50 | Server::layers()->append(ServerWrapper::class, DI::object(ServerUnavailable::class)); |
51 | 51 | |
52 | - $app->starting()->add(static function () use ($options) { |
|
52 | + $app->starting()->add(static function() use ($options) { |
|
53 | 53 | // add traffic monitor layer |
54 | 54 | DI::has(Daemon::class) && Server::layers()->append( |
55 | 55 | ServerWrapper::class, |
@@ -59,7 +59,7 @@ discard block |
||
59 | 59 | config()->bind($options, ['rpc.serv.opts' => ['tt.exec' => 'ttExec']]); |
60 | 60 | }); |
61 | 61 | |
62 | - $app->starting()->done()->then(static function () { |
|
62 | + $app->starting()->done()->then(static function() { |
|
63 | 63 | // mark server "available" when bootstrap done |
64 | 64 | Server::layers()->remove(ServerUnavailable::class); |
65 | 65 | }); |