Issue #BF-5732: Pre-parse METHOD matches into a sub-map; this prevents
the use of string concatenation for lookups at runtime.
Showing
1 changed file
with
3 additions
and
0 deletions
... | @@ -92,6 +92,9 @@ public class DirectControlServlet extends HttpServlet { | ... | @@ -92,6 +92,9 @@ public class DirectControlServlet extends HttpServlet { |
92 | BufferedReader in = new BufferedReader(new InputStreamReader(context.getResourceAsStream(mappingFile))); | 92 | BufferedReader in = new BufferedReader(new InputStreamReader(context.getResourceAsStream(mappingFile))); |
93 | String line; | 93 | String line; |
94 | while ((line = in.readLine()) != null) { | 94 | while ((line = in.readLine()) != null) { |
95 | if (line.startsWith("#")) { | ||
96 | continue; | ||
97 | } | ||
95 | String[] confItem = line.split("="); | 98 | String[] confItem = line.split("="); |
96 | serviceURLMappings.put(confItem[0], confItem[1]); | 99 | serviceURLMappings.put(confItem[0], confItem[1]); |
97 | } | 100 | } | ... | ... |
-
Please register or sign in to post a comment