| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "net/spdy/spdy_stream.h" | 5 #include "net/spdy/spdy_stream.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
| 9 #include "base/singleton.h" | |
| 10 #include "base/values.h" | 9 #include "base/values.h" |
| 11 #include "net/spdy/spdy_session.h" | 10 #include "net/spdy/spdy_session.h" |
| 12 | 11 |
| 13 namespace net { | 12 namespace net { |
| 14 | 13 |
| 15 namespace { | 14 namespace { |
| 16 | 15 |
| 17 class NetLogSpdyStreamWindowUpdateParameter : public NetLog::EventParameters { | 16 class NetLogSpdyStreamWindowUpdateParameter : public NetLog::EventParameters { |
| 18 public: | 17 public: |
| 19 NetLogSpdyStreamWindowUpdateParameter(spdy::SpdyStreamId stream_id, | 18 NetLogSpdyStreamWindowUpdateParameter(spdy::SpdyStreamId stream_id, |
| (...skipping 20 matching lines...) Expand all Loading... |
| 40 spdy::SpdyStreamId stream_id, | 39 spdy::SpdyStreamId stream_id, |
| 41 bool pushed, | 40 bool pushed, |
| 42 const BoundNetLog& net_log) | 41 const BoundNetLog& net_log) |
| 43 : continue_buffering_data_(true), | 42 : continue_buffering_data_(true), |
| 44 stream_id_(stream_id), | 43 stream_id_(stream_id), |
| 45 priority_(0), | 44 priority_(0), |
| 46 stalled_by_flow_control_(false), | 45 stalled_by_flow_control_(false), |
| 47 send_window_size_(spdy::kSpdyStreamInitialWindowSize), | 46 send_window_size_(spdy::kSpdyStreamInitialWindowSize), |
| 48 recv_window_size_(spdy::kSpdyStreamInitialWindowSize), | 47 recv_window_size_(spdy::kSpdyStreamInitialWindowSize), |
| 49 pushed_(pushed), | 48 pushed_(pushed), |
| 50 metrics_(Singleton<BandwidthMetrics>::get()), | |
| 51 response_received_(false), | 49 response_received_(false), |
| 52 session_(session), | 50 session_(session), |
| 53 delegate_(NULL), | 51 delegate_(NULL), |
| 54 request_time_(base::Time::Now()), | 52 request_time_(base::Time::Now()), |
| 55 response_(new spdy::SpdyHeaderBlock), | 53 response_(new spdy::SpdyHeaderBlock), |
| 56 io_state_(STATE_NONE), | 54 io_state_(STATE_NONE), |
| 57 response_status_(OK), | 55 response_status_(OK), |
| 58 cancelled_(false), | 56 cancelled_(false), |
| 59 has_upload_data_(false), | 57 has_upload_data_(false), |
| 60 net_log_(net_log), | 58 net_log_(net_log), |
| (...skipping 517 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 578 UMA_HISTOGRAM_TIMES("Net.SpdyStreamDownloadTime", | 576 UMA_HISTOGRAM_TIMES("Net.SpdyStreamDownloadTime", |
| 579 recv_last_byte_time_ - recv_first_byte_time_); | 577 recv_last_byte_time_ - recv_first_byte_time_); |
| 580 UMA_HISTOGRAM_TIMES("Net.SpdyStreamTime", | 578 UMA_HISTOGRAM_TIMES("Net.SpdyStreamTime", |
| 581 recv_last_byte_time_ - send_time_); | 579 recv_last_byte_time_ - send_time_); |
| 582 | 580 |
| 583 UMA_HISTOGRAM_COUNTS("Net.SpdySendBytes", send_bytes_); | 581 UMA_HISTOGRAM_COUNTS("Net.SpdySendBytes", send_bytes_); |
| 584 UMA_HISTOGRAM_COUNTS("Net.SpdyRecvBytes", recv_bytes_); | 582 UMA_HISTOGRAM_COUNTS("Net.SpdyRecvBytes", recv_bytes_); |
| 585 } | 583 } |
| 586 | 584 |
| 587 } // namespace net | 585 } // namespace net |
| OLD | NEW |