1 write to Layout
Aspire.Hosting (1)
ApplicationModel\TerminalHostResource.cs (1)
34Layout = layout;
76 references to Layout
Aspire.Hosting (11)
ApplicationModel\ResourceTerminalCatalog.cs (2)
93ConsumerUdsPath: host.Layout.ConsumerUdsPath, 94ControlUdsPath: host.Layout.ControlUdsPath,
ApplicationModel\TerminalHostResource.cs (1)
52public int ParentReplicaIndex => Layout.ParentReplicaIndex;
ApplicationModel\TerminalResourceSnapshotProperties.cs (1)
53? terminalHosts[replicaIndex].Layout.ConsumerUdsPath
Backchannel\AuxiliaryBackchannelRpcTarget.cs (2)
503/// for the consumer UDS path and replica index — those come from <see cref="TerminalHostResource.Layout"/> 512var layout = host.Layout;
Dcp\ContainerCreator.cs (1)
279UdsPath = terminalAnnotation.TerminalHosts[0].Layout.ProducerUdsPath,
Dcp\ExecutableCreator.cs (1)
391UdsPath = terminalAnnotation.TerminalHosts[replicaIndex].Layout.ProducerUdsPath,
TerminalResourceBuilderExtensions.cs (3)
390context.Args.Add(host.Layout.ProducerUdsPath); 393context.Args.Add(host.Layout.ConsumerUdsPath); 396context.Args.Add(host.Layout.ControlUdsPath);
Aspire.Hosting.Tests (65)
Backchannel\GetTerminalInfoAsyncTests.cs (8)
80Assert.Equal(hosts[i].Layout.ConsumerUdsPath, result.Replicas[i].ConsumerUdsPath); 145Assert.Equal(hosts[0].Layout.ConsumerUdsPath, result.Replicas[0].ConsumerUdsPath); 163Assert.Equal(hosts[1].Layout.ConsumerUdsPath, result.Replicas[1].ConsumerUdsPath); 196Assert.Equal(hosts[0].Layout.ConsumerUdsPath, result.Replicas[0].ConsumerUdsPath); 197Assert.Equal(hosts[1].Layout.ConsumerUdsPath, result.Replicas[1].ConsumerUdsPath); 226Assert.Equal(hosts[i].Layout.ConsumerUdsPath, summary.Replicas[i].ConsumerUdsPath); 260Assert.Equal(hosts[0].Layout.ConsumerUdsPath, summary.Replicas[0].ConsumerUdsPath); 261Assert.Equal(hosts[1].Layout.ConsumerUdsPath, summary.Replicas[1].ConsumerUdsPath);
Dashboard\DashboardServiceDataTerminalTests.cs (4)
68Assert.Equal(GetTerminalHosts(resource)[0].Layout.ConsumerUdsPath, path.Value.StringValue); 94GetTerminalHosts(resource)[2].Layout.ConsumerUdsPath, 116GetTerminalHosts(resource)[0].Layout.ConsumerUdsPath, 141GetTerminalHosts(resource)[0].Layout.ConsumerUdsPath,
Dcp\DcpExecutorTests.cs (3)
11150Assert.Equal(hosts[i].Layout.ProducerUdsPath, spec!.UdsPath); 11211Assert.Equal(host.Layout.ProducerUdsPath, exe.Spec.Terminal!.UdsPath); 11255Assert.Equal(host.Layout.ProducerUdsPath, container.Spec.Terminal!.UdsPath);
WithTerminalTests.cs (50)
396h.Layout.MetadataPath, 397h.Layout.ProducerUdsPath, 398h.Layout.ConsumerUdsPath, 399h.Layout.ControlUdsPath, 406File.Exists(host.Layout.MetadataPath), 407$"Metadata sidecar '{host.Layout.MetadataPath}' should exist after BeforeStartEvent."); 411File.WriteAllText(host.Layout.ProducerUdsPath, string.Empty); 412File.WriteAllText(host.Layout.ConsumerUdsPath, string.Empty); 413File.WriteAllText(host.Layout.ControlUdsPath, string.Empty); 456Assert.True(File.Exists(host.Layout.MetadataPath)); 458using var doc = JsonDocument.Parse(await File.ReadAllTextAsync(host.Layout.MetadataPath)); 462Assert.Equal(host.Layout.ReplicaId, root.GetProperty("replicaId").GetString()); 477Assert.Equal(host.Layout.ControlUdsPath, root.GetProperty("controlSocketPath").GetString()); 478Assert.Equal(host.Layout.ConsumerUdsPath, root.GetProperty("consumerSocketPath").GetString()); 481Assert.Equal(_terminalDirectory, Path.GetDirectoryName(host.Layout.MetadataPath)); 482Assert.False(File.Exists(TerminalHostPaths.GetMetadataTemporaryPath(host.Layout.MetadataPath))); 489var mode = File.GetUnixFileMode(host.Layout.MetadataPath); 1093host.Layout.MetadataPath, 1094host.Layout.ProducerUdsPath, 1095host.Layout.ConsumerUdsPath, 1096host.Layout.ControlUdsPath); 1146Assert.NotEmpty(single.Layout.ProducerUdsPath); 1147Assert.NotEmpty(single.Layout.ConsumerUdsPath); 1148Assert.NotEmpty(single.Layout.ControlUdsPath); 1170Assert.NotEmpty(hosts[i].Layout.ReplicaId); 1171Assert.StartsWith(hosts[i].Layout.ReplicaId + ".", Path.GetFileName(hosts[i].Layout.ProducerUdsPath)); 1172Assert.StartsWith(hosts[i].Layout.ReplicaId + ".", Path.GetFileName(hosts[i].Layout.ConsumerUdsPath)); 1219Assert.Equal(expectedDirectory, Path.GetDirectoryName(host.Layout.ProducerUdsPath)); 1220Assert.Equal(expectedDirectory, Path.GetDirectoryName(host.Layout.ConsumerUdsPath)); 1221Assert.Equal(expectedDirectory, Path.GetDirectoryName(host.Layout.ControlUdsPath)); 1222Assert.Equal(expectedDirectory, Path.GetDirectoryName(host.Layout.MetadataPath)); 1224Assert.StartsWith(host.Layout.ReplicaId + ".", Path.GetFileName(host.Layout.ProducerUdsPath)); 1225Assert.StartsWith(host.Layout.ReplicaId + ".", Path.GetFileName(host.Layout.ConsumerUdsPath)); 1226Assert.StartsWith(host.Layout.ReplicaId + ".", Path.GetFileName(host.Layout.ControlUdsPath)); 1227Assert.StartsWith(host.Layout.ReplicaId + ".", Path.GetFileName(host.Layout.MetadataPath)); 1231Assert.True(seenReplicaIds.Add(host.Layout.ReplicaId), $"Duplicate replica id '{host.Layout.ReplicaId}'."); 1242firstResource.Resource.Annotations.OfType<TerminalAnnotation>().Single().TerminalHosts).Layout.ReplicaId; 1248secondResource.Resource.Annotations.OfType<TerminalAnnotation>().Single().TerminalHosts).Layout.ReplicaId; 1303Assert.Contains(host.Layout.ProducerUdsPath, args); 1304Assert.Contains(host.Layout.ConsumerUdsPath, args); 1305Assert.Contains(host.Layout.ControlUdsPath, args); 1403Assert.Equal(directory, Path.GetDirectoryName(host.Layout.MetadataPath)); 1404Assert.True(File.Exists(host.Layout.MetadataPath));