Remove jackson from a few more places#1935
Merged
SessionHero01 merged 2 commits intodevfrom Feb 13, 2026
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This pull request removes Jackson dependencies from the codebase and replaces them with kotlinx.serialization. It also refactors several provider classes from Java to Kotlin with proper dependency injection instead of static singleton patterns.
Changes:
- Migrated serialization from Jackson to kotlinx.serialization for
SealedDataandAttachmentSecretclasses - Converted
AttachmentSecretProvider,DatabaseSecretProvider, andLogSecretProviderfrom Java singletons to Kotlin classes with dependency injection - Enhanced
PreferenceKeyto support JSON serialization with reified type parameters and added support forByteArraystorage - Removed deprecated preference storage methods from
TextSecurePreferencesand migrated to the newPreferenceStorageabstraction
Reviewed changes
Copilot reviewed 24 out of 24 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
BlobUtils.java |
Updated to access AttachmentSecretProvider from ApplicationContext instead of static getInstance() |
SharedPreferenceStorage.kt |
Added support for Bytes strategy and fixed enum fallback to default value |
PreferenceKey.kt |
Changed json() method to use reified type parameter and added bytes() factory method |
LandingActivity.kt |
Removed unused imports |
SignalGlideModule.java |
Updated to access AttachmentSecretProvider from ApplicationContext |
PersistentLogger.kt |
Updated to inject LogSecretProvider via constructor instead of static access |
LogSecretProvider.kt (new) |
New Kotlin implementation with dependency injection |
LogSecretProvider.java (deleted) |
Removed Java implementation |
DatabaseModule.kt |
Updated to inject AttachmentSecretProvider instead of using static getInstance() |
SealedData.kt (new) |
New Kotlin data class with kotlinx.serialization support |
KeyStoreHelper.java |
Removed inner SealedData class and updated to use new standalone class |
IdentityKeyUtil.java |
Updated references from KeyStoreHelper.SealedData to SealedData |
DatabaseSecretProvider.kt (new) |
New Kotlin implementation with dependency injection |
DatabaseSecretProvider.java (deleted) |
Removed Java implementation |
AttachmentSecretProvider.kt (new) |
New Kotlin implementation with dependency injection |
AttachmentSecretProvider.java (deleted) |
Removed Java implementation |
AttachmentSecret.kt (new) |
New Kotlin data class with kotlinx.serialization support |
AttachmentSecret.java (deleted) |
Removed Java implementation |
LoginStateRepository.kt |
Migrated from SharedPreferences to PreferenceStorage abstraction |
LocalEncryptedFileOutputStream.kt |
Updated to inject AttachmentSecretProvider instead of using static getInstance() |
LocalEncryptedFileInputStream.kt |
Updated to inject AttachmentSecretProvider instead of using static getInstance() |
ApplicationContext.kt |
Added injection for AttachmentSecretProvider |
BytesAsCompactB64Serializer.kt (new) |
New custom serializer for ByteArray using Base64 encoding |
TextSecurePreferences.kt |
Removed deprecated secret management methods that are now handled by dedicated providers |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
app/src/main/java/org/thoughtcrime/securesms/crypto/DatabaseSecretProvider.kt
Outdated
Show resolved
Hide resolved
ThomasSession
approved these changes
Feb 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Went in to change SealData to use kotlinx serialization, ended up changing these along the way:
AttachmentSecretand its providerDatabaseSecretProviderLogSecretProvider