DP-3T / dp3t-sdk-android

The DP3T-SDK for Android
Mozilla Public License 2.0
242 stars 94 forks source link

Upgrade positive communication service to V2 #220

Open oscar7602 opened 4 years ago

oscar7602 commented 4 years ago

Positive communication service should use version 2. Version 1 is now in use: https://github.com/DP-3T/dp3t-sdk-android/blob/739bf165b0d47c8ccdea6f3dbbd2252cb521aef4/dp3t-sdk/sdk/src/main/java/org/dpppt/android/sdk/internal/backend/ReportService.java

We have verified that iOS is using version 2 of the positive communication service. https://github.com/DP-3T/dp3t-sdk-ios/blob/f0f493971fe9d3df43fe897d7424aca35cfe21ca/Sources/DP3TSDK/Networking/Endpoints.swift

simonroesch commented 4 years ago

The v2 API has no longer the concept of uploading the "current day key" on the next day. On iOS when using ENv2 you are guaranteed to receive the TEK of the current day with a shortened rolling period when requesting the TEKs. On Android it depends on a configuration done by Google whether you immediately receive the TEK of the current day with a shortened rolling period or if you have to request the TEKs again on the next day to receive the last TEK. Currently the Android implementation takes both scenarios into account, but always uses the v1 API that has the ability to upload a TEK on the next day.

I will double check with Google what the status of their configuration is. As soon as all devices with ENv1.6 (current minimum for DP3T-SDK v2) support same day TEK release, we can remove the case-distinction from the SDK and switch to the v2 API.