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 priya menon <pr...@yahoo.com> on 2006/10/07 05:12:12 UTC
Want to become a developer
I have read about JMeter after going through the Apache's site and I found it very interesting.
I want to start as an user and If i am able to sustain the interest and become enough productive, I want to become a developer.
I have played around JMeter, a little.
Trying to create a sampler:
Customer Sampler: I am trying to write a custom sampler just to display sub results in a table and I created a jar and dropped in /lib/ext. Added a sampler Java Requests and ran this stuff.
I did the following steps:
Trying to visualize and see these 3 values sperately in a table, I created a plan and threadgroup and the I found only 2 ways to view results in table and aggregate report. but both are getting the aggregate values. Is there a table component to see this values as a row or column or do I have to write my own custom visualizer.
public SampleResult runTest(JavaSamplerContext context) {
SampleResult results = new SampleResult();
try {
Thread.sleep(2000);
// Generate a random value using the current time.
results.setSuccessful(true);
results.setSampleLabel("PriyaTest");
SampleResult r = new SampleResult();
r.setSampleLabel("Priya Result1");
r.setTime(200);
results.addSubResult(r);
SampleResult r1 = new SampleResult();
r1.setSampleLabel("Priya Result2");
r1.setTime(300);
results.addSubResult(r1);
SampleResult r2 = new SampleResult();
r1.setSampleLabel("Priya Result3");
r1.setTime(500);
results.addSubResult(r2);
} catch (Exception e) {
getLogger().error("SleepTest: error during sample", e);
results.setSuccessful(false);
} finally {
results.sampleEnd();
}
if (getLogger().isDebugEnabled()) {
getLogger().debug(
whoAmI() + "\trunTest()" + "\tTime:\t" + results.getTime());
listParameters(context);
}
return results;
}
---------------------------------
Get your email and more, right on the new Yahoo.com