Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(104)

Issue 2075313002: Substituting legacy protocol with uWeave protocol (Closed)

Created:
4 years, 6 months ago by jingxuy
Modified:
4 years, 4 months ago
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Using the uWeave packet generator and receiver to re-implement the BluetoothLowEnergyConnection class Major changes: SendMesssageImpl which instead of using the old protocol, it will just generate the message with the WeavePacketGenerator. GattCharacteristicValueChanged instead of parsing messages received with the old protocol, will now use the WeavePacketReceiver and just switch on the state of the receiver and take appropriate action. Design Doc for ProximityAuth uWeave Migration: https://docs.google.com/a/google.com/document/d/1HJ1fipxsNQwIxmKs-5_6TjroCAcs6qRhAYvOnIr6mQw/edit?usp=sharing BUG=617238 Committed: https://crrev.com/f4f0a5cde8eff464de5359281560444ff442f920 Cr-Commit-Position: refs/heads/master@{#407655}

Patch Set 1 #

Patch Set 2 : the old connection class for better diffs #

Patch Set 3 : Don't Review Yet, Not built yet, skeleton migration #

Patch Set 4 : built version of the migrated connection #

Patch Set 5 : tested and working version of the weave connection #

Total comments: 2

Patch Set 6 : renamed to weave client connection #

Total comments: 47

Patch Set 7 : mocks for unittest and sends connection close now #

Total comments: 44

Patch Set 8 : readible reason for close and removed dlog in test #

Total comments: 2

Patch Set 9 : added test for connection close #

Patch Set 10 : saved reference to generator/receiver #

Total comments: 2

Patch Set 11 : addressed minor comments #

Patch Set 12 : minor change #

Total comments: 8

Patch Set 13 : correct handling of connection close #

Total comments: 28

Patch Set 14 : fixed bug in onWriteRemoteCharacteristicError #

Patch Set 15 : added comments for sending connection close, minor change to test #

Patch Set 16 : added tests for connection close #

Total comments: 8

Patch Set 17 : actually sends message back #

Total comments: 31

Patch Set 18 : addressed stylistic comments #

Patch Set 19 : addressed stylistic comments #

Patch Set 20 : added test with OnDidSendMessage observer #

Total comments: 14

Patch Set 21 : fixed minor style problems #

Total comments: 2

Patch Set 22 : made setsubstatus private #

Patch Set 23 : fixed onWriteRemoteCharacteristicError bug #

Patch Set 24 : delete todo comment #

Patch Set 25 : removed extra log messages #

Patch Set 26 : updated gyp build files #

Total comments: 30

Patch Set 27 : addressed minor style comments #

Total comments: 2

Patch Set 28 : set status to disconnect when failed to create gatt connection #

Patch Set 29 : better ways to pass information to write characteristic callback #

Patch Set 30 : delete a space #

Patch Set 31 : fix compile error on android #

Patch Set 32 : fixed typo #

Patch Set 33 : expect true/false instead of equality #

Patch Set 34 : fix unittest memory leak #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1800 lines, -106 lines) Patch
M components/components_tests.gyp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 1 chunk +1 line, -0 lines 0 comments Download
M components/proximity_auth.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 1 chunk +2 lines, -0 lines 0 comments Download
M components/proximity_auth/ble/BUILD.gn View 1 2 3 4 5 6 2 chunks +3 lines, -0 lines 0 comments Download
A + components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 12 chunks +94 lines, -94 lines 0 comments Download
A components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 1 chunk +639 lines, -0 lines 0 comments Download
A components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 1 chunk +1049 lines, -0 lines 0 comments Download
M components/proximity_auth/ble/bluetooth_low_energy_weave_packet_generator.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 2 chunks +2 lines, -2 lines 0 comments Download
M components/proximity_auth/ble/bluetooth_low_energy_weave_packet_generator.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 1 chunk +4 lines, -4 lines 0 comments Download
M components/proximity_auth/ble/bluetooth_low_energy_weave_packet_receiver.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 2 chunks +2 lines, -2 lines 0 comments Download
M components/proximity_auth/ble/bluetooth_low_energy_weave_packet_receiver.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 1 chunk +4 lines, -4 lines 0 comments Download

Messages

Total messages: 85 (18 generated)
jingxuy
Please review the weave connection class.
4 years, 6 months ago (2016-06-24 00:02:52 UTC) #3
Kyle Horimoto
Before I start reviewing, please change the class name to reflect that it is for ...
4 years, 6 months ago (2016-06-24 00:14:09 UTC) #4
jingxuy
https://codereview.chromium.org/2075313002/diff/80001/components/proximity_auth/ble/bluetooth_low_energy_weave_connection.h File components/proximity_auth/ble/bluetooth_low_energy_weave_connection.h (right): https://codereview.chromium.org/2075313002/diff/80001/components/proximity_auth/ble/bluetooth_low_energy_weave_connection.h#newcode39 components/proximity_auth/ble/bluetooth_low_energy_weave_connection.h:39: class BluetoothLowEnergyWeaveConnection On 2016/06/24 00:14:09, Kyle Horimoto wrote: > ...
4 years, 6 months ago (2016-06-25 00:23:27 UTC) #6
Kyle Horimoto
Haven't fully reviewed the test yet. You'll have to do a bit of work getting ...
4 years, 5 months ago (2016-06-27 18:06:03 UTC) #7
sacomoto
https://codereview.chromium.org/2075313002/diff/100001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/100001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode34 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:34: const char kTXCharacteristicUUID[] = "977c6674-1239-4e72-993b-502369b8bb5a"; On 2016/06/27 18:06:02, Kyle ...
4 years, 5 months ago (2016-06-29 14:26:58 UTC) #8
jingxuy
https://codereview.chromium.org/2075313002/diff/100001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/100001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode33 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:33: // The UUID of the TX characteristic used to ...
4 years, 5 months ago (2016-06-30 00:27:21 UTC) #9
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/100001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/100001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode233 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:233: // TODO(jingxuy): what to do with the reason for ...
4 years, 5 months ago (2016-06-30 00:42:33 UTC) #10
jingxuy
https://codereview.chromium.org/2075313002/diff/100001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/100001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode233 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:233: // TODO(jingxuy): what to do with the reason for ...
4 years, 5 months ago (2016-06-30 01:14:55 UTC) #11
Kyle Horimoto
I'll review the tests more in-depth tomorrow. Going to finish up some other work tonight. ...
4 years, 5 months ago (2016-06-30 01:29:49 UTC) #12
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode420 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:420: // TODO(jingxuy): I know this is single threaded, but ...
4 years, 5 months ago (2016-06-30 02:01:25 UTC) #13
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/140001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/140001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode222 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:222: if (characteristic->GetIdentifier() == rx_characteristic_.id) { It looks like none ...
4 years, 5 months ago (2016-06-30 18:00:23 UTC) #14
jingxuy
https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode247 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:247: if (sub_status() == SubStatus::WAITING_CONNECTION_RESPONSE) On 2016/06/30 01:29:48, Kyle Horimoto ...
4 years, 5 months ago (2016-06-30 21:59:26 UTC) #15
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode420 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:420: // TODO(jingxuy): I know this is single threaded, but ...
4 years, 5 months ago (2016-06-30 22:36:12 UTC) #16
jingxuy
https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode420 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:420: // TODO(jingxuy): I know this is single threaded, but ...
4 years, 5 months ago (2016-07-01 00:00:45 UTC) #17
Kyle Horimoto
Please ping other reviewers so that we can figure out when the close connection packet ...
4 years, 5 months ago (2016-07-01 17:23:21 UTC) #18
jingxuy
https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc (right): https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc#newcode419 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc:419: On 2016/07/01 17:23:21, Kyle Horimoto wrote: > On 2016/07/01 ...
4 years, 5 months ago (2016-07-01 19:28:08 UTC) #19
sacomoto
https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode420 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:420: // TODO(jingxuy): I know this is single threaded, but ...
4 years, 5 months ago (2016-07-06 13:07:08 UTC) #20
jingxuy
https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/120001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode420 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:420: // TODO(jingxuy): I know this is single threaded, but ...
4 years, 5 months ago (2016-07-07 04:20:58 UTC) #21
Kyle Horimoto
Please add a unit test for these new cases. These are a few of the ...
4 years, 5 months ago (2016-07-07 18:04:47 UTC) #22
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode467 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:467: // TODO(sacomoto): Actually pass the current message to the ...
4 years, 5 months ago (2016-07-07 18:34:20 UTC) #23
jingxuy
https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode127 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:127: if (sub_status_ == SubStatus::CONNECTED) { On 2016/07/07 18:04:46, Kyle ...
4 years, 5 months ago (2016-07-07 23:38:48 UTC) #24
Kyle Horimoto
Could you test the disconnect error cases still? https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode467 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:467: // ...
4 years, 5 months ago (2016-07-07 23:50:54 UTC) #25
jingxuy
I received your request for tests, they are pending https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode467 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:467: ...
4 years, 5 months ago (2016-07-08 00:12:45 UTC) #26
sacomoto
https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode127 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:127: if (sub_status_ == SubStatus::CONNECTED) { On 2016/07/07 23:38:47, jingxuy ...
4 years, 5 months ago (2016-07-08 15:17:39 UTC) #27
jingxuy
https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode495 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:495: OnDidSendMessage(WireMessage(std::string(), std::string()), true); On 2016/07/08 15:17:38, sacomoto wrote: > ...
4 years, 5 months ago (2016-07-08 17:56:09 UTC) #28
jingxuy
Added tests for connection close https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode499 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:499: break; On 2016/07/08 17:56:09, ...
4 years, 5 months ago (2016-07-11 18:51:12 UTC) #29
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode467 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:467: // TODO(sacomoto): Actually pass the current message to the ...
4 years, 5 months ago (2016-07-11 21:35:00 UTC) #30
jingxuy
https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/240001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode467 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:467: // TODO(sacomoto): Actually pass the current message to the ...
4 years, 5 months ago (2016-07-11 23:15:18 UTC) #31
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/300001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc (right): https://codereview.chromium.org/2075313002/diff/300001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc#newcode845 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc:845: TEST_F(ProximityAuthBluetoothLowEnergyWeaveClientConnectionTest, On 2016/07/11 23:15:17, jingxuy wrote: > On 2016/07/11 ...
4 years, 5 months ago (2016-07-12 01:03:17 UTC) #32
jingxuy
https://codereview.chromium.org/2075313002/diff/300001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc (right): https://codereview.chromium.org/2075313002/diff/300001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc#newcode845 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc:845: TEST_F(ProximityAuthBluetoothLowEnergyWeaveClientConnectionTest, On 2016/07/12 01:03:12, Kyle Horimoto wrote: > On ...
4 years, 5 months ago (2016-07-15 18:25:00 UTC) #33
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/320001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/320001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode189 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:189: message_counter_, std::move(message))); On 2016/07/15 18:24:59, jingxuy wrote: > On ...
4 years, 5 months ago (2016-07-15 20:20:43 UTC) #34
jingxuy
https://codereview.chromium.org/2075313002/diff/320001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/320001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode189 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:189: message_counter_, std::move(message))); On 2016/07/15 20:20:43, Kyle Horimoto wrote: > ...
4 years, 5 months ago (2016-07-15 21:30:07 UTC) #35
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/320001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/320001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode189 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:189: message_counter_, std::move(message))); On 2016/07/15 21:30:06, jingxuy wrote: > On ...
4 years, 5 months ago (2016-07-15 21:54:54 UTC) #36
jingxuy
https://codereview.chromium.org/2075313002/diff/320001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/320001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode189 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:189: message_counter_, std::move(message))); On 2016/07/15 21:30:06, jingxuy wrote: > On ...
4 years, 5 months ago (2016-07-16 00:14:06 UTC) #37
Kyle Horimoto
Almost there! :) https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode522 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:522: PA_LOG(ERROR) << "I'm here "; nit: ...
4 years, 5 months ago (2016-07-16 00:46:57 UTC) #38
jingxuy
https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode522 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:522: PA_LOG(ERROR) << "I'm here "; On 2016/07/16 00:46:56, Kyle ...
4 years, 5 months ago (2016-07-16 00:54:53 UTC) #39
jingxuy
4 years, 5 months ago (2016-07-16 00:54:57 UTC) #40
sacomoto
https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc (right): https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc#newcode878 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc:878: // TODO(jingxuy): find out whether this is a bug ...
4 years, 5 months ago (2016-07-18 16:07:09 UTC) #41
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc (right): https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc#newcode878 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc:878: // TODO(jingxuy): find out whether this is a bug ...
4 years, 5 months ago (2016-07-18 17:04:14 UTC) #42
jingxuy
https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc (right): https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc#newcode878 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc:878: // TODO(jingxuy): find out whether this is a bug ...
4 years, 5 months ago (2016-07-18 17:22:25 UTC) #43
Kyle Horimoto
https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc (right): https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc#newcode878 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc:878: // TODO(jingxuy): find out whether this is a bug ...
4 years, 5 months ago (2016-07-18 17:36:07 UTC) #44
sacomoto
https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc (right): https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc#newcode878 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc:878: // TODO(jingxuy): find out whether this is a bug ...
4 years, 5 months ago (2016-07-18 17:42:15 UTC) #45
jingxuy
https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc (right): https://codereview.chromium.org/2075313002/diff/370001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc#newcode878 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection_unittest.cc:878: // TODO(jingxuy): find out whether this is a bug ...
4 years, 5 months ago (2016-07-18 18:25:34 UTC) #46
sacomoto
Please update the GYP files too: components/components_tests.gyp components/proximity_auth.gypi. LGTM after that change.
4 years, 5 months ago (2016-07-20 11:41:11 UTC) #47
Kyle Horimoto
lgtm
4 years, 5 months ago (2016-07-20 18:08:56 UTC) #48
jingxuy
On 2016/07/20 11:41:11, sacomoto wrote: > Please update the GYP files too: > > components/components_tests.gyp ...
4 years, 5 months ago (2016-07-20 18:21:31 UTC) #49
Tim Song
https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode76 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:76: // connection since we might not be connected at ...
4 years, 5 months ago (2016-07-21 20:49:35 UTC) #50
jingxuy
https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode76 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:76: // connection since we might not be connected at ...
4 years, 5 months ago (2016-07-21 21:30:34 UTC) #51
Tim Song
https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode115 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:115: if (remote_device) { On 2016/07/21 21:30:34, jingxuy wrote: > ...
4 years, 5 months ago (2016-07-22 00:52:51 UTC) #52
jingxuy
https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode115 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:115: if (remote_device) { On 2016/07/22 00:52:50, Tim Song wrote: ...
4 years, 5 months ago (2016-07-22 17:14:59 UTC) #53
jingxuy
https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode115 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:115: if (remote_device) { On 2016/07/22 00:52:50, Tim Song wrote: ...
4 years, 5 months ago (2016-07-22 17:14:59 UTC) #54
Tim Song
https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc (right): https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc#newcode425 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.cc:425: notify_session_ = std::move(notify_session); On 2016/07/22 17:14:59, jingxuy wrote: > ...
4 years, 5 months ago (2016-07-22 18:41:34 UTC) #55
jingxuy
https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h (right): https://codereview.chromium.org/2075313002/diff/490001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h#newcode310 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h:310: std::map<int, std::unique_ptr<WireMessage>> map_to_message_; On 2016/07/22 18:41:34, Tim Song wrote: ...
4 years, 5 months ago (2016-07-22 23:06:11 UTC) #56
Tim Song
lgtm https://codereview.chromium.org/2075313002/diff/510001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h (right): https://codereview.chromium.org/2075313002/diff/510001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h#newcode1 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h:1: no new line.
4 years, 5 months ago (2016-07-22 23:21:40 UTC) #57
jingxuy
https://codereview.chromium.org/2075313002/diff/510001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h File components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h (right): https://codereview.chromium.org/2075313002/diff/510001/components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h#newcode1 components/proximity_auth/ble/bluetooth_low_energy_weave_client_connection.h:1: On 2016/07/22 23:21:40, Tim Song wrote: > no new ...
4 years, 5 months ago (2016-07-22 23:26:00 UTC) #58
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2075313002/570001
4 years, 5 months ago (2016-07-22 23:26:39 UTC) #61
commit-bot: I haz the power
Try jobs failed on following builders: android_compile_dbg on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_compile_dbg/builds/101029) chromeos_daisy_chromium_compile_only_ng on master.tryserver.chromium.linux (JOB_FAILED, ...
4 years, 5 months ago (2016-07-22 23:40:39 UTC) #63
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2075313002/590001
4 years, 5 months ago (2016-07-25 17:40:38 UTC) #66
commit-bot: I haz the power
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_chromeos_ozone_rel_ng/builds/206822) mac_chromium_compile_dbg_ng on master.tryserver.chromium.mac (JOB_FAILED, ...
4 years, 5 months ago (2016-07-25 17:49:25 UTC) #68
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2075313002/610001
4 years, 5 months ago (2016-07-25 21:18:35 UTC) #71
commit-bot: I haz the power
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_arm64_dbg_recipe/builds/101520)
4 years, 5 months ago (2016-07-25 21:43:44 UTC) #73
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2075313002/630001
4 years, 5 months ago (2016-07-25 22:22:39 UTC) #76
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_ng/builds/268631)
4 years, 5 months ago (2016-07-25 23:12:05 UTC) #78
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2075313002/630001
4 years, 5 months ago (2016-07-26 00:15:06 UTC) #80
commit-bot: I haz the power
Committed patchset #33 (id:630001)
4 years, 5 months ago (2016-07-26 00:43:10 UTC) #82
commit-bot: I haz the power
Patchset 33 (id:??) landed as https://crrev.com/f4f0a5cde8eff464de5359281560444ff442f920 Cr-Commit-Position: refs/heads/master@{#407655}
4 years, 5 months ago (2016-07-26 00:47:04 UTC) #84
benwells
4 years, 4 months ago (2016-07-28 06:02:20 UTC) #85
Message was sent while issue was closed.
A revert of this CL (patchset #33 id:630001) has been created in
https://codereview.chromium.org/2189913002/ by benwells@chromium.org.

The reason for reverting is: This CL has a memory problem in the unit tests, as
reported by DrMemory.

First build showing the error:
https://build.chromium.org/p/chromium.memory.fyi/builders/Windows%20Unit%20%2...

Note, that build doesn't include this change as there was a problem introduced
earlier that caused the whole build to fail.

Error text:
UNADDRESSABLE ACCESS of freed memory: reading 0x069fa848-0x069fa84c 4 byte(s)
# 0
proximity_auth::weave::BluetoothLowEnergyWeavePacketGenerator::Factory::NewInstance
[components\proximity_auth\ble\bluetooth_low_energy_weave_packet_generator.cc:33]
# 1
proximity_auth::weave::ProximityAuthBluetoothLowEnergyWeavePacketGeneratorTest_CreateConnectionRequestTest_Test::TestBody
[components\proximity_auth\ble\bluetooth_low_energy_weave_packet_generator_unittest.cc:54]
# 2 testing::internal::HandleExceptionsInMethodIfSupported<>                  
[testing\gtest\src\gtest.cc:2458]
Note: @0:05:46.506 in thread 13092
Note: 0x069fa848-0x069fa84c overlaps memory 0x069fa5d8-0x069fa8c0 that was freed
here:
Note: # 0 replace_operator_delete_nothrow                                       
    [d:\drmemory_package\common\alloc_replace.c:2974]
Note: # 1
proximity_auth::weave::ProximityAuthBluetoothLowEnergyWeaveClientConnectionTest_ConnectAfterADelayWhenThrottled_Test::`scalar
deleting destructor'
Note: # 2 testing::Test::DeleteSelf_                                            
    [testing\gtest\include\gtest\gtest.h:453]
Note: # 3 testing::TestInfo::Run                                                
    [testing\gtest\src\gtest.cc:2661]
Note: instruction: mov    (%eax) -> %edx
Suppression (error hash=#E743E83C1B0FB1CF#):
For more info on using suppressions see
http://dev.chromium.org/developers/how-tos/using-drmemory#TOC-Suppressing-err...
{
UNADDRESSABLE ACCESS
name=<insert_a_suppression_name_here>
*!proximity_auth::weave::BluetoothLowEnergyWeavePacketGenerator::Factory::NewInstance
*!proximity_auth::weave::ProximityAuthBluetoothLowEnergyWeavePacketGeneratorTest_CreateConnectionRequestTest_Test::TestBody
*!testing::internal::HandleExceptionsInMethodIfSupported<>
}

The problem is real, to fix this SetInstanceForTesting should keep the previous
factory around somewhere, and there should be a method to clear the testing
instance. Or something like that..

Powered by Google App Engine
This is Rietveld 408576698