[release/13.0] MAUI Integration Android + OtlpDevTunnel#12762
Closed
jfversluis wants to merge 15 commits into
Closed
[release/13.0] MAUI Integration Android + OtlpDevTunnel#12762jfversluis wants to merge 15 commits into
jfversluis wants to merge 15 commits into
Conversation
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Simplifies MauiAndroidEnvironmentProcessedAnnotation by removing the unused TargetsFilePath property and constructor. Updates usage to reflect the new parameterless constructor and clarifies documentation to indicate the annotation is a marker for callback registration.
…r.cs" This reverts commit 8f17d90.
Replaces hardcoded default OTLP port and URL values with named constants and static readonly fields for improved maintainability and clarity.
Contributor
|
🚀 Dogfood this PR with:
curl -fsSL https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 12762Or
iex "& { $(irm https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 12762" |
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds Android platform support (device and emulator) to the Aspire MAUI hosting integration, consolidates platform-specific tests to reduce duplication, and introduces dev tunnel support for OpenTelemetry connectivity on mobile platforms.
Key changes:
- Adds
MauiAndroidDeviceResourceandMauiAndroidEmulatorResourcewith full extension methods for adding Android targets to MAUI projects - Implements environment variable forwarding for Android via MSBuild targets files (required due to Android platform limitations)
- Creates shared OTLP dev tunnel infrastructure (
WithOtlpDevTunnel()) for mobile platforms that cannot reach localhost - Consolidates platform extension tests into a single theory-based test file using
PlatformTestConfig
Reviewed Changes
Copilot reviewed 28 out of 28 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| MauiPlatformExtensionsTests.cs | New consolidated test file replacing separate platform test files using theory-based testing |
| MauiWindowsExtensionsTests.cs | Deleted - tests moved to consolidated file |
| MauiMacCatalystExtensionsTests.cs | Deleted - tests moved to consolidated file |
| MauiAndroidExtensions.cs | New Android device/emulator extension methods with comprehensive documentation |
| MauiAndroidDeviceResource.cs | New resource class for Android physical devices |
| MauiAndroidEmulatorResource.cs | New resource class for Android emulators |
| MauiAndroidEnvironmentAnnotation.cs | Subscriber and annotations for Android environment variable handling via MSBuild |
| MauiEnvironmentHelper.cs | Utility for generating MSBuild targets files for Android environment variables |
| MauiOtlpExtensions.cs | New WithOtlpDevTunnel() extension for mobile OTLP connectivity |
| OtlpEndpointResolver.cs | Shared utility for resolving OTLP endpoint configuration |
| OtlpLoopbackResource.cs | Synthetic resource for OTLP service discovery through dev tunnels |
| IMauiPlatformResource.cs | Updated to extend IResourceWithParent<MauiProjectResource> |
| MauiWindowsPlatformResource.cs | Simplified inheritance - removed redundant interface implementations |
| MauiMacCatalystPlatformResource.cs | Simplified inheritance - removed redundant interface implementations |
| README.md (Aspire.Hosting.Maui) | New comprehensive documentation for MAUI hosting package |
| README.md (playground) | Updated with Android platform examples and environment variable documentation |
87496eb to
da8cc55
Compare
mitchdenny
approved these changes
Nov 6, 2025
Member
|
Assuming this was superseded by #12769 |
Member
Author
|
Correct, closing |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
#12381 but targeting release
Customer Impact
Customers are now able to also use Android for the MAUI integration. Next to Windows and macOS that is already merged. This (the Android platform integration) is currently not available, so no risk for regressions or anything else, just that the first experience might be rough, but the happy path will definitely work and we can take in customer feedback this way.
Testing
Current tests are unchanged and all passing, @maddymontaquila will do some manual testing.
Risk
Low, new package, will be released as preview, if it doesn't work thats not great but also not disastrous
Regression?
N/A