Return-Path: Delivered-To: apmail-jakarta-jmeter-user-archive@www.apache.org Received: (qmail 63301 invoked from network); 25 Mar 2011 12:56:13 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 25 Mar 2011 12:56:13 -0000 Received: (qmail 21905 invoked by uid 500); 25 Mar 2011 12:56:13 -0000 Delivered-To: apmail-jakarta-jmeter-user-archive@jakarta.apache.org Received: (qmail 21865 invoked by uid 500); 25 Mar 2011 12:56:13 -0000 Mailing-List: contact jmeter-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "JMeter Users List" Reply-To: "JMeter Users List" Delivered-To: mailing list jmeter-user@jakarta.apache.org Received: (qmail 21857 invoked by uid 99); 25 Mar 2011 12:56:13 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 25 Mar 2011 12:56:13 +0000 X-ASF-Spam-Status: No, hits=1.8 required=5.0 tests=FREEMAIL_FROM,FREEMAIL_REPLY,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of sebbaz@gmail.com designates 209.85.216.44 as permitted sender) Received: from [209.85.216.44] (HELO mail-qw0-f44.google.com) (209.85.216.44) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 25 Mar 2011 12:56:06 +0000 Received: by qwg5 with SMTP id 5so683885qwg.31 for ; Fri, 25 Mar 2011 05:55:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=sLqaR4sdPuBXdxvg2CauZDkpnVMQmPaEMvxvBWKd+1U=; b=MzsPByaUNbYpj5g46eBNmD2mWjSiDt99N25TD2c5cAD13mPGQQQsD+7ooCjaQTLE7h 44A9ZoGY8zk4RUB64ZlE5zK0FI8HcaycmKV74LDYNFT0oF9kJKykmKdnCyfTlU3Kl5Yh WJyUfN71MQWuGvqg82hQvAvlTQglsXdTFpNZw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=sGu/T+vN3H18Vzy9TA4yg3svHIDiFbPr+T+UEyDQ0w4e0bKpH1rPrrwQrCq5PtYvtM J+YkoYFy6qHZ+ZTsGybxoIWUrfX/HGyyb3CV8LKs7TJk+vCJn1eFXvpNQC+/qHz7lLaC r5LAjnoea9rnWSLHrAAgfBzzwewpWw0ExlouE= MIME-Version: 1.0 Received: by 10.229.96.200 with SMTP id i8mr580505qcn.226.1301057745705; Fri, 25 Mar 2011 05:55:45 -0700 (PDT) Received: by 10.229.24.69 with HTTP; Fri, 25 Mar 2011 05:55:45 -0700 (PDT) In-Reply-To: References: <34FAE3C7-AFCB-4769-BDB6-58DA91FDFE77@mac.com> Date: Fri, 25 Mar 2011 12:55:45 +0000 Message-ID: Subject: Re: jmeter to store responses in recording controller. From: sebb To: JMeter Users List Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Checked: Checked by ClamAV on apache.org On 25 March 2011 12:33, Vikas Malik wrote: >> Have you looked at the documentation, particularly the component > reference? > > 1. Yes Sebb, I have seen "save response to file" and tried it. The thing is, > we can not use it to store the response while we are manually playing > through proxy and recording. Proxy should be able to capture response also > at the same time instead of having to replay it again to create the samples. That does work, but you have to put the Listeners on the Workbench which is where the "sampler" - i.e. Proxy - is. > If we create samples in next step while replaying we need to go to each > response again to manually verify that sample to be sure that samples are > good, nothing went wrong this time. I think second step is unnecessary. It is. > 2. The other question is, can jmeter compare responses from test run against > a set of reference responses stored on disk and give a report saying which > requests produced different results. No, file comparison is not supported by JMeter. You could always write your own Assertion using the BSF or BSH Assertion elements. Or you can use Assertions - e.g. MD5 - to check for such things. http://jakarta.apache.org/jmeter/usermanual/component_reference.html#MD5Hex_Assertion You would have to work out the hashes beforehand and perhaps put them in a CSV file. > > On Fri, Mar 25, 2011 at 5:36 PM, sebb wrote: > >> On 25 March 2011 07:32, Vikas Malik wrote: >> > Hi David, >> > >> > Thanks for the response, >> > >> >>(1) Capture them all in a Results Tree sampler. I think I would do this >> > twice for one and two as you list below, then compare the output files >> > >> > I have many requests(test cases) in my automated test suite. At the end >> of >> > test-run, I want to get a list of failed test cases/requests. >> > In this case, I guess it would be needed to do some extra work "parse and >> > compare" the two xmls etc. >> > >> > This requirement is a very general use case. Does jmeter provide a >> simpler >> > way to go about it? >> >> Have you looked at the documentation, particularly the component reference? >> >> There is a Listener (Save Results) that can do just this. >> >> > For load testing also, I think it would be useful because to verify that >> > under a heavy load also your website sends expected response is >> important. >> > >> > Please let me know if I am trying to do something differently or missing >> > something. >> > >> > Thanks. >> > >> > >> > On Fri, Mar 25, 2011 at 11:50 AM, David Patrick >> wrote: >> > >> >> Hi Vikas, >> >> >> >> To record the responses, I think you have two options: >> >> (1) Capture them all in a Results Tree sampler. I think I would do this >> >> twice for one and two as you list below, then compare the output files >> >> >> >> or >> >> >> >> (2) Use Badboy (badboy.com.au) to record the transactions in record >> phase. >> >> Then, after exporting this to a JMX file, you will be able to run it and >> >> compare the results you get. >> >> >> >> If you are looking to do both your steps in each iteration, then I think >> >> that extending my option (1) above is the way to go - possibly using >> REGEX >> >> samples, variables and assertions to capture the response, re-request it >> and >> >> check again. >> >> >> >> I hope I have been of help. >> >> >> >> -- >> >> David Patrick >> >> david.m1fcf@mac.com >> >> >> >> On 25 Mar 2011, at 06:11, Vikas Malik wrote: >> >> >> >> > Hello, >> >> > >> >> > I am using jmeter for functional testing the website. I am trying to >> >> store >> >> > the responses while recording the HTTP request traffic using HTTP >> proxy >> >> > server, but there does not seem to be any option in jmeter to store >> >> > responses. >> >> > >> >> > Basically I am trying to do the following. Please let me know if it is >> >> > possible to do so using jmeter, if yes, any pointers how to go about >> it >> >> will >> >> > be very useful. >> >> > >> >> > 1. Store the http traffic(both request and response) using HTTP proxy. >> >> Store >> >> > the responses as samples. >> >> > 2. Re-run the recorded HTTP requests in testing phase and compare the >> >> > responses we get now against the samples stored in step 1. Any >> mismatch >> >> > should fail the test. >> >> > >> >> > Thanks. >> >> > Vikas Malik >> >> >> >> >> >> --------------------------------------------------------------------- >> >> 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 >> >> > --------------------------------------------------------------------- To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: jmeter-user-help@jakarta.apache.org