Skip to content

Conversation

@nickolas-dimitrakas
Copy link
Contributor

@nickolas-dimitrakas nickolas-dimitrakas commented Jan 20, 2026

Background

  • The SDK previously used a feature flag enableDirectRouting controlled by server-side remote config to determine whether to use region-specific API endpoints. This change removes the feature flag and makes direct routing the default behavior.

What Has Changed

  • Removed enableDirectRouting property from MPStateMachine
  • Removed remote config parsing for the dur (direct URL routing) key
    SDK now always routes to region-specific endpoints (e.g., nativesdks.us1.mparticle.com instead of nativesdks.mparticle.com)
  • API keys without a region prefix default to us1

Checklist

  • I have performed a self-review of my own code.
  • I have made corresponding changes to the documentation.
  • I have added tests that prove my fix is effective or that my feature works.
  • I have tested this locally.

Reference Issue (For employees only. Ignore if you are an outside contributor)

MIGRATING.md Outdated

### Direct Routing Enabled by Default

The SDK now always uses region-specific API endpoints. Previously, this behavior was controlled by a server-side feature flag (`enableDirectRouting`).
Copy link
Member

Choose a reason for hiding this comment

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

This flag was never set to true, and it's not something we need to publicize given a developer never knew about this server side setting. I'd instead point out that if they have any network security policies, that they'll need to whitelist the new URL that you shared below in What has changed that you share below. I'm not sure about the specifics about iOS, but here's a summary that i plugged into AI to see if there was a comparable thing on IOS since web has such feature.

@nickolas-dimitrakas nickolas-dimitrakas force-pushed the feat/direct-routing-by-default branch 2 times, most recently from 148a102 to dc9e292 Compare January 21, 2026 16:33
@github-actions
Copy link

📦 SDK Size Impact Report

Measures how much the SDK adds to an app's size (with-SDK minus without-SDK).

Metric Target Branch This PR Change
App Bundle Impact 1.67 MB 1.67 MB +N/A
Executable Impact 896 bytes 896 bytes +N/A
XCFramework Size 9.12 MB 9.11 MB -4 KB

➡️ SDK size impact change is minimal.

Raw measurements

Target branch (workstation/9.0-Release):

{"baseline_app_size_kb":84,"baseline_executable_size_bytes":75464,"with_sdk_app_size_kb":1792,"with_sdk_executable_size_bytes":76360,"sdk_impact_kb":1708,"sdk_executable_impact_bytes":896,"xcframework_size_kb":9336}

This PR:

{"baseline_app_size_kb":84,"baseline_executable_size_bytes":75464,"with_sdk_app_size_kb":1792,"with_sdk_executable_size_bytes":76360,"sdk_impact_kb":1708,"sdk_executable_impact_bytes":896,"xcframework_size_kb":9332}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants