ppegusii / cs677-smart-homes-IoT

Programming Assignment 1: Internet of Things and Smart Homes
GNU General Public License v2.0
2 stars 0 forks source link

All devices and sensors multicast Registration request #20

Closed ameetrivedi closed 2 years ago

ameetrivedi commented 9 years ago
  1. Parse the gateway IP and ports
  2. Dial to gateways and send RPC register request
ameetrivedi commented 9 years ago

Done...

2 times saw the same device id being returned by gateway to different devices sending registration request. Haven't been able to reproduce the issue again.

ppegusii commented 9 years ago

There is no synchronization yet, so it is possible:

  1. device multicast request
  2. current leader receives request
  3. current leader responds to request
  4. election occurs blocking the other replica from responding
  5. election finishes other replica now leader
  6. new leader responds with same ID

With release consistency in registration, the other replica should be informed between 2 & 3, but this is something we should test.

The same gateway should not have returned the same ID.