Pablobaxter Harmony Versions Save

Multi-process SharedPreference implementation without ContentProvider

v1.1.7

2 years ago
  • Use Os.fsync() for Android versions that support it
  • Fast follow improvement when reading transaction file

v1.1.5

3 years ago

Version 1.1.5 / 2021-02-27

  • Removed dependency on Kotlin Coroutines. This is to reduce bringing in libraries that may not already exist into the project.
  • Create a global thread to handle Harmony updates, instead of each Harmony object having their own thread.
  • Note: The test times may appear better this release, but that is only because I was previously testing on a debug build of the demo app instead of a release build. In actuality, v1.1.5 performs just as well as v1.1.4 with the listed changes. Sorry if there is any confusion.

v1.1.4

3 years ago

Version 1.1.4 / 2021-02-10

  • Added FileDescriptor.sync() for each transaction written (in response to #15)
  • Minor restructure for reading JSON string from main file
  • Updated Kotlin libraries and Android plugins
  • Migrated to releasing directly to MavenCentral instead of Bintra

v1.1.3

3 years ago

Version 1.1.3 / 2021-01-02

  • MIN SDK Raised to API 17
  • Adds batching to transactions, making inter-process data replication much faster
  • Updates several core Kotlin and Coroutines libraries
  • Fixes potential bug where an IOException could be thrown by a function, but isn't declared as throws when compiled to JVM bytecode.
  • Slight improvements with memory usage
  • Fixes a file descriptor crash
  • Additional unit tests for apply() and commit() functions
  • Fixed crasg bug when storing a large string (64K limit with DataOutputStream.writeUTF())
  • Known issues:

v1.1.2

3 years ago
  • Renamed several functions and variables

v1.1.1

3 years ago
  • Fixes minor issue where phone restart could cause transactions to come in out of order

v1.1.0

3 years ago
  • Fixes a bug where calling apply() in both processes at once would potentially cause removed data to be restored
  • Improves in-memory replication time between processes when using apply()
  • Creates a transaction file where changes get written to before being written to the master preferences file
    • Every time apply() or commit() is called, a new transaction is written to the transaction file
    • Each time a process restarts and gets an instance of a Harmony preference object, all transactions are flushed and written to the master file
    • Transactions are also flushed when transaction file grows beyond a certain size (128 KB currently, or about ~3k single key transactions)
    • All transactions contain a checksum value to validate transaction integrity

v1.0.0

4 years ago
  • FIRST MAJOR RELEASE!
  • Fixes a bug where getAll() only holds long numbers, instead of int and float
  • Fixes a but where lock files could be deleted but not recreated, causing a crash
  • Changes underlying data structure (BREAKING CHANGE)
  • Updates Kotlin Coroutines library
  • Updates min Android SDK to API 14
  • Adds instrumented tests via Firebase Test Lab
  • Added additional tests, especially around testing Harmony in multiprocess
  • Change to casting logic from in-memory map, to match documentation of SharedPreferences

v0.0.7

4 years ago
  • Slight improvement to apply() performance
  • Adds code for performance testing of Harmony vs SharedPreferences
  • Removes unused library from example app (MMKV)

v0.0.6

4 years ago
  • License change from MIT to Apache-2.0