You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by kukukuku <ku...@trash-mail.com> on 2010/02/26 11:48:50 UTC

Question about XPath Extractor

Hi,

I'm monitoring my tomcat according to the monitor tutorial on the reference
documentation. I have an Simple Data Writer where i save the response and
right behind it i have an XPath Extractor post processor with the following
expression "/status/jvm/memory@free". To test if it works i've set up an
beanshell post processor to validate the variable which was set. However it
is not working, i think i'm missing something. Please help.

kuku
-- 
View this message in context: http://old.nabble.com/Question-about-XPath-Extractor-tp27716815p27716815.html
Sent from the JMeter - User mailing list archive at Nabble.com.


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


Re: Question about XPath Extractor

Posted by sebb <se...@gmail.com>.
On 26/02/2010, kukukuku <ku...@trash-mail.com> wrote:
>
>  Hi,
>
>  I'm monitoring my tomcat according to the monitor tutorial on the reference
>  documentation. I have an Simple Data Writer where i save the response and
>  right behind it i have an XPath Extractor post processor with the following
>  expression "/status/jvm/memory@free". To test if it works i've set up an
>  beanshell post processor to validate the variable which was set. However it
>  is not working, i think i'm missing something. Please help.

Note that the Debug Sampler is useful for displaying the values of variables.

>  kuku
>
> --
>  View this message in context: http://old.nabble.com/Question-about-XPath-Extractor-tp27716815p27716815.html
>  Sent from the JMeter - User mailing list archive at Nabble.com.
>
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>  For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>
>

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


Re: Question about XPath Extractor

Posted by kukukuku <ku...@trash-mail.com>.
wow, your right thank you very much !!


Noel O'Brien wrote:
> 
> Hi, 
> 
> Just noticed a missing slash in your XPath between "memory" and "@free",
> it should be: 
> /status/jvm/memory/@free 
> 
> This extracts the correct value for me 
> 
> Regards, 
> Noel 
> 
> ----- "kukukuku" <ku...@trash-mail.com> wrote: 
>> 
>> Hi, 
>> 
>> here the relevant part: 
>> <?xml version="1.0" encoding="utf-8"?><?xml-stylesheet type="text/xsl" 
>> href="/manager/xform.xsl" ?> 
>> <status> 
>> <jvm> 
>> <memory free='5028256' total='23900160' max='66650112' /> 
>> </jvm> 
>> <!-- here comes the rest.......... --> 
>> </status> 
>> 
>> i don't think it has something to do with the expression cause if i use
>> /* i 
>> also get nothing. 
>> 
>> 
>> 
>> 
>> kukukuku wrote: 
>> > 
>> > Hi, 
>> > 
>> > I'm monitoring my tomcat according to the monitor tutorial on the 
>> > reference documentation. I have an Simple Data Writer where i save the 
>> > response and right behind it i have an XPath Extractor post processor
>> with 
>> > the following expression "/status/jvm/memory@free". To test if it works 
>> > i've set up an beanshell post processor to validate the variable which
>> was 
>> > set. However it is not working, i think i'm missing something. Please 
>> > help. 
>> > 
>> > kuku 
>> > 
>> 
>> -- 
>> View this message in context:
>> http://old.nabble.com/Question-about-XPath-Extractor-tp27716815p27716994.html 
>> Sent from the JMeter - User mailing list archive at Nabble.com. 
>> 
>> 
>> --------------------------------------------------------------------- 
>> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org 
>> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org 
>> 
>> 
> 

-- 
View this message in context: http://old.nabble.com/Question-about-XPath-Extractor-tp27716815p27717067.html
Sent from the JMeter - User mailing list archive at Nabble.com.


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


Re: Question about XPath Extractor

Posted by Noel O'Brien <no...@newbay.com>.
Hi, 

Just noticed a missing slash in your XPath between "memory" and "@free", it should be: 
/status/jvm/memory/@free 

This extracts the correct value for me 

Regards, 
Noel 

----- "kukukuku" <ku...@trash-mail.com> wrote: 
> 
> Hi, 
> 
> here the relevant part: 
> <?xml version="1.0" encoding="utf-8"?><?xml-stylesheet type="text/xsl" 
> href="/manager/xform.xsl" ?> 
> <status> 
> <jvm> 
> <memory free='5028256' total='23900160' max='66650112' /> 
> </jvm> 
> <!-- here comes the rest.......... --> 
> </status> 
> 
> i don't think it has something to do with the expression cause if i use /* i 
> also get nothing. 
> 
> 
> 
> 
> kukukuku wrote: 
> > 
> > Hi, 
> > 
> > I'm monitoring my tomcat according to the monitor tutorial on the 
> > reference documentation. I have an Simple Data Writer where i save the 
> > response and right behind it i have an XPath Extractor post processor with 
> > the following expression "/status/jvm/memory@free". To test if it works 
> > i've set up an beanshell post processor to validate the variable which was 
> > set. However it is not working, i think i'm missing something. Please 
> > help. 
> > 
> > kuku 
> > 
> 
> -- 
> View this message in context: http://old.nabble.com/Question-about-XPath-Extractor-tp27716815p27716994.html 
> Sent from the JMeter - User mailing list archive at Nabble.com. 
> 
> 
> --------------------------------------------------------------------- 
> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org 
> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org 
> 
> 

Re: Question about XPath Extractor

Posted by kukukuku <ku...@trash-mail.com>.
Hi,

here the relevant part:
<?xml version="1.0" encoding="utf-8"?><?xml-stylesheet type="text/xsl"
href="/manager/xform.xsl" ?>
	<status>
		<jvm>
			<memory free='5028256' total='23900160' max='66650112' />
		</jvm>
         <!-- here comes the rest.......... -->
       </status>

i don't think it has something to do with the expression cause if i use /* i
also get nothing.




kukukuku wrote:
> 
> Hi,
> 
> I'm monitoring my tomcat according to the monitor tutorial on the
> reference documentation. I have an Simple Data Writer where i save the
> response and right behind it i have an XPath Extractor post processor with
> the following expression "/status/jvm/memory@free". To test if it works
> i've set up an beanshell post processor to validate the variable which was
> set. However it is not working, i think i'm missing something. Please
> help.
> 
> kuku
> 

-- 
View this message in context: http://old.nabble.com/Question-about-XPath-Extractor-tp27716815p27716994.html
Sent from the JMeter - User mailing list archive at Nabble.com.


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


Re: Question about XPath Extractor

Posted by Noel O'Brien <no...@newbay.com>.
Hi, 

Please post an example of the sampler response (tomcats xml data), an what you expect your script to do. 

Regards, 
Noel 

----- "kukukuku" <ku...@trash-mail.com> wrote: 
> 
> Hi, 
> 
> I'm monitoring my tomcat according to the monitor tutorial on the reference 
> documentation. I have an Simple Data Writer where i save the response and 
> right behind it i have an XPath Extractor post processor with the following 
> expression "/status/jvm/memory@free". To test if it works i've set up an 
> beanshell post processor to validate the variable which was set. However it 
> is not working, i think i'm missing something. Please help. 
> 
> kuku 
> -- 
> View this message in context: http://old.nabble.com/Question-about-XPath-Extractor-tp27716815p27716815.html 
> Sent from the JMeter - User mailing list archive at Nabble.com. 
> 
> 
> --------------------------------------------------------------------- 
> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org 
> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org 
> 
>