FSchumacher commented on a change in pull request #700:
URL: https://github.com/apache/jmeter/pull/700#discussion_r814076712
##########
File path:
src/components/src/main/java/org/apache/jmeter/assertions/JSONPathAssertion.java
##########
@@ -164,8 +166,12 @@ private boolean arrayMatched(JSONArray value) {
private boolean isEquals(Object subj) {
if (isUseRegex()) {
String str = objectToString(subj);
- Pattern pattern =
JMeterUtils.getPatternCache().getPattern(getExpectedValue());
- return JMeterUtils.getMatcher().matches(str, pattern);
+ if (useJavaRegex) {
+ return java.util.regex.Pattern.matches(getExpectedValue(),
str);
+ } else {
+ Pattern pattern =
JMeterUtils.getPatternCache().getPattern(getExpectedValue());
Review comment:
Added a cache with
[1d30005](https://github.com/apache/jmeter/pull/700/commits/1d3000597810a7e5c379cabad00c1369002a0c1f)
Now, we should use it and measure, if it is performing well :)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]