Skip to content

MOBILE-129: Add operationsDomain#707

Merged
enotniy merged 4 commits intodevelopfrom
feature/MOBILE-129
Apr 28, 2026
Merged

MOBILE-129: Add operationsDomain#707
enotniy merged 4 commits intodevelopfrom
feature/MOBILE-129

Conversation

@enotniy
Copy link
Copy Markdown
Collaborator

@enotniy enotniy commented Apr 27, 2026

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds support for a separate “operations domain” (optionally coming from remote mobile config) so the SDK can route operations endpoints through a different host (e.g., anonymizer/proxy) while keeping backward compatibility with the existing domain.

Changes:

  • Extend config/DTO parsing to read settings.baseAddresses.operations and persist it in SharedPreferences.
  • Add operationsDomain to SDK init configuration + Room Configuration entity, and route operations URLs through the resolved domain with a priority chain.
  • Update/expand unit tests for domain parsing/normalization and operations-domain routing behavior.

Reviewed changes

Copilot reviewed 16 out of 16 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
sdk/src/test/java/cloud/mindbox/mobile_sdk/managers/MobileConfigSettingsManagerTest.kt Updates test construction for SettingsDto with new field.
sdk/src/test/java/cloud/mindbox/mobile_sdk/managers/GatewayManagerTest.kt Adds tests for operations-domain resolution and URL routing.
sdk/src/test/java/cloud/mindbox/mobile_sdk/inapp/data/repositories/OperationsDomainConfigPolicyTest.kt New tests for config → stored-domain persistence policy.
sdk/src/test/java/cloud/mindbox/mobile_sdk/SdkValidationDomainTest.kt New tests for domain normalization helpers (extractHost, toBaseUrl).
sdk/src/main/java/cloud/mindbox/mobile_sdk/repository/MindboxPreferences.kt Adds operationsDomainFromConfig stored preference.
sdk/src/main/java/cloud/mindbox/mobile_sdk/repository/MindboxDatabase.kt Bumps Room DB version and adds migration for operationsDomain column.
sdk/src/main/java/cloud/mindbox/mobile_sdk/models/operation/response/InAppConfigResponse.kt Adds baseAddresses.operations to config DTOs.
sdk/src/main/java/cloud/mindbox/mobile_sdk/models/Configuration.kt Adds operationsDomain field to persisted init configuration model.
sdk/src/main/java/cloud/mindbox/mobile_sdk/managers/GatewayManager.kt Routes operations endpoints via resolved operations domain; normalizes base URLs.
sdk/src/main/java/cloud/mindbox/mobile_sdk/inapp/data/repositories/OperationsDomainConfigPolicy.kt Introduces policy for deciding whether to save/keep/clear stored operations domain.
sdk/src/main/java/cloud/mindbox/mobile_sdk/inapp/data/repositories/MobileConfigRepositoryImpl.kt Parses baseAddresses and persists operations domain based on policy.
sdk/src/main/java/cloud/mindbox/mobile_sdk/inapp/data/managers/MobileConfigSerializationManagerImpl.kt Parses baseAddresses block from settings JSON.
sdk/src/main/java/cloud/mindbox/mobile_sdk/SdkValidation.kt Adds helpers for domain normalization + validates optional operationsDomain.
sdk/src/main/java/cloud/mindbox/mobile_sdk/MindboxConfiguration.kt Adds builder/config support for operationsDomain.
sdk/src/main/java/cloud/mindbox/mobile_sdk/Mindbox.kt Integrates operationsDomain into init validation and sanitization flow.
sdk/src/androidTest/java/cloud/mindbox/mobile_sdk/InputParametersUnitTest.kt Updates validation expectations for normalized domain inputs.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread sdk/src/main/java/cloud/mindbox/mobile_sdk/SdkValidation.kt Outdated
Comment thread sdk/src/main/java/cloud/mindbox/mobile_sdk/repository/MindboxPreferences.kt Outdated
@enotniy enotniy requested a review from justSmK April 27, 2026 14:15
@enotniy enotniy force-pushed the feature/MOBILE-129 branch from 1656c8b to 7af9213 Compare April 27, 2026 14:52
@enotniy enotniy force-pushed the feature/MOBILE-129 branch from 7af9213 to d797449 Compare April 27, 2026 15:57
Comment thread sdk/src/main/java/cloud/mindbox/mobile_sdk/Mindbox.kt
@enotniy enotniy merged commit c3f0659 into develop Apr 28, 2026
5 checks passed
@enotniy enotniy deleted the feature/MOBILE-129 branch April 28, 2026 09:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants