Ensure Mutagen waits for the CLI container during docker/sdk up with Tideways#628
Open
pwnyprod wants to merge 1 commit into
Open
Conversation
Author
|
For recreating and testing this issue:
image:
tag: spryker/php:8.3-debian
...
php:
enabled-extensions:
- tideways
ini:
...
tideways.features.distributed_tracing: 1
tideways.features.redis_keys: 1
tideways.features.crawler_detection: 1
...
services:
...
tideways:
apikey: XXX
engine: tideways
environment: XXX
environment-name: XXX
cli-enabled: trueafter enabling tideways:
|
kfrohwein
approved these changes
May 27, 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.
Description
This change makes Mutagen target the CLI container explicitly and ensures the CLI container is started during
docker/sdk up.Previously, the sync flow implicitly relied on the CLI container being available early enough. With additional services such as Tideways starting first, Mutagen could run before the CLI container was ready or fall back to a different running container. This caused the sync setup to become unreliable.
The patch fixes this by:
upDetails
Problem
The current Mutagen startup flow implicitly assumes that the CLI container is available early enough during
docker/sdk up.This becomes fragile when another container (for example Tideways) starts before the CLI container. In that case:
Solution
This patch makes the CLI container the explicit sync target and ensures it is started before the Mutagen session is created.
Result
docker/sdk upno longer depends on the CLI container being the first relevant container that comes up.Mutagen now waits for the CLI container explicitly and always creates the sync session against it.
Related resources
Change log
Compose::ensureCliRunning()fromCompose::up()after the regular compose runMount::Mutagen::waitForCliContainer()and use it before creating the sync sessionfindTargetContainer()to the CLI container onlyafterRun()defer sync creation instead of failing hard when the CLI container is not running yetChecklist