Skip to content

Commit 4a04cc2

Browse files
authored
Android: Switch to UniFFI experimental FFI (#7205)
We've been developing this in to try to reduce the Android crash rate. We're not sure if this will work or not, so the plan is to run an experiment where we switch to a UniFFI branch with the new FFI and monitor the crash rate. The branch is based off of 0.31 and should only affect Kotlin/Android. https://docs.google.com/document/d/13kEAIcjoHYVH-z4uKFsTsLKaUc1I-PmZ_E-Orn2lgqY/edit?tab=t.0#heading=h.rjnszvtvhr7e mozilla/uniffi-rs#2765
1 parent 3df8da4 commit 4a04cc2

File tree

33 files changed

+71
-81
lines changed

33 files changed

+71
-81
lines changed

Cargo.lock

Lines changed: 12 additions & 22 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

components/ads-client/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ serde = "1"
2323
serde_json = "1"
2424
thiserror = "2"
2525
once_cell = "1.5"
26-
uniffi = { version = "0.31" }
26+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666" }
2727
url = { version = "2", features = ["serde"] }
2828
uuid = { version = "1.3", features = ["v4"] }
2929
viaduct = { path = "../viaduct" }
@@ -35,4 +35,4 @@ mockito = { version = "0.31", default-features = false }
3535
viaduct-dev = { path = "../support/viaduct-dev" }
3636

3737
[build-dependencies]
38-
uniffi = { version = "0.31", features = ["build"] }
38+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666", features = ["build"] }

components/as-ohttp-client/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@ exclude = ["/ios"]
1010
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
1111

1212
[dependencies]
13-
uniffi = { version = "0.31" }
13+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666" }
1414
thiserror = "2"
1515
parking_lot = "0.12"
1616
rusqlite = { version = "0.37.0", features = ["bundled"] }
1717
bhttp = "0.7.2"
1818
ohttp = { version = "0.7.2", default-features = false, features = ["client", "server", "app-svc", "external-sqlite"] }
1919

2020
[build-dependencies]
21-
uniffi = { version = "0.31", features=["build"]}
21+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666", features=["build"]}

components/autofill/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ sync-guid = { path = "../support/guid", features = ["rusqlite_support", "random"
2323
sync15 = { path = "../sync15", features = ["sync-engine"] }
2424
thiserror = "2"
2525
types = { path = "../support/types" }
26-
uniffi = { version = "0.31" }
26+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666" }
2727
url = { version = "2.2", features = ["serde"] }
2828

2929
[dev-dependencies]
@@ -32,4 +32,4 @@ nss = { path = "../support/rc_crypto/nss" }
3232
error-support = { path = "../support/error", features=["testing"] }
3333

3434
[build-dependencies]
35-
uniffi = { version = "0.31", features=["build"]}
35+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666", features=["build"]}

components/context_id/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ edition = "2021"
55
license = "MPL-2.0"
66

77
[build-dependencies]
8-
uniffi = { version = "0.31", features=["build"]}
8+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666", features=["build"]}
99

1010
[dependencies]
1111
chrono = "0.4"
@@ -15,7 +15,7 @@ parking_lot = "0.12"
1515
serde = "1"
1616
serde_json = "1"
1717
thiserror = "2"
18-
uniffi = { version = "0.31" }
18+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666" }
1919
url = "2"
2020
uuid = { version = "1.3", features = ["v4"]}
2121
viaduct = { path = "../viaduct" }

components/crashtest/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ exclude = ["/android", "/ios"]
99
[dependencies]
1010
log = "0.4"
1111
thiserror = "2"
12-
uniffi = { version = "0.31" }
12+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666" }
1313

1414
[build-dependencies]
15-
uniffi = { version = "0.31", features=["build"]}
15+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666", features=["build"]}

components/example/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ license = "MPL-2.0"
1212
[dependencies]
1313
# UniFFI is a dependency for any shared Rust component, make the version match what the other
1414
# components are using.
15-
uniffi = { version = "0.31" }
15+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666" }
1616
# app-services support crates that you probably want to use.
1717
error-support = { path = "../support/error" }
1818
interrupt-support = { path = "../support/interrupt" }

components/filter_adult/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ error-support = { path = "../support/error" }
1111
md-5 = "0.10"
1212
regex = "1"
1313
thiserror = "2"
14-
uniffi = { version = "0.31" }
14+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666" }
1515

1616
[[bin]]
1717
name = "import-site-list"

components/fxa-client/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,12 @@ error-support = { path = "../support/error" }
2525
thiserror = "2"
2626
anyhow = "1.0"
2727
sync-guid = { path = "../support/guid", features = ["random"] }
28-
uniffi = { version = "0.31" }
28+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666" }
2929
payload-support = { path = "../support/payload" }
3030
nss = { path = "../support/rc_crypto/nss" }
3131

3232
[build-dependencies]
33-
uniffi = { version = "0.31", features = ["build"] }
33+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666", features = ["build"] }
3434

3535
[dev-dependencies]
3636
viaduct-dev = { path = "../support/viaduct-dev"}

components/init_rust_components/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,6 @@ keydb = ["nss/keydb"]
1212
ohttp = ["dep:viaduct", "viaduct/ohttp"]
1313

1414
[dependencies]
15-
uniffi = { version = "0.31" }
15+
uniffi = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "106e12ae2a0474a1880667ed3a4b050fcf1c6666" }
1616
nss = { path = "../support/rc_crypto/nss" }
1717
viaduct = { path = "../viaduct", optional = true }

0 commit comments

Comments
 (0)