Return-Path: Delivered-To: apmail-jakarta-jmeter-user-archive@www.apache.org Received: (qmail 73224 invoked from network); 15 Apr 2010 10:46:38 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 15 Apr 2010 10:46:38 -0000 Received: (qmail 75292 invoked by uid 500); 15 Apr 2010 10:46:37 -0000 Delivered-To: apmail-jakarta-jmeter-user-archive@jakarta.apache.org Received: (qmail 75194 invoked by uid 500); 15 Apr 2010 10:46:37 -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 75186 invoked by uid 99); 15 Apr 2010 10:46:36 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 15 Apr 2010 10:46:36 +0000 X-ASF-Spam-Status: No, hits=-5.0 required=10.0 tests=RCVD_IN_DNSWL_HI,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of ben.cuthbert@hsbcib.com designates 193.108.75.62 as permitted sender) Received: from [193.108.75.62] (HELO 19.mail.hsbc.co.uk) (193.108.75.62) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 15 Apr 2010 10:46:29 +0000 Received: from ([172.20.32.105]) by 19.mail.hsbc.co.uk with ESMTP id GNQWLG1.31633113; Thu, 15 Apr 2010 11:34:22 +0100 In-Reply-To: References: Subject: Re: User defined variables X-KeepSent: F450BC7D:3DF71EC4-80257706:003B10ED; type=4; name=$KeepSent To: "JMeter Users List" Cc: JMeter Users List X-Mailer: Lotus Notes Release 8.0.1 February 07, 2008 Message-ID: From: ben.cuthbert@hsbcib.com Date: Thu, 15 Apr 2010 11:45:38 +0100 X-MIMETrack: Serialize by Router on EMEA-SMTP-03/SERVERS/HSBC at 15/04/2010 11:46:06 MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" X-Virus-Checked: Checked by ClamAV on apache.org Thanks I will take a look. I did notice something yesterday when trying to run the JMeter-server my code had loads of null pointers on the server.log. When it runs on my local machine in GUI mode everything is fine. Is there some important document that outlines building load tests for distributed mode? sebb To Apr 15 2010 00:24 JMeter Users List Mail Size: 25545 cc Subject Re: User defined variables Please respond to "JMeter Users List" Entity Have a look at the examples section of the source tree. On 14/04/2010, ben.cuthbert@hsbcib.com wrote: > Sebb > > I have a question. I want to set my own sample time. I am sending out a > message to a remote system and waiting for the Ack to come back. In a > session class > i set the System.nanoTime() on the way out and then when we receive the > incoming response. How can I set this on the sample? as the setTime is > deprecated. > > > > > > __________________________________________________________ > > > > Ben > CUTHBERT/IBEU/HSB > C To > "JMeter Users List" > Apr 14 2010 10:37 > cc > Phone no. 22200 JMeter Users List > 44 0 44 20 799 > 22192 Subject > Mail Size: 20586 Re: User defined variables (Document > link: Ben CUTHBERT) > > > Entity > > > > > > > > Hi Sorry about the attachments. Sorry what is the debug sampler? > > > Regards > > > > > sebb > > To > Apr 14 2010 10:33 JMeter Users List > > Mail Size: 19074 cc > > > Subject > Re: User defined variables > Please respond to > "JMeter Users > > List" Entity > > ta.apache.org> > > > > > > > On 14/04/2010, ben.cuthbert@hsbcib.com wrote: > > Hi Sebb > > > > I have attached screenshots of my test plan. When the test starts the > > following logging statement has been placed in the sampler. But the host > > values does not get populated > > with what is defined in the UDV. > > Did you try using a Debug Sampler? > > Please don't send attachments to the list - they are too heavy and > tend to fall off ;-) > > Upload them somewhere public and post the URL instead. > > > 010/04/14 09:54:02 INFO - jmeter.engine.StandardJMeterEngine: Running > the > > test! > > 2010/04/14 09:54:02 INFO - jmeter.gui.util.JMeterMenuBar: setRunning > > (true,*local*) > > 2010/04/14 09:54:02 INFO - jmeter.engine.StandardJMeterEngine: Starting > 1 > > threads for group Thread Group. Ramp up = 50. > > 2010/04/14 09:54:02 INFO - jmeter.engine.StandardJMeterEngine: Test > will > > stop on error > > 2010/04/14 09:54:02 INFO - jmeter.engine.StandardJMeterEngine: All > threads > > have been started > > 2010/04/14 09:54:02 INFO - jmeter.threads.JMeterThread: Thread started: > > Thread Group 1-1 > > 2010/04/14 09:54:03 INFO - > > com.hsbc.jmeter.protocol.test.samplerTestSampler: Starting sampler > > (Host:FIXMessageSampler.remoteHost,Port:FIXMessageSampler.remotePort) > > 2010/04/14 09:54:04 INFO - > > com.hsbc.jmeter.protocol.test.samplerTestSampler Starting sampler > > (Host:FIXMessageSampler.remoteHost,Port:FIXMessageSampler.remotePort) > > 2010/04/14 09:54:05 INFO - > > com.hsbc.jmeter.protocol.test.samplerTestSampler: Starting sampler > > (Host:FIXMessageSampler.remoteHost,Port:FIXMessageSampler.remotePort) > > > > > > (Embedded image moved to file: pic19853.gif) > > > > > > (Embedded image moved to file: pic29034.gif) > > > > > > > > > > Regards > > > > > > > > > > > > __________________________________________________________ > > > > > > > > Deepak Shetty > > > > > To > > JMeter Users List > > > > Apr 13 2010 18:07 > > > cc > > Mail Size: 13872 > > > > > Subject > > Re: User defined variables > > > > Please respond to > > > > "JMeter Users > Entity > > > > List" > > > ta.apache.org> > > > > > > > > > > > > > > Hi > > I dont know much about the samplers so youll probably have to wait for > sebb > > to reply. > > However User defined variables apply at runtime. Whereas you seem to be > > asking about load and store from the JMX file (in which case $ {SERVER} > is > > correct , the value will get replaced at runtime > > regards > > deepak > > > > On Tue, Apr 13, 2010 at 9:17 AM, wrote: > > > > > Yes sorry. > > > > > > So I have a sample that looks like > > > > > > public class TestSampler extends AbstractSampler implements > TestListener > > { > > > > > > public final static String HOST = "TestSampler.remoteHost"; > > > > > > > > > public final void setHost(String newServer) { > > > this.setProperty(HOST, newServer); > > > } > > > > > > public final String getHost() { > > > return getPropertyAsString(HOST); > > > } > > > } > > > > > > Now I would like to set this values based on a user defined variable > > config > > > above this sampler. > > > So in my GUI config class for this sampler I have > > > > > > > > > public class TestSamplerGui extends AbstractSamplerGui implements > > > ActionListener, ChangeListener { > > > > > > private final JLabeledTextField remoteHost = new JLabeledTextField( > > > "Remote host"); //$NON-NLS-1$ > > > > > > @Override > > > protected void configureTestElement(TestElement mc) { > > > remoteHost.setText(mc.getPropertyAsString > (TestSampler.HOST)); > > > } > > > > > > > > > public TestElement createTestElement() { > > > TestSampler sampler = new TestSampler (); > > > modifyTestElement(sampler); > > > > > > return sampler; > > > } > > > > > > > > > public void modifyTestElement(TestElement s) { > > > TestSamplerGui sampler = (TestSamplerGui ) s; > > > this.configureTestElement(sampler); > > > sampler.setProperty > (FIXProtocolMessageSampler.HOST,this.remoteHost > > > .getText()); > > > } > > > } > > > > > > So the first time if you set the value for remote host on the front > end > > > within the sampler gui it writes it to the .xml file. But when you > load > > it > > > again > > > and try and update the host it just pulls the old value back because > of > > the > > > configureTestElement() method. > > > > > > This was copied from the FTPSampler on trunk > > > > > > > > > Regards > > > > > > > > > Ben CUTHBERT > > > > > > > > > Futures and Options > > > 8 Canada Square,Canary Wharf,London,E14 5HQ,United Kingdom > > > > > > > > > __________________________________________________________ > > > > > > > > > Phone. +44 (0) 20 799 22192 > > > > > > > > > Email. ben.cuthbert@hsbcib.com > > > > > > > > > __________________________________________________________ > > > > > > > > > > > > Deepak Shetty > > > > > > > To > > > JMeter Users List > > > Apr 13 2010 17:11 > > > > > cc > > > Mail Size: 9388 > > > > > Subject > > > Re: User defined variables > > > > > > Please respond to > > > "JMeter Users > > > List" > > > > > ta.apache.org> > > > > > > > > > > > > > > > > > > > > > Sorry I think i misunderstood your question. > > > You are writing a custom sampler and you have defined a field in it > and > > you > > > want to pass in a variable? > > > > > > regards > > > deepak > > > > > > On Tue, Apr 13, 2010 at 8:58 AM, wrote: > > > > > > > I think it is something in the GUI Config class. > > > > > > > > Is there a template anywhere that I can base my GUI code off? > > > > Regards > > > > > > > > > > > > > > > > > > > > > > > > __________________________________________________________ > > > > > > > > > > > > > > > > Deepak Shetty > > > > > > > > > > To > > > > JMeter Users List > > > > Apr 13 2010 16:55 > > > > > > > cc > > > > Mail Size: 7046 > > > > > > Subject > > > > Re: User defined variables > > > > > > > > Please respond to > > > > "JMeter Users > > > > List" > > > > > > > ta.apache.org> > > > > > > > > > > > > > > > > > > > > > > > > > > > > should have worked . There might be a case mismatch or whitespace or > > > > something in the UDV. if you have verified that then what is your > exact > > > > Test > > > > Structure and definition?(also did you get any errors in jmeter.log) > > > > > > > > On Tue, Apr 13, 2010 at 2:49 AM, wrote: > > > > > > > > > > > > > > All > > > > > > > > > > Could how do I get my sampler to access user defined variables. > When > > I > > > > set > > > > > a UDV Config element inside my ThreadGroup and put ${SERVER} in > one > > of > > > > the > > > > > text fields in my SamplerGUI > > > > > the sample gui just puts ${SERVER} in the Sampler variable. Am I > > > missing > > > > > something. Is there an example Sampler one could use. > > > > > > > > > > > > > > > > > > > > > > > > > ----------------------------------------- > > > > > SAVE PAPER - THINK BEFORE YOU PRINT! > > > > > > > > > > This transmission has been issued by a member of the HSBC Group > > > > > "HSBC" for the information of the addressee only and should not be > > > > > reproduced and/or distributed to any other person. Each page > > > > > attached hereto must be read in conjunction with any disclaimer > > > > > which forms part of it. Unless otherwise stated, this transmission > > > > > is neither an offer nor the solicitation of an offer to sell or > > > > > purchase any investment. Its contents are based on information > > > > > obtained from sources believed to be reliable but HSBC makes no > > > > > representation and accepts no responsibility or liability as to > its > > > > > completeness or accuracy. > > > > > > > > > > > --------------------------------------------------------------------- > > > > > To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org > > > > > For additional commands, e-mail: > jmeter-user-help@jakarta.apache.org > > > > > > > > > > > > > > > > > > > > > > ----------------------------------------- > > > > SAVE PAPER - THINK BEFORE YOU PRINT! > > > > > > > > This transmission has been issued by a member of the HSBC Group > > > > "HSBC" for the information of the addressee only and should not be > > > > reproduced and/or distributed to any other person. Each page > > > > attached hereto must be read in conjunction with any disclaimer > > > > which forms part of it. Unless otherwise stated, this transmission > > > > is neither an offer nor the solicitation of an offer to sell or > > > > purchase any investment. Its contents are based on information > > > > obtained from sources believed to be reliable but HSBC makes no > > > > representation and accepts no responsibility or liability as to its > > > > completeness or accuracy. > > > > > > > > > --------------------------------------------------------------------- > > > > To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org > > > > For additional commands, e-mail: jmeter-user-help@jakarta.apache.org > > > > > > > > > > > > > > > > > ----------------------------------------- > > > SAVE PAPER - THINK BEFORE YOU PRINT! > > > > > > This transmission has been issued by a member of the HSBC Group > > > "HSBC" for the information of the addressee only and should not be > > > reproduced and/or distributed to any other person. Each page > > > attached hereto must be read in conjunction with any disclaimer > > > which forms part of it. Unless otherwise stated, this transmission > > > is neither an offer nor the solicitation of an offer to sell or > > > purchase any investment. Its contents are based on information > > > obtained from sources believed to be reliable but HSBC makes no > > > representation and accepts no responsibility or liability as to its > > > completeness or accuracy. > > > > > > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org > > > For additional commands, e-mail: jmeter-user-help@jakarta.apache.org > > > > > > > > > > > > > > > > ************************************************************ > > HSBC Bank plc may be solicited in the course of its placement efforts > for a > > new issue, by investment clients of the firm for whom the Bank as a firm > > already provides other services. It may equally decide to allocate to > its > > own proprietary book or with an associate of HSBC Group. This represents > a > > potential conflict of interest. HSBC Bank plc has internal arrangements > > designed to ensure that the firm would give unbiased and full advice to > the > > corporate finance client about the valuation and pricing of the offering > as > > well as internal systems, controls and procedures to identify and manage > > conflicts of interest. > > > > HSBC Bank plc > > Registered Office: 8 Canada Square, London E14 5HQ, United Kingdom > > Registered in England - Number 14259 > > Authorised and regulated by the Financial Services Authority. > > ************************************************************ > > > > > > ----------------------------------------- > > SAVE PAPER - THINK BEFORE YOU PRINT! > > > > This transmission has been issued by a member of the HSBC Group > > "HSBC" for the information of the addressee only and should not be > > reproduced and/or distributed to any other person. Each page > > attached hereto must be read in conjunction with any disclaimer > > which forms part of it. Unless otherwise stated, this transmission > > is neither an offer nor the solicitation of an offer to sell or > > purchase any investment. Its contents are based on information > > obtained from sources believed to be reliable but HSBC makes no > > representation and accepts no responsibility or liability as to its > > completeness or accuracy. > > > > > > --------------------------------------------------------------------- > > 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 > > > > > ************************************************************ > HSBC Bank plc may be solicited in the course of its placement efforts for a > new issue, by investment clients of the firm for whom the Bank as a firm > already provides other services. It may equally decide to allocate to its > own proprietary book or with an associate of HSBC Group. This represents a > potential conflict of interest. HSBC Bank plc has internal arrangements > designed to ensure that the firm would give unbiased and full advice to the > corporate finance client about the valuation and pricing of the offering as > well as internal systems, controls and procedures to identify and manage > conflicts of interest. > > HSBC Bank plc > Registered Office: 8 Canada Square, London E14 5HQ, United Kingdom > Registered in England - Number 14259 > Authorised and regulated by the Financial Services Authority. > ************************************************************ > > > ************************************************************ > HSBC Bank plc may be solicited in the course of its placement efforts for a > new issue, by investment clients of the firm for whom the Bank as a firm > already provides other services. It may equally decide to allocate to its > own proprietary book or with an associate of HSBC Group. This represents a > potential conflict of interest. HSBC Bank plc has internal arrangements > designed to ensure that the firm would give unbiased and full advice to the > corporate finance client about the valuation and pricing of the offering as > well as internal systems, controls and procedures to identify and manage > conflicts of interest. > > HSBC Bank plc > Registered Office: 8 Canada Square, London E14 5HQ, United Kingdom > Registered in England - Number 14259 > Authorised and regulated by the Financial Services Authority. > ************************************************************ > > ----------------------------------------- > SAVE PAPER - THINK BEFORE YOU PRINT! > > This transmission has been issued by a member of the HSBC Group > "HSBC" for the information of the addressee only and should not be > reproduced and/or distributed to any other person. Each page > attached hereto must be read in conjunction with any disclaimer > which forms part of it. Unless otherwise stated, this transmission > is neither an offer nor the solicitation of an offer to sell or > purchase any investment. Its contents are based on information > obtained from sources believed to be reliable but HSBC makes no > representation and accepts no responsibility or liability as to its > completeness or accuracy. > > --------------------------------------------------------------------- > 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 ************************************************************ HSBC Bank plc may be solicited in the course of its placement efforts for a new issue, by investment clients of the firm for whom the Bank as a firm already provides other services. It may equally decide to allocate to its own proprietary book or with an associate of HSBC Group. This represents a potential conflict of interest. HSBC Bank plc has internal arrangements designed to ensure that the firm would give unbiased and full advice to the corporate finance client about the valuation and pricing of the offering as well as internal systems, controls and procedures to identify and manage conflicts of interest. HSBC Bank plc Registered Office: 8 Canada Square, London E14 5HQ, United Kingdom Registered in England - Number 14259 Authorised and regulated by the Financial Services Authority. ************************************************************ ----------------------------------------- SAVE PAPER - THINK BEFORE YOU PRINT! This transmission has been issued by a member of the HSBC Group "HSBC" for the information of the addressee only and should not be reproduced and/or distributed to any other person. Each page attached hereto must be read in conjunction with any disclaimer which forms part of it. Unless otherwise stated, this transmission is neither an offer nor the solicitation of an offer to sell or purchase any investment. Its contents are based on information obtained from sources believed to be reliable but HSBC makes no representation and accepts no responsibility or liability as to its completeness or accuracy. --------------------------------------------------------------------- To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: jmeter-user-help@jakarta.apache.org