* rust: cargo update
* rust: Migrate to `zcash_client_sqlite 0.7`
* rust: cargo fmt
* Adopt zcash_client_sqlite 0.7 database changes
* [#1018] add limit parameter to validateCombinedChain
* Adopt limit parameter in Android layer
* Switch limit argument to Long
- Switched from Int to Long type
- Done for both validate and scan blocks functions
- Changed the default parameter for nullable one in the public interface to let callers be explicit about the argument
- Changed in the Rust layer as well
---------
Co-authored-by: Carter Jernigan <git@carterjernigan.com>
Co-authored-by: Jack Grigg <jack@z.cash>
Co-authored-by: Honza <rychnovsky.honza@gmail.com>
* [#1009] Change CompactBlockProcessor methods signature
* Remove withContext {}
Since our networking, RustBackend, and CompactBlockRepository all use coroutines internally by implementing `suspend` for their APIs, we don’t need withContext() anymore. (If we discover something does do blocking IO on the thread, we should deal with it at the point the IO is occurring rather than at the top level)
* Sort FileExt functions
* Add isDirectorySuspend
- To avoid strict mode disc IO violation warning
* Omit try/catch on block files delete action
* Refactor scan batch function
- Removed retry mechanisms, as it’s not needed now after the previous switch from the database-based blocks persisting to file-based blocks persisting
- scan function now works with the current processing range of blocks size instead of hardcoded constant value
* Eliminate duplicate processorInfo object
* Change log text
* MutableList instead of ArrayList
* Eliminate sync range nullability
* Rewind not scanned blocks
If we find out that we previously downloaded, but not validated and scanned persisted blocks, we need to rewind the blocks above the last scanned height first.
* Fix ktlint warning
---------
Co-authored-by: Carter Jernigan <git@carterjernigan.com>
- We rather use add address method for this use case, as the addresses field does not seem to be initialized with a fixed size at the time of address setting
* [#895] Adopt new Response result
* Change catch flow part
* Correct emit from flow catch
* Additional changes after Block store on disk merged
* Simplify networking model structure
* Enhance flow filter
* Switch to coroutine client in a few tests too
* Use StatusException
* Switch client in a few tests
* Switch client for download block case
* Link fetch UTXOs issue
* Refactor refresh and process UTXOs
* Improve downloadBlockRange logging
* Switch getTAddressTransactions to the Response result
* Move some parts of requests out of try-catch
* Remove link to issue
* Refactor fetchUtxos to return Response
* Throws custom exception from ResponseFailure
- To trigger existing re-try mechanisms in case of any particular trouble
* [#674] Use suspending functions for networking
- Initial commit to set up how we transform to the coroutine version of networking client
* Enhance flow filter
* Switch to coroutine client in a few tests too
* Use StatusException
* Comment out old UI demo app cases
* Switch client in a few tests
* Switch client for download block case
* Remove the blocking networking client entirely
* Link fetch UTXOs issue
* Refactor refresh and process UTXOs
* Improve downloadBlockRange logging
* Remove CompactBlockRepository.write(sequence)
* Remove “Coroutine” prefix
Since we only have a single implementation, the designation shouldn’t matter anymore
* Fix collection bug
* Finish network client renaming
* Collect write results internally
* Write method simplification
* Blocks sync logging reduce
* Unused unsafe models remove
---------
Co-authored-by: Carter Jernigan <git@carterjernigan.com>
This is an initial step before moving the Rust backend into a separate Gradle module
- Use primitive values for the Rust backend interface. This will allow the backend to be moved into a new Gradle module in the future, without needing to access the model objects of the SDK
- Add extension functions to the Backend to replace the existing usage of more strongly typed objects. The extension functions can continue to live in the sdk-lib even after refactoring the Rust backend
- Add new decorator that can eventually replace using the Rust backend within the SDK