Check proxy reply time

kylemaes

Newbie
Joined
Jul 30, 2012
Messages
7
Reaction score
0
Hi BHW! I was wondering if it was possible to check proxys reply time from google? I have nothing nor can I find anything. I know all the functions that connect to websites through proxys and such and I am using them as I type this. But none of the functions return the time it took to execute the function or what not... Any ideas? Thanks.
 
Yes, I've seen that. I was wondering how big is the instruction execution time I want a pretty precise measurement. Is this +-10 output?
 
Yes, I've seen that. I was wondering how big is the instruction execution time I want a pretty precise measurement. Is this +-10 output?

If you take the time to read the link he posted, you'd see its down to microseconds. So yes, it is accurate within 10 seconds.
 
That is not what I meant,

I meant that it has a +-10ms, but I am wondering because the execution time to find the time and to start contacting the proxy server and such will probably take more than 10 ms...
 
1000 microseconds = 1 millisecond

The timer can be started anytime and can be used anywhere. You can time the entire script, individual functions, class response etc.
Code:
<?php
foreach ($proxies as $proxy) {
    $start = microtime(true);
    /* Code to connect and valdiate.  Whatever you want to time */
    $end = microtime(true);
    $total_time = $end - $start;
}
?>
 
I'm sorry. I think we are having a communication problem :(

I know exactly how the microtime works and such.
But im wondering the time to transfer the variable returned to another variable would come up into the timer because I have to take the data from the function after mutiple times.. It is ok I'll run some tests to get it accurate to the millisecond... Thankyou guys :D

You might not do microcontrollers and hardware design. I do that kind of thing and am just learning this for my website. But I refer to instuructions of cycles constantly because when working with microcontrollers and serial/parrallel interfacing you have to get the most precise timing you can do reduce error and increase speed...
 
Last edited:
I'm sorry. I think we are having a communication problem :(

I know exactly how the microtime works and such.
But im wondering the time to transfer the variable returned to another variable would come up into the timer because I have to take the data from the function after mutiple times.. It is ok I'll run some tests to get it accurate to the millisecond... Thankyou guys :D

You might not do microcontrollers and hardware design. I do that kind of thing and am just learning this for my website. But I refer to instuructions of cycles constantly because when working with microcontrollers and serial/parrallel interfacing you have to get the most precise timing you can do reduce error and increase speed...

Yeah, communication does seem to be a problem lol

There can be some inherent delay when recording the values. So in my example, the execution time would be off due to the microtime start and stops along with their assigning values. Fixing or reducing the margin of error would likely need to be done as a PHP C Module where you have more flexibility and low level access. Anything that would try and fix it in PHP would probably be off due to the same memory time.

and sorry about being kind of hostile earlier, people ask the same thing over and over and never read. Wasn't aware you needed precision to such a point, or that you already knew what microtime was.
 
Last edited:
You could also use XDebug as well and compare results. But as Zapdos said, since you want to measure ms and not microsec, I don't see the problem. The overhead of trivial variable manipulation should not affect your results in the ms range.
 
Thankyou guys for everything.

Zapdos, I understand, it's ok :P
 
Back
Top