VolumeMountBindingAnnotation Constructors
Constructor(string) Section titled Constructor(string)public sealed class VolumeMountBindingAnnotation{ public VolumeMountBindingAnnotation( string volumeName) { // ... }}Parameters
volumeName stringRemarks
This annotation is the extensibility point compute environments use to participate in the portable volume path convention. It carries two independent facets, either of which may be absent:
Volumerecords that the workload reads the effective storage path from an environment variable. The variable itself is written by anMount Binding Annotation. Environment Variable Name Environmentwhose closure captures the name, which makes the intent invisible to anything inspecting the model. Restating it here lets a compute environment tell whether a host process materializes a local backing store for the volume, without having to observe the callback running.Callback Annotation Volumelets a compute environment supply the local directory that backs the volume in run mode. Without it, host processes fall back to a workload-scoped directory underMount Binding Annotation. Run Mode Host Path Resolver I.Aspire Store
The two facets are produced by different parties at different times — the AppHost author opts into the environment variable, while the compute environment supplies the local path — so a resource can carry several of these annotations for the same Volume. A binding resolves through its own Volume when it has one, and otherwise takes the last sibling that does. Volume alone is not a unique key, because separate compute environments can each declare a volume under the same name.