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)
398UdsPath = terminalAnnotation.TerminalHosts[replicaIndex].Layout.ProducerUdsPath,
TerminalResourceBuilderExtensions.cs (3)
376context.Args.Add(host.Layout.ProducerUdsPath); 379context.Args.Add(host.Layout.ConsumerUdsPath); 382context.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)
88Assert.Equal(GetTerminalHosts(resource)[0].Layout.ConsumerUdsPath, path.Value.StringValue); 114GetTerminalHosts(resource)[2].Layout.ConsumerUdsPath, 136GetTerminalHosts(resource)[0].Layout.ConsumerUdsPath, 161GetTerminalHosts(resource)[0].Layout.ConsumerUdsPath,
Dcp\DcpExecutorTests.cs (3)
11865Assert.Equal(hosts[i].Layout.ProducerUdsPath, spec!.UdsPath); 11926Assert.Equal(host.Layout.ProducerUdsPath, exe.Spec.Terminal!.UdsPath); 11970Assert.Equal(host.Layout.ProducerUdsPath, container.Spec.Terminal!.UdsPath);
WithTerminalTests.cs (50)
470h.Layout.MetadataPath, 471h.Layout.ProducerUdsPath, 472h.Layout.ConsumerUdsPath, 473h.Layout.ControlUdsPath, 480File.Exists(host.Layout.MetadataPath), 481$"Metadata sidecar '{host.Layout.MetadataPath}' should exist after BeforeStartEvent."); 485File.WriteAllText(host.Layout.ProducerUdsPath, string.Empty); 486File.WriteAllText(host.Layout.ConsumerUdsPath, string.Empty); 487File.WriteAllText(host.Layout.ControlUdsPath, string.Empty); 530Assert.True(File.Exists(host.Layout.MetadataPath)); 532using var doc = JsonDocument.Parse(await File.ReadAllTextAsync(host.Layout.MetadataPath)); 536Assert.Equal(host.Layout.ReplicaId, root.GetProperty("replicaId").GetString()); 551Assert.Equal(host.Layout.ControlUdsPath, root.GetProperty("controlSocketPath").GetString()); 552Assert.Equal(host.Layout.ConsumerUdsPath, root.GetProperty("consumerSocketPath").GetString()); 555Assert.Equal(_terminalDirectory, Path.GetDirectoryName(host.Layout.MetadataPath)); 556Assert.False(File.Exists(TerminalHostPaths.GetMetadataTemporaryPath(host.Layout.MetadataPath))); 563var mode = File.GetUnixFileMode(host.Layout.MetadataPath); 1167host.Layout.MetadataPath, 1168host.Layout.ProducerUdsPath, 1169host.Layout.ConsumerUdsPath, 1170host.Layout.ControlUdsPath); 1220Assert.NotEmpty(single.Layout.ProducerUdsPath); 1221Assert.NotEmpty(single.Layout.ConsumerUdsPath); 1222Assert.NotEmpty(single.Layout.ControlUdsPath); 1244Assert.NotEmpty(hosts[i].Layout.ReplicaId); 1245Assert.StartsWith(hosts[i].Layout.ReplicaId + ".", Path.GetFileName(hosts[i].Layout.ProducerUdsPath)); 1246Assert.StartsWith(hosts[i].Layout.ReplicaId + ".", Path.GetFileName(hosts[i].Layout.ConsumerUdsPath)); 1293Assert.Equal(expectedDirectory, Path.GetDirectoryName(host.Layout.ProducerUdsPath)); 1294Assert.Equal(expectedDirectory, Path.GetDirectoryName(host.Layout.ConsumerUdsPath)); 1295Assert.Equal(expectedDirectory, Path.GetDirectoryName(host.Layout.ControlUdsPath)); 1296Assert.Equal(expectedDirectory, Path.GetDirectoryName(host.Layout.MetadataPath)); 1298Assert.StartsWith(host.Layout.ReplicaId + ".", Path.GetFileName(host.Layout.ProducerUdsPath)); 1299Assert.StartsWith(host.Layout.ReplicaId + ".", Path.GetFileName(host.Layout.ConsumerUdsPath)); 1300Assert.StartsWith(host.Layout.ReplicaId + ".", Path.GetFileName(host.Layout.ControlUdsPath)); 1301Assert.StartsWith(host.Layout.ReplicaId + ".", Path.GetFileName(host.Layout.MetadataPath)); 1305Assert.True(seenReplicaIds.Add(host.Layout.ReplicaId), $"Duplicate replica id '{host.Layout.ReplicaId}'."); 1316firstResource.Resource.Annotations.OfType<TerminalAnnotation>().Single().TerminalHosts).Layout.ReplicaId; 1322secondResource.Resource.Annotations.OfType<TerminalAnnotation>().Single().TerminalHosts).Layout.ReplicaId; 1377Assert.Contains(host.Layout.ProducerUdsPath, args); 1378Assert.Contains(host.Layout.ConsumerUdsPath, args); 1379Assert.Contains(host.Layout.ControlUdsPath, args); 1479Assert.Equal(directory, Path.GetDirectoryName(host.Layout.MetadataPath)); 1480Assert.True(File.Exists(host.Layout.MetadataPath));