Skip to content

Commit 4ba4567

Browse files
committed
Fix NETSDK1022: remove case-colliding licenseKey redirect
Remove MCP feature (Docs.Mcp, Docs.Indexer, MCP endpoint, search tools, build-time indexer).
1 parent 8e76e48 commit 4ba4567

23 files changed

Lines changed: 8 additions & 1234 deletions

.gitignore

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@ astro/dist/
33
astro/root/
44
server/Docs.Web/wwwroot/
55

6-
# MCP index database (generated at build time)
7-
server/Docs.Web/data/
86
# generated types
97
astro/.astro/
108

README.md

Lines changed: 3 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,10 @@ All commands use the `build.cs` file-based build script and can be run from any
3737

3838
| Command | Action |
3939
| :------ | :----- |
40-
| `dotnet build.cs` | Build everything (Astro + .NET + MCP index) |
40+
| `dotnet build.cs` | Build everything (Astro + .NET) |
4141
| `dotnet build.cs astro-build` | Build Astro to wwwroot |
4242
| `dotnet build.cs dotnet-build` | Build .NET solution |
4343
| `dotnet build.cs container` | Build container image |
44-
| `dotnet build.cs mcp-index` | Build MCP search index database |
4544
| `dotnet build.cs aspire` | Start Aspire dev environment |
4645
| `dotnet build.cs clean` | Clean all build outputs |
4746
| `dotnet build.cs verify-formatting` | Check .NET code formatting |
@@ -65,41 +64,6 @@ docker run -p 8080:8080 docs
6564

6665
The site will be available at http://localhost:8080.
6766

68-
## MCP Server
69-
70-
The documentation site exposes a [Model Context Protocol (MCP)](https://modelcontextprotocol.io/) endpoint at `/mcp` for AI-powered search. This enables AI assistants to search and retrieve documentation, blog posts, and code samples.
71-
72-
### Available Tools
73-
74-
| Tool | Description |
75-
| :--- | :---------- |
76-
| `search_duende_docs` | Full-text search across documentation |
77-
| `fetch_duende_docs` | Retrieve a specific documentation article |
78-
| `search_duende_blog` | Full-text search across blog posts |
79-
| `fetch_duende_blog` | Retrieve a specific blog post |
80-
| `search_duende_samples` | Full-text search across code samples |
81-
| `fetch_duende_sample` | Get sample project metadata and file list |
82-
| `fetch_duende_sample_file` | Retrieve a specific file from a sample |
83-
84-
### Building the Index
85-
86-
The MCP search index is built at build time (not runtime) using the `mcp-index` target:
87-
88-
```bash
89-
dotnet build.cs mcp-index
90-
```
91-
92-
This creates a SQLite FTS5 database at `server/Docs.Web/data/mcp.db` containing:
93-
- Documentation articles (from Astro's `_llms-txt/*.txt` output)
94-
- Blog posts (fetched from RSS feed)
95-
- Code samples (downloaded from GitHub)
96-
97-
The index is automatically built as part of the `build` and `container` targets. Locally, subsequent runs skip indexing if the database already exists. Use `--force` to rebuild:
98-
99-
```bash
100-
dotnet run --project server/Docs.Indexer -- --wwwroot <path> --output <path> --force
101-
```
102-
10367
## Project Structure
10468

10569
This project uses Astro + Starlight for the documentation site, served by ASP.NET Core in production.
@@ -118,11 +82,8 @@ This project uses Astro + Starlight for the documentation site, served by ASP.NE
11882
│ ├── package.json
11983
│ └── tsconfig.json
12084
└── server/ # ASP.NET Core server
121-
├── Docs.Web/ # Static file server + MCP endpoint
122-
│ ├── wwwroot/ # Astro build output (gitignored)
123-
│ └── data/ # MCP database (gitignored)
124-
├── Docs.Mcp/ # MCP server library (search tools)
125-
├── Docs.Indexer/ # Build-time search indexer
85+
├── Docs.Web/ # Static file server
86+
│ └── wwwroot/ # Astro build output (gitignored)
12687
├── Docs.AppHost/ # .NET Aspire orchestrator
12788
└── Docs.ServiceDefaults/ # Shared configuration
12889
```

astro/src/content/docs/general/licensing.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ tableOfContents:
88
maxHeadingLevel: 4
99
redirect_from:
1010
- /licensekey/
11-
- /licenseKey/
1211
- /trial-mode/
1312
- /identityserver/v5/fundamentals/license_key/
1413
- /identityserver/v6/fundamentals/license_key/

build.cs

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
const string LinkCheck = "link-check";
2828
const string VerifyFormatting = "verify-formatting";
2929
const string Clean = "clean";
30-
const string McpIndex = "mcp-index";
3130
const string Default = "default";
3231

3332
// Restore
@@ -65,10 +64,10 @@ await RunAsync("docker",
6564
RunAsync("dotnet", "publish Docs.Web/Docs.Web.csproj -c Release --no-restore",
6665
workingDirectory: serverDir));
6766

68-
Target(Build, dependsOn: [AstroBuild, DotnetBuild, McpIndex]);
67+
Target(Build, dependsOn: [AstroBuild, DotnetBuild]);
6968

7069
// Container (no Dockerfile needed!)
71-
Target(Container, dependsOn: [AstroBuild, McpIndex], () =>
70+
Target(Container, dependsOn: [AstroBuild], () =>
7271
RunAsync("dotnet", "publish Docs.Web/Docs.Web.csproj -c Release /t:PublishContainer",
7372
workingDirectory: serverDir));
7473

@@ -84,25 +83,12 @@ await RunAsync("docker",
8483
RunAsync("dotnet", "format Docs.slnx --verify-no-changes --no-restore",
8584
workingDirectory: serverDir));
8685

87-
// MCP Index - build the search database
88-
var mcpDataDir = Path.Combine(serverDir, "Docs.Web", "data");
89-
Target(McpIndex, dependsOn: [AstroBuild, Restore], async () =>
90-
{
91-
Directory.CreateDirectory(mcpDataDir);
92-
var mcpDbPath = Path.Combine(mcpDataDir, "mcp.db");
93-
await RunAsync("dotnet",
94-
$"run --project Docs.Indexer -- --wwwroot \"{wwwrootDir}\" --output \"{mcpDbPath}\"",
95-
workingDirectory: serverDir);
96-
});
97-
9886
// Clean
9987
Target(Clean, async () =>
10088
{
10189
await RunAsync("dotnet", "clean Docs.slnx", workingDirectory: serverDir);
10290
if (Directory.Exists(wwwrootDir))
10391
Directory.Delete(wwwrootDir, recursive: true);
104-
if (Directory.Exists(mcpDataDir))
105-
Directory.Delete(mcpDataDir, recursive: true);
10692
});
10793

10894
Target(Default, dependsOn: [Build]);

server/Docs.Indexer/Docs.Indexer.csproj

Lines changed: 0 additions & 20 deletions
This file was deleted.

server/Docs.Indexer/Indexers/BlogIndexer.cs

Lines changed: 0 additions & 102 deletions
This file was deleted.

0 commit comments

Comments
 (0)