Skip to content

Commit

Permalink
Remove Systrace annotation that is breaking logged data
Browse files Browse the repository at this point in the history
Summary:
We're logging a systrace section that for some reason is breaking the data in application traces. That section isn't especially relevant so we can just remove it.

Changelog: [internal]

Reviewed By: sammy-SC

Differential Revision: D50939346

fbshipit-source-id: 350a528d83c6fe6e7100275644d3d02a96700e59
  • Loading branch information
rubennorte authored and facebook-github-bot committed Nov 3, 2023
1 parent b955fc2 commit aa5141c
Showing 1 changed file with 5 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,12 @@

package com.facebook.react.uimanager;

import static com.facebook.systrace.Systrace.TRACE_TAG_REACT_JAVA_BRIDGE;

import androidx.annotation.Nullable;
import androidx.annotation.VisibleForTesting;
import com.facebook.common.logging.FLog;
import com.facebook.react.common.MapBuilder;
import com.facebook.react.common.build.ReactBuildConfig;
import com.facebook.react.config.ReactFeatureFlags;
import com.facebook.systrace.SystraceMessage;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
Expand Down Expand Up @@ -112,21 +109,11 @@ private static void validateDirectEventNames(
for (ViewManager viewManager : viewManagers) {
final String viewManagerName = viewManager.getName();

SystraceMessage.beginSection(
TRACE_TAG_REACT_JAVA_BRIDGE, "UIManagerModuleConstantsHelper.createConstants")
.arg("ViewManager", viewManagerName)
.arg("Lazy", false)
.flush();

try {
Map viewManagerConstants =
createConstantsForViewManager(
viewManager, null, null, allBubblingEventTypes, allDirectEventTypes);
if (!viewManagerConstants.isEmpty()) {
constants.put(viewManagerName, viewManagerConstants);
}
} finally {
SystraceMessage.endSection(TRACE_TAG_REACT_JAVA_BRIDGE);
Map viewManagerConstants =
createConstantsForViewManager(
viewManager, null, null, allBubblingEventTypes, allDirectEventTypes);
if (!viewManagerConstants.isEmpty()) {
constants.put(viewManagerName, viewManagerConstants);
}
}

Expand Down

0 comments on commit aa5141c

Please sign in to comment.