1

My team and I are working on a mobile app. A feature of this mobile app is to have the ability to register their device with multiple organizations who are our clients. We distribute to our clients multiple applications and web apps, one of them is a web api application so the mobile application can retrieve data. Having this type of distribution can cause issues because there could be a user on the latest version of the application trying to access an older version of the api which may or may not have all of the same properties on a DTO.

Are there known patterns or thoughts on how to deal with an situation like this?

Simple visual representation here enter image description here

Benji
  • 489
  • 2
  • 4
  • 14
  • I don't know if i got it right, but you could request first the api version and on response check if that matches with the mobile app version and then send other requests – Antonios Tsimourtos Jul 05 '16 at 14:42
  • @Tony If i read between the lines, are you suggesting something like after getting the URL version from the web api to then do something like url versioning? (.....api/v2.0/my-endpoint)? Also what about the DTO versioning?? – Benji Jul 05 '16 at 14:44
  • You could make a request i guess asking for web api and DTO version,if the user's app is outdated prompt him to update, if the company is outdated prompt them to update, in order to have a successfull transaction of data. That depends i guess on you, that way you block the user until he updates or make him wait for the company to update..you could still receive and give data. For example if theres a newer version with more variables you could update only the previous version's variables, and when system captures the update then to send the rest. – Antonios Tsimourtos Jul 05 '16 at 14:54
  • @Tony that would be the last ditch effort. Ideally we dont want to make our clients update if they don't want to. If no other solutions are found, it may be something we need to propose to the BU – Benji Jul 05 '16 at 14:56
  • edited above comment – Antonios Tsimourtos Jul 05 '16 at 14:58
  • Make a rule that newer objects are always supersets of older ones. Deprecate, rather than delete old properties. – danh Jul 05 '16 at 15:06

0 Answers0