Is there any way(point) to know size of the HTTP request sent handset to server?

1 view
Skip to first unread message

sso

unread,
May 14, 2009, 9:21:25 PM5/14/09
to SteelAndroid
Recently, I've been studying HTTP request/response for Browser.
Is there any way(point) to know size of the HTTP request sent handset
to server,
includes all bytes of the request including Request-Line.

I reviewed the source code - HttpConnectionMetricslmpl.java (/
Extenal),
and found that there is "getSentBytesCount",
but whenever I call the API from sendRequest in Request.java(/
Framework),
the return value is "0".


Where is the point to know the size of the HTTP request send handset
to server,
Or is there any other method to know that?


Thanks..

kolbysoft

unread,
May 15, 2009, 8:43:36 AM5/15/09
to SteelAndroid
I'm not sure I understand what you want to do. The class and methods
you describe give you the metrics of an http request IF you're making
the request from your code using the HttpClient library yourself.
The browser on Android, or Steel for that matter, don't use the
HttpClient library, they use the native lib used by the webkit engine.
So, you can only measure traffic for requests you initiate form within
your code, the webkit traffic is transparent to the system.

Michael
Reply all
Reply to author
Forward
0 new messages