This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Request: 0 | |
Start Time: Thu Aug 02 09:40:24 BRT 2012 | |
End time: Thu Aug 02 09:41:07 BRT 2012 | |
Thread id: 15 | |
Sampling start time: Thu Aug 02 09:40:30 BRT 2012 | |
Sampling end time: Thu Aug 02 09:41:07 BRT 2012 | |
# Contents of Request.toString() goes here |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void processRequest(Integer param1,String param2) { | |
MyRequest request=new MyRequest(param1, param2); | |
requestManager.requestStarting(request); | |
// Process the request as usual... | |
requestManager.requestFinished(request); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.logicstyle.samplr.Request; | |
public class MyRequest extends Request { | |
private Integer requestParam1; | |
private String requestParam2; | |
public MyRequest(Integer requestParam1, String requestParam2) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RequestManager requestManager=new RequestManager() | |
.withRequestProcessor(new ThreadSamplingRequestProcessor() | |
.withRequestLengthSamplingThreshold(60000L)) | |
.withRequestProcessor(new RequestRecorderRequestProcessor()) | |
.withResultsProcessor(new FileResultsArchiver() | |
.withOutputDirectory(new File("/home/glassfish/samplr-output"))) | |
.withRequestTimeout(300000L); | |