Uh oh!
There was an error while loading. Please reload this page.
refactor: raw spawn call to instead of helper.spawn in start non-daemon mode - #23
Merged
Merged
Conversation
XadillaXforce-pushed
the
refactor-start-spawn
branch
from
August 7, 2018 08:44
0f0c0b8 to
21c120bComparepopomore
reviewed
Aug 7, 2018
| } else { | ||
| // signal event had been handler at common-bin helper | ||
| this.helper.spawn('node', eggArgs, options); | ||
| options.stdio = options.stdio || 'inherit'; |
Member
There was a problem hiding this comment.
原来的有什么问题?为什么不在 helper.spawn 加参数实现,而又在这里实现重复的逻辑代码?
背景问题是什么?
MemberAuthor
There was a problem hiding this comment.
@fengmk2 要暴露出 child 对象供上层监听使用。我跟天猪讨论后的方案有:
- 暴露出
helper里面的childs; helper里面年久失修,重构估计会变成 break,所以直接这一块逻辑替换。
MemberAuthor
There was a problem hiding this comment.
helper 里面是一个 Promise,要等子进程结束后才会被 resolve。
popomore
reviewed
Aug 7, 2018
| // attach master signal to child | ||
| let signal; | ||
| [ 'SIGINT', 'SIGQUIT', 'SIGTERM' ].forEach(event => { |
Member
There was a problem hiding this comment.
Codecov Report
@@ Coverage Diff @@## master #23 +/- ##
=====================================
Coverage 100% 100% =====================================
Files 6 6 Lines 190 203 +13 =====================================
+ Hits 190 203 +13
Continue to review full report at Codecov.
|
popomore
approved these changes
Aug 9, 2018
popomore
commented
Aug 9, 2018
Member
忘记发了,明天发 |
popomore
commented
Aug 10, 2018
Member
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Checklist
npm testpassesAffected core subsystem(s)
Description of change