This repository has been archived by the owner on Jun 3, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
[Android] Android] restart weexCoreThread when reload JSEngine becaus… #2824
Merged
Darin726
merged 1 commit into
apache:master
from
lucky-chen:bugfix/ws_restart_corethread
Aug 14, 2019
Merged
[Android] Android] restart weexCoreThread when reload JSEngine becaus… #2824
Darin726
merged 1 commit into
apache:master
from
lucky-chen:bugfix/ws_restart_corethread
Aug 14, 2019
Conversation
This file contains 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
…e thread maybe in lock state and can't execute reload action (block)
lucky-chen
requested review from
Darin726,
gubaojian and
YorkShen
as code owners
August 14, 2019 08:07
|
Darin726
reviewed
Aug 14, 2019
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oldThread.quit(); 有风险吗
WXThread oldThread = mJSThread; | ||
mJSThread = new WXThread("WeexJSBridgeThread", this); | ||
mJSHandler = mJSThread.getHandler(); | ||
oldThread.quit(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
程序还在运行, 直接 quit 有风险吗? 有发过灰度吗
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- HanderThread quit是比较安全的,remove 消息队列里面的所有消息,然后thread没有消息,loop结束,线程自然回收
- 灰度同步进行
Darin726
approved these changes
Aug 14, 2019
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
lucky-chen
added a commit
to lucky-chen/incubator-weex
that referenced
this pull request
Aug 15, 2019
…e because thread maybe in lock state and can't execute reload action (block) (apache#2824)" This reverts commit c72e6b5.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
[Android] Android] restart weexCoreThread when reload JSEngine because thread maybe in lock state and can't execute reload action (block)