Skip to content

Commit 9ed6dc2

Browse files
authored
fix: make JsonSchemaFactory more thread-safe #891 (#892)
1 parent 92141e3 commit 9ed6dc2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/networknt/schema/JsonSchemaFactory.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public static class Builder {
4848
private final Map<String, URIFactory> uriFactoryMap = new HashMap<String, URIFactory>();
4949
private final Map<String, URIFetcher> uriFetcherMap = new HashMap<String, URIFetcher>();
5050
private URNFactory urnFactory;
51-
private final Map<String, JsonMetaSchema> jsonMetaSchemas = new HashMap<String, JsonMetaSchema>();
51+
private final ConcurrentMap<String, JsonMetaSchema> jsonMetaSchemas = new ConcurrentHashMap<String, JsonMetaSchema>();
5252
private final Map<String, String> uriMap = new HashMap<String, String>();
5353
private boolean enableUriSchemaCache = true;
5454
private final CompositeURITranslator uriTranslators = new CompositeURITranslator();

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy