You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jmeter-dev@jakarta.apache.org by bu...@apache.org on 2008/05/12 16:21:25 UTC

DO NOT REPLY [Bug 44972] New: Regular Expression (?s) not accepted at end of pattern

https://issues.apache.org/bugzilla/show_bug.cgi?id=44972

           Summary: Regular Expression (?s) not accepted at end of pattern
           Product: JMeter
           Version: 2.3.1
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Main
        AssignedTo: jmeter-dev@jakarta.apache.org
        ReportedBy: michael.giroux@bull.com


Documentation at http://perldoc.perl.org/perlre.html#Extended-Patterns
indicates that the single line modifier may appear at either end of a pattern:

> These can be used anywhere within the expression, e.g.
> (?i)apple(?-i) Pie - matches "ApPLe Pie", but not "ApPLe pIe"

Using 2.3.1, I get an error when the qualifier appears at the end of the
pattern:
TP-STORAGE CONTENTS:.*TX-TYPE +ECHOTPS(?s)

Results in an error:
Assertion failure message : Bad test configuration
org.apache.oro.text.MalformedCachePatternException: Invalid
expression:
TP-STORAGE CONTENTS:.*TX-TYPE +ECHOTPS(?s)
Unmatched parentheses.


Placing the qualifier at the beginning of the pattern works:
(?s)TP-STORAGE CONTENTS:.*TX-TYPE +ECHOTPS


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org


DO NOT REPLY [Bug 44972] Regular Expression (?s) not accepted at end of pattern

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=44972


Michael Giroux <mi...@bull.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|WONTFIX                     |




--- Comment #2 from Michael Giroux <mi...@bull.com>  2008-05-12 07:39:27 PST ---
> JMeter uses Apache ORO for regular expression handling.
>
> It is ORO that is complaining about the trailing (?s).

Interesting point, but from a user perspective, I'm using JMeter, not ORO.

> It does not really make sense to use (?s) at the end of an RE,
> as it does not achieve anything.

I'm sorry, but I cannot agree.  I lost two days fussing with this because the
advice in the mailing list kept referring me to PERL.  The PERL docs are clear
that modifiers appear at the *END* of a pattern.
ex.  /Barney.*Fred/s

JMeter does not use the quoting slash characters, so removing those leaves me
with Barney.*Fred(?s).

I think the JMeter docs need to be improved with additional examples showing
use of the single-line qualifier.


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org


DO NOT REPLY [Bug 44972] Regular Expression (?s) not accepted at end of pattern

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=44972





--- Comment #4 from Michael Giroux <mi...@bull.com>  2008-05-12 08:14:45 PST ---
> That only applies to pattern modifiers, not the exended pattern modifiers.

A distinction I as a JMeter user can only recognize after wasting 2 days.

> > JMeter does not use the quoting slash characters, so removing those 
> > leaves me with Barney.*Fred(?s).

> That's not so.

As a JMeter developer, you are too close to this.  If you have never used PERL,
or ORO and you are trying to build a JMeter test plan starting from the JMeter
docs, this *is* so.

> > I think the JMeter docs need to be improved with additional examples showing
> > use of the single-line qualifier.

Closing this as RESOLVED INVALID is just stubborn.  The docs are inadequate. 
Is it really that hard to swallow your pride and fix them?


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org


DO NOT REPLY [Bug 44972] Regular Expression (?s) not accepted at end of pattern

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=44972





--- Comment #5 from Michael Giroux <mi...@bull.com>  2008-05-12 08:18:49 PST ---
(In reply to comment #4)

Ooops,  I got testy.  Sorry.

> Closing this as RESOLVED INVALID is just stubborn.  The docs are inadequate. 
> Is it really that hard to swallow your pride and fix them?

Should have kept it civil and said:

The docs are not clear. Is it really that hard to fix them?


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org


DO NOT REPLY [Bug 44972] Regular Expression (?s) not accepted at end of pattern

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=44972


Sebb <se...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |INVALID




--- Comment #3 from Sebb <se...@apache.org>  2008-05-12 08:07:14 PST ---
(In reply to comment #2)
> > JMeter uses Apache ORO for regular expression handling.
> >
> > It is ORO that is complaining about the trailing (?s).
> 
> Interesting point, but from a user perspective, I'm using JMeter, not ORO.
> 
> > It does not really make sense to use (?s) at the end of an RE,
> > as it does not achieve anything.
> 
> I'm sorry, but I cannot agree.  I lost two days fussing with this because the
> advice in the mailing list kept referring me to PERL.  The PERL docs are clear
> that modifiers appear at the *END* of a pattern.
> ex.  /Barney.*Fred/s
> 

That only applies to pattern modifiers, not the exended pattern modifiers.

> JMeter does not use the quoting slash characters, so removing those leaves me
> with Barney.*Fred(?s).

That's not so.

> I think the JMeter docs need to be improved with additional examples showing
> use of the single-line qualifier.
> 


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org


DO NOT REPLY [Bug 44972] Regular Expression (?s) not accepted at end of pattern

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=44972


Sebb <se...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |WONTFIX




--- Comment #1 from Sebb <se...@apache.org>  2008-05-12 07:28:10 PST ---
JMeter uses Apache ORO for regular expression handling.

It is ORO that is complaining about the trailing (?s).

It does not really make sense to use (?s) at the end of an RE, as it does not
achieve anything.


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org


DO NOT REPLY [Bug 44972] Regular Expression (?s) not accepted at end of pattern

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=44972





--- Comment #6 from Sebb <se...@apache.org>  2008-05-12 11:02:04 PST ---
Please raise a separate Bugzilla issue regarding the documentation.

There are a lot of documentation files, so it would help the bug identified
which files are relevant. Also documentation patches are welcome.


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org