Refactor logging of Fabric React Markers when running on the UI Thread
Summary: This diff refactors the execution of the logging of Fabric React markers to be executed after the MountItems are executed on the UI Thred Changelog: Improve logging of Fabric react markers Reviewed By: JoshuaGross Differential Revision: D18010920 fbshipit-source-id: e36306102d190119a89c16e660b855acab1528fe
This commit is contained in:
Родитель
c5321e8514
Коммит
a8ce2dcf89
|
@ -474,10 +474,14 @@ public class FabricUIManager implements UIManager, LifecycleEventListener {
|
|||
mMountItems.add(mountItem);
|
||||
}
|
||||
|
||||
// Post markers outside of lock
|
||||
if (UiThreadUtil.isOnUiThread()) {
|
||||
dispatchMountItems();
|
||||
}
|
||||
|
||||
// Post markers outside of lock and after sync mounting finishes its execution
|
||||
if (isBatchMountItem) {
|
||||
ReactMarker.logFabricMarker(
|
||||
ReactMarkerConstants.FABRIC_COMMIT_START, null, commitNumber, mCommitStartTime);
|
||||
ReactMarkerConstants.FABRIC_COMMIT_START, null, commitNumber, commitStartTime);
|
||||
ReactMarker.logFabricMarker(
|
||||
ReactMarkerConstants.FABRIC_FINISH_TRANSACTION_START,
|
||||
null,
|
||||
|
@ -498,10 +502,6 @@ public class FabricUIManager implements UIManager, LifecycleEventListener {
|
|||
ReactMarkerConstants.FABRIC_LAYOUT_END, null, commitNumber, layoutEndTime);
|
||||
ReactMarker.logFabricMarker(ReactMarkerConstants.FABRIC_COMMIT_END, null, commitNumber);
|
||||
}
|
||||
|
||||
if (UiThreadUtil.isOnUiThread()) {
|
||||
dispatchMountItems();
|
||||
}
|
||||
}
|
||||
|
||||
@UiThread
|
||||
|
|
Загрузка…
Ссылка в новой задаче