Skip to content

Containers targets need to keep 'execution time' data ordering consistent for single-RID publishes #48579

Open
@baronfel

Description

@baronfel

Describe the bug

We broke an ordering contract with the ComputeContainerConfig target that the VSCode Docker Tools were depending on - see microsoft/vscode-docker#4558 for details.

The gist is that before p3, you could call ComputeContainerConfig and get all of the data about a container. But some of that data may var per-RID, so in p3 we broke it out into RID-specific Targets that would fire before each RID-specific container. This is problematic for debug tooling. We need to make sure that for single-RID use cases at least the runtime execution data can be computed before ComputeContainerConfig.

Today, single-RID:

graph TD
    PublishContainer[PublishContainer] --> ContainerVerifySDKVersion[_ContainerVerifySDKVersion]
    PublishContainer --> ComputeContainerConfig[ComputeContainerConfig]
    PublishContainer --> CheckContainersPackage[_CheckContainersPackage]
    PublishContainer --> PublishSingleContainer[_PublishSingleContainer]

    ComputeContainerConfig --> ComputeBaseImage[ComputeContainerBaseImage]

    PublishSingleContainer --> ComputeContainerExecutionArgs[_ComputeContainerExecutionArgs]
    PublishSingleContainer --> CreateNewImage[CreateNewImage]
Loading

Today, multi-RID:

graph TD
    PublishContainer[PublishContainer] --> ContainerVerifySDKVersion[_ContainerVerifySDKVersion]
    PublishContainer --> ComputeContainerConfig[ComputeContainerConfig]
    PublishContainer --> CheckContainersPackage[_CheckContainersPackage]
    PublishContainer --> PublishMultiArchContainers[_PublishMultiArchContainers]

    ComputeContainerConfig --> ComputeBaseImage[ComputeContainerBaseImage]

    PublishMultiArchContainers --> ForEachRID{For each RID}
    ForEachRID --> |Per RID| PublishSingleContainer[_PublishSingleContainer]
    PublishSingleContainer --> ComputeContainerExecutionArgs[_ComputeContainerExecutionArgs]
    PublishSingleContainer --> CreateNewImage[CreateNewImage Task]

    PublishMultiArchContainers --> ParseItems[_ParseItemsForPublishingSingleContainer]
    PublishMultiArchContainers --> CreateImageIndex[CreateImageIndex Task]
Loading

Proposed, single-RID:

graph TD
    PublishContainer[PublishContainer] --> ContainerVerifySDKVersion[_ContainerVerifySDKVersion]
    PublishContainer --> ComputeContainerConfig[ComputeContainerConfig]
    PublishContainer --> CheckContainersPackage[_CheckContainersPackage]
    PublishContainer --> PublishSingleContainer[_PublishSingleContainer]

    ComputeContainerConfig --> ComputeBaseImage[ComputeContainerBaseImage]
    ComputeContainerConfig --> ComputeContainerExecutionArgs[_ComputeContainerExecutionArgs]

    PublishSingleContainer --> CreateNewImage[CreateNewImage]
Loading

Metadata

Metadata

Labels

Area-ContainersRelated to dotnet SDK containers functionalityBug

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions