[done] switches to threadsafe concurrenthashmap
This commit is contained in:
parent
be4f9dd209
commit
a00504c9f9
1 changed files with 2 additions and 2 deletions
|
|
@ -2,9 +2,9 @@ package de.pzzz.vertx;
|
|||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
|
||||
import io.vertx.core.Vertx;
|
||||
import io.vertx.core.eventbus.Message;
|
||||
|
|
@ -14,7 +14,7 @@ import io.vertx.ext.web.Router;
|
|||
import io.vertx.ext.web.RoutingContext;
|
||||
|
||||
public class RestDataAccess<T extends SerializableWithId> {
|
||||
private Map<String, T> dataMap = new HashMap<>();
|
||||
private Map<String, T> dataMap = new ConcurrentHashMap<>();
|
||||
protected final Class<T> classReference;
|
||||
|
||||
public RestDataAccess(final Class<T> classReference) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue