Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#1405: replace HashMap be ConcurrentHashMap #1408

Merged
merged 1 commit into from
Jun 3, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions framework/src/play/classloading/ApplicationClasses.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
import java.io.FileOutputStream;
import java.lang.annotation.Annotation;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

import javassist.ClassPool;
import javassist.CtClass;
Expand All @@ -30,13 +30,13 @@ public class ApplicationClasses {
/**
* Cache of all compiled classes
*/
Map<String, ApplicationClass> classes = new HashMap<>();
Map<String, ApplicationClass> classes = new ConcurrentHashMap<>();

/**
* Clear the classes cache
*/
public void clear() {
classes = new HashMap<>();
classes = new ConcurrentHashMap<>();
}

/**
Expand Down