From 8d1f6820337e930b5a8656451197045271bbf3e4 Mon Sep 17 00:00:00 2001 From: 451134428 <451134428@qq.com> Date: Tue, 23 Oct 2018 09:56:01 +0800 Subject: [PATCH 1/3] update --- examples/laravel/env/.env | 6 ------ 1 file changed, 6 deletions(-) diff --git a/examples/laravel/env/.env b/examples/laravel/env/.env index bed8015..e69de29 100644 --- a/examples/laravel/env/.env +++ b/examples/laravel/env/.env @@ -1,6 +0,0 @@ - -DB_HOST=rm-bp1v28fr23a11wi1wo.mysql.rds.aliyuncs.com -DB_PORT=3306 -DB_DATABASE=g-store -DB_USERNAME=db_dev -DB_PASSWORD=ecarxdb@IMhi9m From 4ba1f43e86eb353cabc64bea6afa3fa00e02bf89 Mon Sep 17 00:00:00 2001 From: 451134428 <451134428@qq.com> Date: Fri, 26 Oct 2018 10:45:50 +0800 Subject: [PATCH 2/3] update --- examples/laravel/env/.env | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/examples/laravel/env/.env b/examples/laravel/env/.env index e69de29..bed8015 100644 --- a/examples/laravel/env/.env +++ b/examples/laravel/env/.env @@ -0,0 +1,6 @@ + +DB_HOST=rm-bp1v28fr23a11wi1wo.mysql.rds.aliyuncs.com +DB_PORT=3306 +DB_DATABASE=g-store +DB_USERNAME=db_dev +DB_PASSWORD=ecarxdb@IMhi9m From e4d6f841ddb0d86d38605d94b406341e0f2f7c8f Mon Sep 17 00:00:00 2001 From: 451134428 <451134428@qq.com> Date: Fri, 26 Oct 2018 11:03:36 +0800 Subject: [PATCH 3/3] code optimize --- examples/laravel/apollo.php | 2 +- examples/laravel/env/.env | 1 - start.php | 29 ----------------------------- 3 files changed, 1 insertion(+), 31 deletions(-) delete mode 100644 examples/laravel/env/.env delete mode 100644 start.php diff --git a/examples/laravel/apollo.php b/examples/laravel/apollo.php index 6aa85d3..fe26b10 100644 --- a/examples/laravel/apollo.php +++ b/examples/laravel/apollo.php @@ -21,7 +21,7 @@ } } if (!$apollo) { - throw new Exception('Load Apollo Config Failed'); + throw new Exception('Load Apollo Config Failed, no config available'); } ob_start(); include ENV_TPL; diff --git a/examples/laravel/env/.env b/examples/laravel/env/.env deleted file mode 100644 index 8b13789..0000000 --- a/examples/laravel/env/.env +++ /dev/null @@ -1 +0,0 @@ - diff --git a/start.php b/start.php deleted file mode 100644 index 36e0cf5..0000000 --- a/start.php +++ /dev/null @@ -1,29 +0,0 @@ -#!/usr/bin/env php -setClientIp($clientIp); -} - -ini_set('memory_limit','128M'); -$pid = getmypid(); -echo "start [$pid]\n"; -$restart = false; //失败自动重启 -do { - $error = $apollo->start(); - if ($error) echo('error:'.$error."\n"); -}while($error && $restart); \ No newline at end of file