Skip to content

MOBILE-52: Add timeout for in-app image loading#720

Merged
enotniy merged 3 commits into
developfrom
feature/MOBILE-52
May 27, 2026
Merged

MOBILE-52: Add timeout for in-app image loading#720
enotniy merged 3 commits into
developfrom
feature/MOBILE-52

Conversation

@enotniy
Copy link
Copy Markdown
Collaborator

@enotniy enotniy commented May 26, 2026

@enotniy enotniy force-pushed the feature/MOBILE-52 branch from 534e83f to e83eac5 Compare May 26, 2026 12:55
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

This PR aims to enforce a timeout and screen-bounded sizing for in-app image loading to avoid long hangs and overly large image decodes during in-app rendering.

Changes:

  • Added coroutine-level timeout handling and screen-size-based image preloading in InAppGlideImageLoaderImpl.
  • Updated in-app view image loading to apply timeout, caching strategy, and sizing constraints.
  • Added unit tests covering success/failure/timeout/cancellation behavior for the Glide-based image loader.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
sdk/src/test/java/cloud/mindbox/mobile_sdk/inapp/data/managers/InAppGlideImageLoaderImplTest.kt Adds unit tests validating image load success/failure, timeout behavior, and cancellation cleanup.
sdk/src/main/java/cloud/mindbox/mobile_sdk/managers/GatewayManager.kt Modifies mobile config fetching behavior (currently returns hardcoded JSON instead of network response).
sdk/src/main/java/cloud/mindbox/mobile_sdk/inapp/presentation/view/AbstractInAppViewHolder.kt Applies timeout + size override + cache strategy when loading in-app images into views.
sdk/src/main/java/cloud/mindbox/mobile_sdk/inapp/data/managers/InAppGlideImageLoaderImpl.kt Implements timeout-aware Glide preload with sizing and improved error handling.
sdk/src/main/java/cloud/mindbox/mobile_sdk/Extensions.kt Adds Context.maxScreenDimension() helper used to bound image sizes.

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

Copilot AI review requested due to automatic review settings May 26, 2026 13:48
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

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

@enotniy enotniy merged commit ca7df9e into develop May 27, 2026
6 checks passed
@enotniy enotniy deleted the feature/MOBILE-52 branch May 27, 2026 12:11
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