|
|
Created:
4 years, 4 months ago by maksims (do not use this acc) Modified:
4 years, 3 months ago CC:
chromium-reviews, rsleevi+watch_chromium.org, certificate-transparency-chrome_googlegroups.com, cbentzel+watch_chromium.org, Eran Messeri Base URL:
https://chromium.googlesource.com/chromium/src.git@URLRequestRead Target Ref:
refs/pending/heads/master Project:
chromium Visibility:
Public. |
DescriptionUse modified URLRequest::Read() and delegate methods in components/
This CL modifies clients that use URLRequest::Read() method
or implement net::Delegate/net::NetworkDelegate methods
and makes them to use returned networking errors instead,
which are returned in term of int.
Old implementation of URLRequest::Read() used to set its
status inside the URLRequest object itself and clients
used to check the status by calling request->status().
The main CL that changes URLRequest::Read and delegate
methods is here - https://codereview.chromium.org/2262653003
BUG=423484
Committed: https://crrev.com/1faf924e0dc99a797084918fc04bc6a688e2cd4c
Cr-Commit-Position: refs/heads/master@{#419413}
Patch Set 1 : componets #
Total comments: 16
Patch Set 2 : remove domain_reliability from thic cl #Patch Set 3 : comments #Patch Set 4 : comments #Messages
Total messages: 86 (72 generated)
Description was changed from ========== djust callers and networking delegates in components/ to modified APIs BUG= ========== to ========== Adjust callers and networking delegates in components/ to modified APIs BUG= ==========
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: android_arm64_dbg_recipe on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_arm6...) linux_chromium_chromeos_compile_dbg_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
Patchset #1 (id:1) has been deleted
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Patchset #1 (id:20001) has been deleted
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: cast_shell_android on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/cast_shell_a...)
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: ios-device on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios-device/builds...)
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_chromium_chromeos_ozone_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_chromium_chromeos_ozone_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Description was changed from ========== Adjust callers and networking delegates in components/ to modified APIs BUG= ========== to ========== Use modified URLRequest::Read() and delegate methods in components/ Use modified Read and delegate methods from the following CL - https://codereview.chromium.org/2262653003/ BUG=423484 ==========
Patchset #4 (id:100001) has been deleted
Patchset #3 (id:80001) has been deleted
Patchset #2 (id:60001) has been deleted
Patchset #1 (id:40001) has been deleted
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: ios-simulator on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios-simulator/bui...)
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_chromium_chromeos_ozone_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...) mac_chromium_compile_dbg_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_comp...)
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: ios-simulator on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios-simulator/bui...)
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_android_rel_ng on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/linux_androi...)
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Patchset #4 (id:180001) has been deleted
Patchset #3 (id:160001) has been deleted
Patchset #2 (id:140001) has been deleted
Patchset #1 (id:120001) has been deleted
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
PTAL rsleevi@: components/certificate_transparency/log_proof_fetcher.cc mmenke@: components/cronet/android/* bengr@: components/data_reduction_proxy/core/* davidben@: components/domain_reliability/*
maksim.sisov@intel.com changed reviewers: + bengr@chromium.org, davidben@chromium.org, mmenke@chromium.org, rsleevi@chromium.org
PTAL rsleevi@: components/certificate_transparency/log_proof_fetcher.cc mmenke@: components/cronet/android/* bengr@: components/data_reduction_proxy/core/* davidben@: components/domain_reliability/*
Please update the commit description to better reflect what this code does. A good primer on this is http://chris.beams.io/posts/git-commit/
Description was changed from ========== Use modified URLRequest::Read() and delegate methods in components/ Use modified Read and delegate methods from the following CL - https://codereview.chromium.org/2262653003/ BUG=423484 ========== to ========== Use modified URLRequest::Read() and delegate methods in components/ This CL modifies clients that use URLRequest::Read() method or implement net::Delegate/net::NetworkDelegate methods and makes them to use returned networking errors instead, which are returned in term of int. Old implementation of URLRequest::Read() used to set its status inside the URLRequest object itself and clients used to check the status by calling request->status(). The main CL that changes URLRequest::Read and delegate methods is here - https://codereview.chromium.org/2262653003 BUG=423484 ==========
On 2016/09/06 16:15:34, Ryan Sleevi (slow) wrote: > Please update the commit description to better reflect what this code does. > > A good primer on this is http://chris.beams.io/posts/git-commit/ please check
https://codereview.chromium.org/2261103002/diff/200001/components/domain_reli... File components/domain_reliability/monitor.cc (right): https://codereview.chromium.org/2261103002/diff/200001/components/domain_reli... components/domain_reliability/monitor.cc:173: // TODO(maksims): Make this take net_error. It does not appear this CL does not actually do anything to this directory except lose the logic in URLRequestStatusToNetError. I think this TODO needs to be resolved at the same time as converting this directory. So either remove the changes to this directory and leave it for later or fully route the net_error out of URLRequest correctly. https://codereview.chromium.org/2261103002/diff/200001/components/domain_reli... File components/domain_reliability/monitor.h (right): https://codereview.chromium.org/2261103002/diff/200001/components/domain_reli... components/domain_reliability/monitor.h:147: explicit RequestInfo(const net::URLRequest& request, int net_error); No need for 'explicit' with two arguments.
Cronet LGTM https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... File components/cronet/android/cronet_url_request_adapter.cc (right): https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/cronet_url_request_adapter.cc:274: ReportError(request, bytes_read); Early return is generally preferred, and it's generally easiest to follow code that handles errors before success. https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/cronet_url_request_adapter.cc:354: if (bytes_read == net::ERR_IO_PENDING) nit: bytes_read -> result. https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/cronet_url_request_adapter.cc:371: DCHECK_NE(net::ERR_IO_PENDING, net_error); Suggest also DCHECK_LT(new_error, 0); https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... File components/cronet/android/url_request_adapter.cc (right): https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/url_request_adapter.cc:244: int bytes_read = url_request_->Read(read_buffer_.get(), kReadBufferSize); nit: bytes_read -> result https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/url_request_adapter.cc:254: bool URLRequestAdapter::HandleReadResult(int bytes_read) { bytes_read -> result https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/url_request_adapter.cc:260: } else if (bytes_read == 0) { pre-existing issue, but while you're here, mind removing this else? https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/url_request_adapter.cc:306: void URLRequestAdapter::OnRequestFailed(int net_error) { Suggest adding: DCHECK_LE(net_error, 0); DCHECK_NE(ERR_IO_PENDING, net_error);
lgtm https://codereview.chromium.org/2261103002/diff/200001/components/certificate... File components/certificate_transparency/log_proof_fetcher.cc (right): https://codereview.chromium.org/2261103002/diff/200001/components/certificate... components/certificate_transparency/log_proof_fetcher.cc:149: // Check for an error condition. You can drop this line; it no longer grammatically fits with the rest of the code (and probably shouldn't have been included on 137 to begin with)
components/data_reduction_proxy/* lgtm
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_android_rel_ng on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/linux_androi...)
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... File components/cronet/android/cronet_url_request_adapter.cc (right): https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/cronet_url_request_adapter.cc:274: ReportError(request, bytes_read); On 2016/09/06 17:57:58, mmenke wrote: > Early return is generally preferred, and it's generally easiest to follow code > that handles errors before success. Done. https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/cronet_url_request_adapter.cc:354: if (bytes_read == net::ERR_IO_PENDING) On 2016/09/06 17:57:58, mmenke wrote: > nit: bytes_read -> result. Done. https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/cronet_url_request_adapter.cc:371: DCHECK_NE(net::ERR_IO_PENDING, net_error); On 2016/09/06 17:57:58, mmenke wrote: > Suggest also DCHECK_LT(new_error, 0); Done. https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... File components/cronet/android/url_request_adapter.cc (right): https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/url_request_adapter.cc:260: } else if (bytes_read == 0) { On 2016/09/06 17:57:58, mmenke wrote: > pre-existing issue, but while you're here, mind removing this else? Do you mean to do this - if (result == 0) { ... return false; } ??? Or to remove completely? https://codereview.chromium.org/2261103002/diff/200001/components/cronet/andr... components/cronet/android/url_request_adapter.cc:306: void URLRequestAdapter::OnRequestFailed(int net_error) { On 2016/09/06 17:57:58, mmenke wrote: > Suggest adding: > > DCHECK_LE(net_error, 0); > DCHECK_NE(ERR_IO_PENDING, net_error); Done. https://codereview.chromium.org/2261103002/diff/200001/components/domain_reli... File components/domain_reliability/monitor.cc (right): https://codereview.chromium.org/2261103002/diff/200001/components/domain_reli... components/domain_reliability/monitor.cc:173: // TODO(maksims): Make this take net_error. On 2016/09/06 17:07:28, davidben wrote: > It does not appear this CL does not actually do anything to this directory > except lose the logic in URLRequestStatusToNetError. I think this TODO needs to > be resolved at the same time as converting this directory. So either remove the > changes to this directory and leave it for later or fully route the net_error > out of URLRequest correctly. Thank you for your feedback. I'll leave this for second iteration then after all the other changes land, otherwise I'll have to change quite a lot, becuase this method is overridden by other clients as well.
mmenke@, can I commit this or better wait? what do you think?
On 2016/09/12 12:12:48, maksims wrote: > mmenke@, can I commit this or better wait? what do you think? It's up to you. I'd try not landing it at the same time as the others, as you incrementally see if the crash will reappear, but I think you're fine to land at your leisure.
The CQ bit was checked by maksim.sisov@intel.com to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
The CQ bit was checked by maksim.sisov@intel.com
The patchset sent to the CQ was uploaded after l-g-t-m from bengr@chromium.org, mmenke@chromium.org, rsleevi@chromium.org Link to the patchset: https://codereview.chromium.org/2261103002/#ps260001 (title: "comments")
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Message was sent while issue was closed.
Description was changed from ========== Use modified URLRequest::Read() and delegate methods in components/ This CL modifies clients that use URLRequest::Read() method or implement net::Delegate/net::NetworkDelegate methods and makes them to use returned networking errors instead, which are returned in term of int. Old implementation of URLRequest::Read() used to set its status inside the URLRequest object itself and clients used to check the status by calling request->status(). The main CL that changes URLRequest::Read and delegate methods is here - https://codereview.chromium.org/2262653003 BUG=423484 ========== to ========== Use modified URLRequest::Read() and delegate methods in components/ This CL modifies clients that use URLRequest::Read() method or implement net::Delegate/net::NetworkDelegate methods and makes them to use returned networking errors instead, which are returned in term of int. Old implementation of URLRequest::Read() used to set its status inside the URLRequest object itself and clients used to check the status by calling request->status(). The main CL that changes URLRequest::Read and delegate methods is here - https://codereview.chromium.org/2262653003 BUG=423484 ==========
Message was sent while issue was closed.
Committed patchset #4 (id:260001)
Message was sent while issue was closed.
Description was changed from ========== Use modified URLRequest::Read() and delegate methods in components/ This CL modifies clients that use URLRequest::Read() method or implement net::Delegate/net::NetworkDelegate methods and makes them to use returned networking errors instead, which are returned in term of int. Old implementation of URLRequest::Read() used to set its status inside the URLRequest object itself and clients used to check the status by calling request->status(). The main CL that changes URLRequest::Read and delegate methods is here - https://codereview.chromium.org/2262653003 BUG=423484 ========== to ========== Use modified URLRequest::Read() and delegate methods in components/ This CL modifies clients that use URLRequest::Read() method or implement net::Delegate/net::NetworkDelegate methods and makes them to use returned networking errors instead, which are returned in term of int. Old implementation of URLRequest::Read() used to set its status inside the URLRequest object itself and clients used to check the status by calling request->status(). The main CL that changes URLRequest::Read and delegate methods is here - https://codereview.chromium.org/2262653003 BUG=423484 Committed: https://crrev.com/1faf924e0dc99a797084918fc04bc6a688e2cd4c Cr-Commit-Position: refs/heads/master@{#419413} ==========
Message was sent while issue was closed.
Patchset 4 (id:??) landed as https://crrev.com/1faf924e0dc99a797084918fc04bc6a688e2cd4c Cr-Commit-Position: refs/heads/master@{#419413} |