Skip to content

Commit

Permalink
Adjust some naming.
Browse files Browse the repository at this point in the history
  • Loading branch information
agoallikmaa committed May 27, 2021
1 parent a8bad8f commit aa6c829
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public static boolean isThreadPropagationDebuggerEnabled() {

public static Context appendLocations(
Context context, StackTraceElement[] locations, Object carrier) {
List<Propagation> currentLocations = ContextPropagationDebug.getLocations(context);
List<Propagation> currentLocations = ContextPropagationDebug.getPropagations(context);
if (currentLocations == null) {
currentLocations = new CopyOnWriteArrayList<>();
context = context.with(THREAD_PROPAGATION_LOCATIONS, currentLocations);
Expand Down Expand Up @@ -68,15 +68,15 @@ public static void debugContextLeakIfEnabled() {
}
}

private static List<Propagation> getLocations(Context context) {
private static List<Propagation> getPropagations(Context context) {
return context.get(THREAD_PROPAGATION_LOCATIONS);
}

private static void debugContextPropagation(Context context) {
List<Propagation> locations = getLocations(context);
if (locations != null) {
List<Propagation> propagations = getPropagations(context);
if (propagations != null) {
StringBuilder sb = new StringBuilder();
Iterator<Propagation> i = locations.iterator();
Iterator<Propagation> i = propagations.iterator();
while (i.hasNext()) {
Propagation entry = i.next();
sb.append("\ncarrier of type: ").append(entry.carrierClassName);
Expand Down

0 comments on commit aa6c829

Please sign in to comment.