Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

Update Application services to 93.1.0 #12120

Merged
merged 5 commits into from
May 9, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion buildSrc/src/main/java/Dependencies.kt
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ object Versions {
const val disklrucache = "2.0.2"
const val leakcanary = "2.8.1"

const val mozilla_appservices = "91.1.2"
const val mozilla_appservices = "93.1.0"

const val mozilla_glean = "44.1.1"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

package mozilla.components.browser.storage.sync

import android.content.Context
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.cancelChildren
Expand All @@ -15,16 +16,20 @@ import mozilla.components.concept.sync.Device
import mozilla.components.concept.sync.SyncableStore
import mozilla.components.support.base.log.logger.Logger
import mozilla.components.support.utils.logElapsedTime
import java.io.File
import mozilla.appservices.remotetabs.InternalException as RemoteTabProviderException
import mozilla.appservices.remotetabs.TabsStore as RemoteTabsProvider

private const val TABS_DB_NAME = "tabs.sqlite"

/**
* An interface which defines read/write methods for remote tabs data.
*/
open class RemoteTabsStorage(
private val context: Context,
private val crashReporter: CrashReporting? = null
) : Storage, SyncableStore {
internal val api by lazy { RemoteTabsProvider() }
internal val api by lazy { RemoteTabsProvider(File(context.filesDir, TABS_DB_NAME).canonicalPath) }
private val scope by lazy { CoroutineScope(Dispatchers.IO) }
internal val logger = Logger("RemoteTabsStorage")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import mozilla.appservices.remotetabs.RemoteTab
import mozilla.components.concept.base.crash.CrashReporting
import mozilla.components.support.test.any
import mozilla.components.support.test.mock
import mozilla.components.support.test.robolectric.testContext
import org.junit.After
import org.junit.Assert.assertEquals
import org.junit.Before
Expand All @@ -36,7 +37,7 @@ class RemoteTabsStorageTest {
@Before
fun setup() {
crashReporter = mock()
remoteTabs = spy(RemoteTabsStorage(crashReporter))
remoteTabs = spy(RemoteTabsStorage(testContext, crashReporter))
apiMock = mock(RemoteTabsProvider::class.java)
`when`(remoteTabs.api).thenReturn(apiMock)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ import mozilla.components.support.ktx.kotlinx.coroutines.flow.ifChanged
class SyncedTabsStorage(
private val accountManager: FxaAccountManager,
private val store: BrowserStore,
private val tabsStorage: RemoteTabsStorage = RemoteTabsStorage(),
private val tabsStorage: RemoteTabsStorage,
private val debounceMillis: Long = 1000L,
) : SyncedTabsProvider {
private var scope: CoroutineScope? = null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ class NimbusPlugin implements Plugin<Project> {
// a) this plugin is going to live in the AS repo (eventually)
// See https://github.com/mozilla-mobile/android-components/issues/11422 for tying this
// to a version that is specified in buildSrc/src/main/java/Dependencies.kt
return "92.0.0"
return "93.1.0"
}

// Try one or more hosts to download the given file.
Expand Down
15 changes: 10 additions & 5 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,14 @@ permalink: /changelog/
* Added `CreditCardValidationDelegate` which is a delegate that will check against the `CreditCardsAddressesStorage` to determine if a `CreditCard` can be persisted in storage. [#9838](https://github.com/mozilla-mobile/android-components/issues/9838)
* Refactors `CreditCard` from `concept-engine` to `CreditCardEntry` in `concept-storage` so that it can validated with the `CreditCardValidationDelegate`. [#9838](https://github.com/mozilla-mobile/android-components/issues/9838)

* **storage-sync**:
* **browser-storage-sync**
* ⚠️ **This is a breaking change**: When constructing a `RemoteTabsStorage` object you must now a `Context` which is used to determine the location of the sqlite database which is used to persist the remote tabs [#11799](https://github.com/mozilla-mobile/android-components/pull/11799).
* Fixed a low frequency crasher that might occur when the app attempts to delete all history. [#12112](https://github.com/mozilla-mobile/android-components/pull/12112)


* **feature-syncedtabs**
* ⚠️ **This is a breaking change**: When constructing a `SyncedTabsStorage`, the `tabsStorage: RemoteTabsStorage` parameter is no longer optional so must be supplied [#11799](https://github.com/mozilla-mobile/android-components/pull/11799).

# 101.0.0
* [Commits](https://github.com/mozilla-mobile/android-components/compare/v100.0.0...v101.0.0)
* [Milestone](https://github.com/mozilla-mobile/android-components/milestone/148?closed=1)
Expand All @@ -53,7 +58,7 @@ permalink: /changelog/
* Media playback is now paused when AudioManager.ACTION_AUDIO_BECOMING_NOISY is broadcast by the system.

* **feature-media**
* The Play/Pause button remains displayed on the media notification
* The Play/Pause button remains displayed on the media notification.

# 100.0.0
* [Commits](https://github.com/mozilla-mobile/android-components/compare/v99.0.0...v100.0.0)
Expand Down Expand Up @@ -101,13 +106,13 @@ permalink: /changelog/

* **lib-crash-sentry**
* 🌟️️ Add `sendCaughtExceptions` config flag to `SentryService`, allowing consumers to disable submitting caught exceptions. By default it's enabled, maintaining prior behaviour. Useful in projects with high volumes of caught exceptions and multiple release channels.

* **site-permission-feature**
* 🆕 New Add to SitePermissionsFeature a property to set visibility for NotAskAgainCheckBox

* **feature-search**
* 🆕 Update search Engines and Search Engine Icons

# 99.0.0
* [Commits](https://github.com/mozilla-mobile/android-components/compare/v98.0.0...v99.0.0)
* [Milestone](https://github.com/mozilla-mobile/android-components/milestone/146?closed=1)
Expand All @@ -128,7 +133,7 @@ permalink: /changelog/
* 🚒 Bug fixed [issue #8567](https://github.com/mozilla-mobile/android-components/issues/8567) - Prevent crashes when trying to add to the system databases.

* **concept-engine**
* 🌟️️ Add `EngineSessionStateStorage`, describing a storage of `EngineSessionState` instances.
* 🌟️️ Add `EngineSessionStateStorage`, describing a storage of `EngineSessionState` instances.

* **browser-session-storage**
* 🌟️️ Add `FileEngineSessionStateStorage`, an implementation of `EngineSessionStateStorage` for persisting engine state outside of the regular RecoverableBrowserState flow.
Expand Down