How to test response time per one request in ROR

I’m try test response time per one request in ROR but I don’t know how
to do?
Could you give me some advice? Thanks…

Thank Robert
I read in http://guides.rubyonrails.org/performance_testing.html
I found with Wall Time,Process Time,User Time,Objects…Can I use this
value same as test response time for 1 request in ROR.Thanks…

haxuan lac wrote in post #1103466:

I’m try test response time per one request in ROR but I don’t know how
to do?
Could you give me some advice? Thanks…

There are many ways to do this. The simplest is to just look at your
Rails log. It logs the response times of every request that the server
receives.

Another good way to do this is use your browser’s built-in developer
tools (or plugin such as FireBug). I use the excellent Web Inspector in
Safari (or Chrome). Web Inspector will produce a nice graph detailing
out the time for a request, along with the load times for each asset.

Web Inspector Timeline:
https://developer.apple.com/library/safari/#documentation/AppleApplications/Conceptual/Safari_Developer_Guide/OptimizingYourWebsite/OptimizingYourWebsite.html#//apple_ref/doc/uid/TP40007874-CH9-SW1

Another quick-and-dirty way to get a rough idea of request time is by
using the “time” command with curl (assuming a *NIX like OS).

Note, however, that this is going to measure the response time to get
the HTML, which doesn’t necessarily mean that the entire page is fully
rendered and all the page assets have been downloaded and rendered.

time curl http://example.com/my_page

I know you may hear lots about Requests per Minute (RPM), but the
reality is that it is much more complex than that. In order to really
get a good understanding of your overall site performance, and to
monitor it over time you need to use on of the services built to provide
you this data.

http://newrelic.com
https://scoutapp.com

haxuan lac wrote in post #1103550:

Thank Robert
I read in http://guides.rubyonrails.org/performance_testing.html
I found with Wall Time,Process Time,User Time,Objects…Can I use this
value same as test response time for 1 request in ROR.Thanks…

If you have performance test cases then sure. I haven’t tried these
myself, but I would imaging that this gathers the times that are shown
in the Rails log file and outputs them in a more presentable format.

I wasn’t really considering test cases because your original question
sounded like you were looking for sort of 1-off benchmarks. I also
noticed from that guid the “rails benchmark” command for performing
1-off benchmarks. You might look into that.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs