I am trying a vanilla MVI for my new project with ...
# android-architecture
p
I am trying a vanilla MVI for my new project with channels and flow. I’ve used RxJava before and tried some frameworks like Mvrx, Grox. I have few questions I’d like to get answers for and see how this situations are handled.  1. Two ui intents are mapped to async calls but they should be emitted sequentially so that the UI updates are sequential. For example event A and B are emitted, async operation trigged by event B finishes before event A. But the state updates should be sequential right?  2. On-off async operations or side effects like uploading or downloading a pdf. This needs to only show a snackbar and there is no state preserved. 3. Suggestions for state loss problems or back pressure?
r
We are using orbit mvi plz go thru this https://github.com/orbit-mvi/orbit-mvi. All the points which you mentioned is supported by this library and we are refactoring most of our old code base to this architecture

https://youtu.be/E6obYmkkdko

p
Thanks Ravi, unfortunately I can't use any library but I will go through it. Interesting to see the internals, how back pressure, congestion control etc is handled. Agree that using Orbit-MVI or MVRx will alleviate all the pain. I would like to see how others are handling the issues with vanilla MVI and different perspectives.
Read this article recently, they were facing the same issue - https://godaddy.com/engineering/2021/11/05/android-state-management-mvi/