Skip to content

Commit 286866d

Browse files
Mpdreamzclaude
andauthored
[1/5] VSA: Merge Elastic.Documentation.Api.* into single project (#3333)
* Merge Elastic.Documentation.Api.* into single project Three projects (Api.Core, Api.Infrastructure, Api.App) collapsed into Elastic.Documentation.Api. Mcp.Remote no longer references any Api.* project — its only deps are ServiceDefaults, services/Search, and services/Assembler. Key moves: - EuidSpanProcessor + EuidLogProcessor → ServiceDefaults (shared) - AddEuidEnrichment helper added to ServiceDefaults - Search gateway interfaces (IFullSearchGateway, INavigationSearchGateway, IChangesGateway) → services/Elastic.Documentation.Search - McpToolSourceName constant inlined into Mcp.Remote Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com> * Fix C# import ordering and name simplification after Api merge Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com> * Fix Dockerfile publish RID to use TARGETARCH/TARGETOS instead of linux-x64 Enables arm64 image builds to publish and copy the correct architecture artifact rather than always using the amd64 binary. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com> * Address PR review: OTel source registration, assembly version, env var key - Register McpTools ActivitySource in Mcp.Remote TracerProvider so MCP spans are captured - Use GetEntryAssembly() over GetCallingAssembly() for service.version so the host service's version is reported rather than ServiceDefaults - OtlpProxyOptions now checks OTEL_EXPORTER_OTLP_ENDPOINT first then OTLP_PROXY_ENDPOINT as backward-compatible fallback, matching the documented priority order Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com> * Fix import ordering in Mcp.Remote Program.cs Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com> * [2/5] VSA: Collapse Gateway+Usecase into *Service per feature (#3335) Co-authored-by: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
1 parent d2ee28b commit 286866d

227 files changed

Lines changed: 1279 additions & 1313 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

aspire/AppHost.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ internal static async Task Run(
6161

6262
var elasticsearchRemote = builder.AddExternalService(ElasticsearchRemote, elasticsearchUrl);
6363

64-
var api = builder.AddProject<Projects.Elastic_Documentation_Api_App>(Api)
64+
var api = builder.AddProject<Projects.Elastic_Documentation_Api>(Api)
6565
.WithArgs(GlobalArguments)
6666
.WithEnvironment("ENVIRONMENT", "dev")
6767
.WithEnvironment("LLM_GATEWAY_FUNCTION_URL", llmUrl)

aspire/aspire.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
</ItemGroup>
2121

2222
<ItemGroup>
23-
<ProjectReference Include="..\src\api\Elastic.Documentation.Api.App\Elastic.Documentation.Api.App.csproj" />
23+
<ProjectReference Include="..\src\api\Elastic.Documentation.Api\Elastic.Documentation.Api.csproj" />
2424
<ProjectReference Include="..\src\api\Elastic.Documentation.Mcp.Remote\Elastic.Documentation.Mcp.Remote.csproj" />
2525
<ProjectReference Include="..\src\tooling\docs-builder\docs-builder.csproj"/>
2626
<ProjectReference Include="..\src\Elastic.Documentation\Elastic.Documentation.csproj" IsAspireProjectResource="false" />

docs-builder.slnx

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,12 +53,11 @@
5353
<Project Path="src/Elastic.Documentation.Site/Elastic.Documentation.Site.csproj" />
5454
<Project Path="src/Elastic.Documentation.Svg/Elastic.Documentation.Svg.csproj" />
5555
<Project Path="src/Elastic.Documentation/Elastic.Documentation.csproj" />
56+
<Project Path="src/Elastic.Documentation.Tooling/Elastic.Documentation.Tooling.csproj" />
5657
<Project Path="src/Elastic.Markdown/Elastic.Markdown.csproj" />
5758
</Folder>
5859
<Folder Name="/src/api/">
59-
<Project Path="src/api/Elastic.Documentation.Api.Core/Elastic.Documentation.Api.Core.csproj" />
60-
<Project Path="src/api/Elastic.Documentation.Api.Infrastructure/Elastic.Documentation.Api.Infrastructure.csproj" />
61-
<Project Path="src/api/Elastic.Documentation.Api.App/Elastic.Documentation.Api.App.csproj" />
60+
<Project Path="src/api/Elastic.Documentation.Api/Elastic.Documentation.Api.csproj" />
6261
<Project Path="src/api/Elastic.Documentation.Mcp.Remote/Elastic.Documentation.Mcp.Remote.csproj" />
6362
</Folder>
6463
<Folder Name="/src/authoring/">
@@ -74,7 +73,10 @@
7473
<Project Path="src/services/Elastic.Documentation.Isolated/Elastic.Documentation.Isolated.csproj" />
7574
<Project Path="src/services/Elastic.Documentation.Integrations/Elastic.Documentation.Integrations.csproj" />
7675
<Project Path="src/services/Elastic.Documentation.Services/Elastic.Documentation.Services.csproj" />
77-
<Project Path="src/services/Elastic.Documentation.Search/Elastic.Documentation.Search.csproj" />
76+
</Folder>
77+
<Folder Name="/src/services/search/">
78+
<Project Path="src/services/search/Elastic.Documentation.Search/Elastic.Documentation.Search.csproj" />
79+
<Project Path="src/services/search/Elastic.Documentation.Search.Contract/Elastic.Documentation.Search.Contract.csproj" />
7880
</Folder>
7981
<Folder Name="/src/tooling/">
8082
<File Path="src/tooling/Directory.Build.props" />

src/Elastic.ApiExplorer/Elasticsearch/OpenApiDocumentExporter.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
using Elastic.Documentation.Configuration.Inference;
1212
using Elastic.Documentation.Configuration.Versions;
1313
using Elastic.Documentation.Search;
14+
using Elastic.Documentation.Versions;
1415
using Microsoft.OpenApi;
1516
using Microsoft.OpenApi.Reader;
1617

@@ -177,7 +178,7 @@ private IEnumerable<DocumentationDocument> ConvertToDocuments(OpenApiDocument op
177178
StrippedBody = body,
178179
Headings = headings,
179180
Links = [],
180-
Applies = applies,
181+
Applies = applies?.ToAppliesTo(),
181182
Parents =
182183
[
183184
new ParentDocument { Title = "API Reference", Url = "/docs/api" },

src/Elastic.ApiExplorer/Operations/AvailabilityBadgeHelper.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
using Elastic.Documentation.AppliesTo;
99
using Elastic.Documentation.Configuration.Versions;
1010
using Elastic.Documentation.Diagnostics;
11+
using Elastic.Documentation.Versions;
1112
using Microsoft.OpenApi;
1213

1314
namespace Elastic.ApiExplorer.Operations;

src/Elastic.Codex/Building/CodexBuildService.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
using Elastic.Codex.Sourcing;
1111
using Elastic.Documentation;
1212
using Elastic.Documentation.Configuration;
13+
using Elastic.Documentation.Configuration.Builder;
1314
using Elastic.Documentation.Configuration.Codex;
1415
using Elastic.Documentation.Diagnostics;
1516
using Elastic.Documentation.Isolated;

src/Elastic.Documentation.Configuration/Assembler/AssemblyConfiguration.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
using System.Text.RegularExpressions;
66
using Elastic.Documentation.Configuration.Products;
77
using Elastic.Documentation.Extensions;
8+
using Elastic.Documentation.Versions;
89
using Microsoft.Extensions.Logging;
910
using YamlDotNet.Serialization;
1011

src/Elastic.Documentation.Configuration/BuildContext.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ public BuildContext(
117117
if (ConfigurationPath.FullName != DocumentationSourceDirectory.FullName)
118118
DocumentationSourceDirectory = ConfigurationPath.Directory!;
119119

120-
Git = gitCheckoutInformation ?? GitCheckoutInformation.Create(DocumentationCheckoutDirectory, ReadFileSystem);
120+
Git = gitCheckoutInformation ?? GitCheckoutInformationFactory.Create(DocumentationCheckoutDirectory, ReadFileSystem);
121121

122122
// Load and resolve the docset file, or create an empty one if it doesn't exist
123123
ConfigurationYaml = ConfigurationPath.Exists

src/Elastic.Documentation.Configuration/Builder/ConfigurationFile.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
using Elastic.Documentation.Diagnostics;
1212
using Elastic.Documentation.Extensions;
1313
using Elastic.Documentation.Links;
14-
using static Elastic.Documentation.Configuration.SymlinkValidator;
14+
using static Elastic.Documentation.SymlinkValidator;
1515

1616
namespace Elastic.Documentation.Configuration.Builder;
1717

src/Elastic.Documentation.Configuration/CrossLinkEntry.cs renamed to src/Elastic.Documentation.Configuration/Builder/CrossLinkEntry.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
33
// See the LICENSE file in the project root for more information
44

5-
namespace Elastic.Documentation.Configuration;
5+
namespace Elastic.Documentation.Configuration.Builder;
66

77
/// <summary>
88
/// A parsed cross-link entry from docset.yml, with the target registry for lookup.

0 commit comments

Comments
 (0)