Reading SQLite data with StorIO

Since we are now prepared to handle all kinds of exceptions and interruptions of the flow, we can finally start creating a flow that will load locally saved StockUpdate entries from the SQLite database in cases when the quotes cannot be fetched from the Internet.

First of all, to do that, we will need to implement a GetResolver for the StorIO library that will handle the reading of the data. More specifically, it will handle the conversion of data from SQLite returned interfaces to our native domain objects (StockUpdate).

Next, we will incorporate that new local StockUpdate entry-reading mechanism into the existing flow so that the entries can be injected into the reactive stream.

Finally, we will inform the user that the remote data fetch was unsuccessful and we had to fall back to the local means of data retrieval.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.147.58.194