@enokdev/springdocs-mcp 1.2.8 → 1.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +83 -40
- package/build/config.d.ts +9 -0
- package/build/config.d.ts.map +1 -0
- package/build/config.js +32 -0
- package/build/config.js.map +1 -0
- package/build/format.d.ts +6 -0
- package/build/format.d.ts.map +1 -0
- package/build/format.js +23 -0
- package/build/format.js.map +1 -0
- package/build/http-server.d.ts +15 -0
- package/build/http-server.d.ts.map +1 -0
- package/build/http-server.js +131 -0
- package/build/http-server.js.map +1 -0
- package/build/index.js +182 -68
- package/build/index.js.map +1 -1
- package/build/prompts.d.ts +23 -0
- package/build/prompts.d.ts.map +1 -0
- package/build/prompts.js +112 -0
- package/build/prompts.js.map +1 -0
- package/build/resources.d.ts +31 -0
- package/build/resources.d.ts.map +1 -0
- package/build/resources.js +66 -0
- package/build/resources.js.map +1 -0
- package/build/services/advanced-features.d.ts +14 -9
- package/build/services/advanced-features.d.ts.map +1 -1
- package/build/services/advanced-features.js +205 -195
- package/build/services/advanced-features.js.map +1 -1
- package/build/services/boot-wiki.d.ts +25 -0
- package/build/services/boot-wiki.d.ts.map +1 -0
- package/build/services/boot-wiki.js +103 -0
- package/build/services/boot-wiki.js.map +1 -0
- package/build/services/cache.d.ts +18 -3
- package/build/services/cache.d.ts.map +1 -1
- package/build/services/cache.js +84 -3
- package/build/services/cache.js.map +1 -1
- package/build/services/dependency-finder.d.ts +46 -0
- package/build/services/dependency-finder.d.ts.map +1 -0
- package/build/services/dependency-finder.js +181 -0
- package/build/services/dependency-finder.js.map +1 -0
- package/build/services/diagnosis.d.ts +46 -0
- package/build/services/diagnosis.d.ts.map +1 -0
- package/build/services/diagnosis.js +481 -0
- package/build/services/diagnosis.js.map +1 -0
- package/build/services/guides-list.d.ts +16 -0
- package/build/services/guides-list.d.ts.map +1 -0
- package/build/services/guides-list.js +45 -0
- package/build/services/guides-list.js.map +1 -0
- package/build/services/http.d.ts +21 -0
- package/build/services/http.d.ts.map +1 -0
- package/build/services/http.js +168 -0
- package/build/services/http.js.map +1 -0
- package/build/services/initializr.d.ts +41 -0
- package/build/services/initializr.d.ts.map +1 -0
- package/build/services/initializr.js +135 -0
- package/build/services/initializr.js.map +1 -0
- package/build/services/markdown.d.ts +56 -0
- package/build/services/markdown.d.ts.map +1 -0
- package/build/services/markdown.js +146 -0
- package/build/services/markdown.js.map +1 -0
- package/build/services/migration-sources.d.ts +13 -0
- package/build/services/migration-sources.d.ts.map +1 -0
- package/build/services/migration-sources.js +48 -0
- package/build/services/migration-sources.js.map +1 -0
- package/build/services/release-notes.d.ts +23 -0
- package/build/services/release-notes.d.ts.map +1 -0
- package/build/services/release-notes.js +94 -0
- package/build/services/release-notes.js.map +1 -0
- package/build/services/search-index.d.ts +33 -0
- package/build/services/search-index.d.ts.map +1 -0
- package/build/services/search-index.js +147 -0
- package/build/services/search-index.js.map +1 -0
- package/build/services/spring-projects-config.d.ts +26 -33
- package/build/services/spring-projects-config.d.ts.map +1 -1
- package/build/services/spring-projects-config.js +248 -79
- package/build/services/spring-projects-config.js.map +1 -1
- package/build/services/springboot-docs-optimized.d.ts +57 -16
- package/build/services/springboot-docs-optimized.d.ts.map +1 -1
- package/build/services/springboot-docs-optimized.js +315 -197
- package/build/services/springboot-docs-optimized.js.map +1 -1
- package/build/services/url.d.ts +15 -0
- package/build/services/url.d.ts.map +1 -0
- package/build/services/url.js +40 -0
- package/build/services/url.js.map +1 -0
- package/build/tools/index.d.ts +376 -2
- package/build/tools/index.d.ts.map +1 -1
- package/build/tools/index.js +178 -11
- package/build/tools/index.js.map +1 -1
- package/build/validation.d.ts +7 -0
- package/build/validation.d.ts.map +1 -0
- package/build/validation.js +50 -0
- package/build/validation.js.map +1 -0
- package/build/version.d.ts +3 -0
- package/build/version.d.ts.map +1 -0
- package/build/version.js +6 -0
- package/build/version.js.map +1 -0
- package/package.json +6 -6
- package/build/debug.d.ts +0 -3
- package/build/debug.d.ts.map +0 -1
- package/build/debug.js +0 -292
- package/build/debug.js.map +0 -1
- package/build/services/advanced-features-old.d.ts +0 -45
- package/build/services/advanced-features-old.d.ts.map +0 -1
- package/build/services/advanced-features-old.js +0 -792
- package/build/services/advanced-features-old.js.map +0 -1
- package/build/services/springboot-docs-optimized-old.d.ts +0 -55
- package/build/services/springboot-docs-optimized-old.d.ts.map +0 -1
- package/build/services/springboot-docs-optimized-old.js +0 -588
- package/build/services/springboot-docs-optimized-old.js.map +0 -1
- package/build/services/springboot-docs.d.ts +0 -65
- package/build/services/springboot-docs.d.ts.map +0 -1
- package/build/services/springboot-docs.js +0 -708
- package/build/services/springboot-docs.js.map +0 -1
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
* This configuration-driven approach allows adding new Spring projects (Security,
|
|
8
8
|
* Data, Cloud, etc.) with zero code changes - only configuration updates.
|
|
9
9
|
*/
|
|
10
|
+
import { normalizeVersion } from './url.js';
|
|
10
11
|
/**
|
|
11
12
|
* Spring Projects Registry
|
|
12
13
|
*
|
|
@@ -18,14 +19,22 @@ export const SPRING_PROJECTS = new Map([
|
|
|
18
19
|
'boot',
|
|
19
20
|
{
|
|
20
21
|
id: 'boot',
|
|
22
|
+
githubRepo: 'spring-projects/spring-boot',
|
|
23
|
+
githubTagPrefix: 'v',
|
|
24
|
+
versionInsertAfter: 'https://docs.spring.io/spring-boot/',
|
|
21
25
|
displayName: 'Spring Boot',
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
26
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-boot',
|
|
27
|
+
referenceLayout: 'directory',
|
|
28
|
+
referencePaths: {
|
|
29
|
+
'deployment': 'how-to/deployment',
|
|
30
|
+
'native-image': 'reference/packaging/native-image',
|
|
31
|
+
'application-properties': 'appendix/application-properties'
|
|
32
|
+
},
|
|
25
33
|
hasVersionedDocs: true,
|
|
26
34
|
cacheStrategy: 'long', // Stable releases, cache aggressively
|
|
27
|
-
scopes: ['boot', 'web', 'data', 'actuator', 'starters', 'autoconfiguration'],
|
|
28
35
|
referenceSections: [
|
|
36
|
+
'features',
|
|
37
|
+
'using',
|
|
29
38
|
'web',
|
|
30
39
|
'data',
|
|
31
40
|
'messaging',
|
|
@@ -42,36 +51,23 @@ export const SPRING_PROJECTS = new Map([
|
|
|
42
51
|
'ai',
|
|
43
52
|
{
|
|
44
53
|
id: 'ai',
|
|
54
|
+
githubRepo: 'spring-projects/spring-ai',
|
|
55
|
+
githubTagPrefix: 'v',
|
|
56
|
+
versionInsertAfter: 'https://docs.spring.io/spring-ai/reference/',
|
|
45
57
|
displayName: 'Spring AI',
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
hasVersionedDocs: false, // Spring AI docs don't have version in URL path
|
|
58
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-ai/reference/api',
|
|
59
|
+
referenceLayout: 'flat',
|
|
60
|
+
hasVersionedDocs: true, // Verified: https://docs.spring.io/spring-ai/reference/1.1/api/chatclient.html
|
|
50
61
|
cacheStrategy: 'short', // AI documentation evolves rapidly, shorter cache
|
|
51
|
-
scopes: [
|
|
52
|
-
'ai',
|
|
53
|
-
'llm',
|
|
54
|
-
'rag',
|
|
55
|
-
'embeddings',
|
|
56
|
-
'vector',
|
|
57
|
-
'chatclient',
|
|
58
|
-
'openai',
|
|
59
|
-
'azure',
|
|
60
|
-
'anthropic',
|
|
61
|
-
'ollama',
|
|
62
|
-
'chroma',
|
|
63
|
-
'pinecone',
|
|
64
|
-
'pgvector'
|
|
65
|
-
],
|
|
66
62
|
referenceSections: [
|
|
67
63
|
'chatclient',
|
|
68
|
-
'
|
|
69
|
-
'
|
|
70
|
-
'
|
|
64
|
+
'chatmodel',
|
|
65
|
+
'embeddings',
|
|
66
|
+
'vectordbs',
|
|
71
67
|
'retrieval-augmented-generation',
|
|
72
|
-
'
|
|
73
|
-
'prompt
|
|
74
|
-
'output
|
|
68
|
+
'tools',
|
|
69
|
+
'prompt',
|
|
70
|
+
'structured-output'
|
|
75
71
|
]
|
|
76
72
|
}
|
|
77
73
|
],
|
|
@@ -79,13 +75,14 @@ export const SPRING_PROJECTS = new Map([
|
|
|
79
75
|
'framework',
|
|
80
76
|
{
|
|
81
77
|
id: 'framework',
|
|
78
|
+
githubRepo: 'spring-projects/spring-framework',
|
|
79
|
+
githubTagPrefix: 'v',
|
|
80
|
+
versionInsertAfter: 'https://docs.spring.io/spring-framework/reference/',
|
|
82
81
|
displayName: 'Spring Framework',
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
apiPath: '/javadoc-api',
|
|
82
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-framework/reference',
|
|
83
|
+
referenceLayout: 'flat',
|
|
86
84
|
hasVersionedDocs: true,
|
|
87
85
|
cacheStrategy: 'long',
|
|
88
|
-
scopes: ['core', 'context', 'beans', 'aop', 'web', 'webflux', 'data-access'],
|
|
89
86
|
referenceSections: [
|
|
90
87
|
'core',
|
|
91
88
|
'web',
|
|
@@ -96,9 +93,204 @@ export const SPRING_PROJECTS = new Map([
|
|
|
96
93
|
'testing'
|
|
97
94
|
]
|
|
98
95
|
}
|
|
96
|
+
],
|
|
97
|
+
[
|
|
98
|
+
'security',
|
|
99
|
+
{
|
|
100
|
+
id: 'security',
|
|
101
|
+
githubRepo: 'spring-projects/spring-security',
|
|
102
|
+
githubTagPrefix: '',
|
|
103
|
+
versionInsertAfter: 'https://docs.spring.io/spring-security/reference/',
|
|
104
|
+
displayName: 'Spring Security',
|
|
105
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-security',
|
|
106
|
+
referenceLayout: 'directory',
|
|
107
|
+
// Directory layout: subsections only resolve to <dir>/<subsection>.html, so nested folders
|
|
108
|
+
// (oauth2/login/..., authentication/passwords/...) are not reachable; hence the top-level paths below.
|
|
109
|
+
referencePaths: {
|
|
110
|
+
'authentication': 'reference/servlet/authentication',
|
|
111
|
+
'authorization': 'reference/servlet/authorization',
|
|
112
|
+
'oauth2': 'reference/servlet/oauth2',
|
|
113
|
+
'exploits': 'reference/servlet/exploits',
|
|
114
|
+
'integrations': 'reference/servlet/integrations',
|
|
115
|
+
'testing': 'reference/servlet/test'
|
|
116
|
+
},
|
|
117
|
+
hasVersionedDocs: true, // Verified: https://docs.spring.io/spring-security/reference/6.5/index.html
|
|
118
|
+
cacheStrategy: 'long',
|
|
119
|
+
referenceSections: [
|
|
120
|
+
'servlet',
|
|
121
|
+
'reactive',
|
|
122
|
+
'features',
|
|
123
|
+
'migration',
|
|
124
|
+
'authentication',
|
|
125
|
+
'authorization',
|
|
126
|
+
'oauth2',
|
|
127
|
+
'exploits',
|
|
128
|
+
'integrations',
|
|
129
|
+
'testing'
|
|
130
|
+
]
|
|
131
|
+
}
|
|
132
|
+
],
|
|
133
|
+
[
|
|
134
|
+
'data-jpa',
|
|
135
|
+
{
|
|
136
|
+
id: 'data-jpa',
|
|
137
|
+
githubRepo: 'spring-projects/spring-data-jpa',
|
|
138
|
+
githubTagPrefix: '',
|
|
139
|
+
versionInsertAfter: 'https://docs.spring.io/spring-data/jpa/reference/',
|
|
140
|
+
displayName: 'Spring Data JPA',
|
|
141
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-data/jpa/reference',
|
|
142
|
+
referenceLayout: 'flat',
|
|
143
|
+
hasVersionedDocs: true, // Verified: https://docs.spring.io/spring-data/jpa/reference/3.5/index.html
|
|
144
|
+
cacheStrategy: 'long',
|
|
145
|
+
referenceSections: [
|
|
146
|
+
'jpa',
|
|
147
|
+
'auditing',
|
|
148
|
+
// repositories.html alone returns 404 (verified): this section only works with a subsection, e.g. 'core-concepts'
|
|
149
|
+
'repositories'
|
|
150
|
+
]
|
|
151
|
+
}
|
|
152
|
+
],
|
|
153
|
+
[
|
|
154
|
+
'batch',
|
|
155
|
+
{
|
|
156
|
+
id: 'batch',
|
|
157
|
+
githubRepo: 'spring-projects/spring-batch',
|
|
158
|
+
githubTagPrefix: 'v',
|
|
159
|
+
versionInsertAfter: 'https://docs.spring.io/spring-batch/reference/',
|
|
160
|
+
displayName: 'Spring Batch',
|
|
161
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-batch/reference',
|
|
162
|
+
referenceLayout: 'flat',
|
|
163
|
+
hasVersionedDocs: true, // Verified: https://docs.spring.io/spring-batch/reference/5.2/index.html
|
|
164
|
+
cacheStrategy: 'long',
|
|
165
|
+
referenceSections: [
|
|
166
|
+
'spring-batch-architecture',
|
|
167
|
+
'whatsnew',
|
|
168
|
+
'domain',
|
|
169
|
+
'job',
|
|
170
|
+
'step',
|
|
171
|
+
'readersAndWriters',
|
|
172
|
+
'processor',
|
|
173
|
+
'scalability',
|
|
174
|
+
'repeat',
|
|
175
|
+
'retry',
|
|
176
|
+
'testing',
|
|
177
|
+
'common-patterns'
|
|
178
|
+
]
|
|
179
|
+
}
|
|
180
|
+
],
|
|
181
|
+
[
|
|
182
|
+
'integration',
|
|
183
|
+
{
|
|
184
|
+
id: 'integration',
|
|
185
|
+
githubRepo: 'spring-projects/spring-integration',
|
|
186
|
+
githubTagPrefix: 'v',
|
|
187
|
+
versionInsertAfter: 'https://docs.spring.io/spring-integration/reference/',
|
|
188
|
+
displayName: 'Spring Integration',
|
|
189
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-integration/reference',
|
|
190
|
+
referenceLayout: 'flat',
|
|
191
|
+
hasVersionedDocs: true, // Verified: https://docs.spring.io/spring-integration/reference/6.5/index.html
|
|
192
|
+
cacheStrategy: 'long',
|
|
193
|
+
referenceSections: [
|
|
194
|
+
'overview',
|
|
195
|
+
'message',
|
|
196
|
+
'channel',
|
|
197
|
+
'endpoint',
|
|
198
|
+
'router',
|
|
199
|
+
'transformer',
|
|
200
|
+
'dsl',
|
|
201
|
+
'http',
|
|
202
|
+
'jms',
|
|
203
|
+
'amqp',
|
|
204
|
+
'kafka',
|
|
205
|
+
'testing',
|
|
206
|
+
'whats-new'
|
|
207
|
+
]
|
|
208
|
+
}
|
|
209
|
+
],
|
|
210
|
+
[
|
|
211
|
+
'kafka',
|
|
212
|
+
{
|
|
213
|
+
id: 'kafka',
|
|
214
|
+
githubRepo: 'spring-projects/spring-kafka',
|
|
215
|
+
githubTagPrefix: 'v',
|
|
216
|
+
versionInsertAfter: 'https://docs.spring.io/spring-kafka/reference/',
|
|
217
|
+
displayName: 'Spring for Apache Kafka',
|
|
218
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-kafka/reference',
|
|
219
|
+
referenceLayout: 'flat',
|
|
220
|
+
hasVersionedDocs: true, // Verified: https://docs.spring.io/spring-kafka/reference/3.3/index.html
|
|
221
|
+
cacheStrategy: 'long',
|
|
222
|
+
referenceSections: [
|
|
223
|
+
'introduction',
|
|
224
|
+
'quick-tour',
|
|
225
|
+
'kafka',
|
|
226
|
+
'retrytopic',
|
|
227
|
+
'streams',
|
|
228
|
+
'testing',
|
|
229
|
+
'whats-new'
|
|
230
|
+
]
|
|
231
|
+
}
|
|
232
|
+
],
|
|
233
|
+
[
|
|
234
|
+
'modulith',
|
|
235
|
+
{
|
|
236
|
+
id: 'modulith',
|
|
237
|
+
githubRepo: 'spring-projects/spring-modulith',
|
|
238
|
+
githubTagPrefix: '',
|
|
239
|
+
versionInsertAfter: 'https://docs.spring.io/spring-modulith/reference/',
|
|
240
|
+
displayName: 'Spring Modulith',
|
|
241
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-modulith/reference',
|
|
242
|
+
referenceLayout: 'flat',
|
|
243
|
+
hasVersionedDocs: true, // Verified: https://docs.spring.io/spring-modulith/reference/1.4/index.html
|
|
244
|
+
cacheStrategy: 'long',
|
|
245
|
+
referenceSections: [
|
|
246
|
+
'fundamentals',
|
|
247
|
+
'events',
|
|
248
|
+
'testing',
|
|
249
|
+
'verification',
|
|
250
|
+
'documentation',
|
|
251
|
+
'appendix'
|
|
252
|
+
]
|
|
253
|
+
}
|
|
254
|
+
],
|
|
255
|
+
[
|
|
256
|
+
'cloud-gateway',
|
|
257
|
+
{
|
|
258
|
+
id: 'cloud-gateway',
|
|
259
|
+
githubRepo: 'spring-cloud/spring-cloud-gateway',
|
|
260
|
+
githubTagPrefix: 'v',
|
|
261
|
+
versionInsertAfter: 'https://docs.spring.io/spring-cloud-gateway/reference/',
|
|
262
|
+
displayName: 'Spring Cloud Gateway',
|
|
263
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-cloud-gateway/reference',
|
|
264
|
+
referenceLayout: 'flat',
|
|
265
|
+
hasVersionedDocs: true, // Verified: https://docs.spring.io/spring-cloud-gateway/reference/4.3/index.html
|
|
266
|
+
cacheStrategy: 'long',
|
|
267
|
+
referenceSections: [
|
|
268
|
+
'spring-cloud-gateway-server-webflux',
|
|
269
|
+
'spring-cloud-gateway-server-webmvc',
|
|
270
|
+
'appendix'
|
|
271
|
+
]
|
|
272
|
+
}
|
|
273
|
+
],
|
|
274
|
+
[
|
|
275
|
+
'cloud-config',
|
|
276
|
+
{
|
|
277
|
+
id: 'cloud-config',
|
|
278
|
+
githubRepo: 'spring-cloud/spring-cloud-config',
|
|
279
|
+
githubTagPrefix: 'v',
|
|
280
|
+
versionInsertAfter: 'https://docs.spring.io/spring-cloud-config/reference/',
|
|
281
|
+
displayName: 'Spring Cloud Config',
|
|
282
|
+
referenceBaseUrl: 'https://docs.spring.io/spring-cloud-config/reference',
|
|
283
|
+
referenceLayout: 'flat',
|
|
284
|
+
hasVersionedDocs: true, // Verified: https://docs.spring.io/spring-cloud-config/reference/4.3/index.html
|
|
285
|
+
cacheStrategy: 'long',
|
|
286
|
+
referenceSections: [
|
|
287
|
+
'quickstart',
|
|
288
|
+
'server',
|
|
289
|
+
'client'
|
|
290
|
+
]
|
|
291
|
+
}
|
|
99
292
|
]
|
|
100
|
-
// Future projects can be added here
|
|
101
|
-
// 'security', 'data-jpa', 'cloud', 'batch', 'integration', etc.
|
|
293
|
+
// Future projects can be added here (e.g. 'cloud-*' siblings, 'data-*' modules, 'graphql', 'session').
|
|
102
294
|
]);
|
|
103
295
|
/**
|
|
104
296
|
* Spring Projects Configuration Manager
|
|
@@ -123,12 +315,6 @@ export class SpringProjectsConfig {
|
|
|
123
315
|
}
|
|
124
316
|
return project;
|
|
125
317
|
}
|
|
126
|
-
/**
|
|
127
|
-
* Check if a project is supported
|
|
128
|
-
*/
|
|
129
|
-
hasProject(projectId) {
|
|
130
|
-
return this.projects.has(projectId);
|
|
131
|
-
}
|
|
132
318
|
/**
|
|
133
319
|
* Get all supported project IDs
|
|
134
320
|
*/
|
|
@@ -142,53 +328,36 @@ export class SpringProjectsConfig {
|
|
|
142
328
|
return Array.from(this.projects.values());
|
|
143
329
|
}
|
|
144
330
|
/**
|
|
145
|
-
* Build documentation reference URL for a project
|
|
331
|
+
* Build documentation reference URL for a project (current documentation version)
|
|
146
332
|
*
|
|
147
333
|
* @param projectId - Project identifier
|
|
148
|
-
* @param section - Documentation section (e.g., "web", "chatclient")
|
|
149
|
-
* @param
|
|
150
|
-
* @
|
|
334
|
+
* @param section - Documentation section (e.g., "web", "chatclient"), already validated as a safe URL segment
|
|
335
|
+
* @param subsection - Optional page inside the section (e.g., "servlet" for boot/web)
|
|
336
|
+
* @param version - Optional documentation version ("3.4" or "3.4.2"); omitted or "current" means the current docs
|
|
337
|
+
* @returns Complete URL to the documentation page
|
|
151
338
|
*/
|
|
152
|
-
buildReferenceUrl(projectId, section, version) {
|
|
339
|
+
buildReferenceUrl(projectId, section, subsection, version) {
|
|
340
|
+
const normalizedVersion = normalizeVersion(version);
|
|
153
341
|
const project = this.getProject(projectId);
|
|
154
|
-
const
|
|
155
|
-
|
|
156
|
-
|
|
342
|
+
const base = project.referenceBaseUrl;
|
|
343
|
+
let url;
|
|
344
|
+
if (project.referenceLayout === 'directory') {
|
|
345
|
+
const dir = project.referencePaths?.[section] ?? `reference/${section}`;
|
|
346
|
+
url = `${base}/${dir}/${subsection ? `${subsection}.html` : 'index.html'}`;
|
|
157
347
|
}
|
|
158
348
|
else {
|
|
159
|
-
|
|
349
|
+
url = subsection ? `${base}/${section}/${subsection}.html` : `${base}/${section}.html`;
|
|
160
350
|
}
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
* @param version - Optional version override (defaults to latest)
|
|
167
|
-
* @returns Complete URL to API documentation
|
|
168
|
-
*/
|
|
169
|
-
buildApiUrl(projectId, version) {
|
|
170
|
-
const project = this.getProject(projectId);
|
|
171
|
-
if (!project.apiPath) {
|
|
172
|
-
throw new Error(`Project "${projectId}" does not have API documentation configured`);
|
|
351
|
+
if (!normalizedVersion)
|
|
352
|
+
return url;
|
|
353
|
+
const prefix = project.versionInsertAfter;
|
|
354
|
+
if (!project.hasVersionedDocs || !prefix) {
|
|
355
|
+
throw new Error(`Project "${projectId}" does not support versioned documentation`);
|
|
173
356
|
}
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
return `${project.baseDocUrl}/${targetVersion}${project.apiPath}/`;
|
|
177
|
-
}
|
|
178
|
-
else {
|
|
179
|
-
return `${project.baseDocUrl}${project.apiPath}/`;
|
|
357
|
+
if (!url.startsWith(prefix)) {
|
|
358
|
+
throw new Error(`Invalid configuration for project "${projectId}": versionInsertAfter is not a prefix of ${url}`);
|
|
180
359
|
}
|
|
181
|
-
|
|
182
|
-
/**
|
|
183
|
-
* Find projects by scope/keyword
|
|
184
|
-
* Useful for routing queries to appropriate projects
|
|
185
|
-
*
|
|
186
|
-
* @param scope - Search scope keyword (e.g., "ai", "boot", "security")
|
|
187
|
-
* @returns Array of matching project configurations
|
|
188
|
-
*/
|
|
189
|
-
findProjectsByScope(scope) {
|
|
190
|
-
const scopeLower = scope.toLowerCase();
|
|
191
|
-
return this.getAllProjects().filter(project => project.scopes.some(s => s.toLowerCase().includes(scopeLower)));
|
|
360
|
+
return `${prefix}${normalizedVersion}/${url.slice(prefix.length)}`;
|
|
192
361
|
}
|
|
193
362
|
/**
|
|
194
363
|
* Get cache TTL in milliseconds for a project
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"spring-projects-config.js","sourceRoot":"","sources":["../../src/services/spring-projects-config.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;
|
|
1
|
+
{"version":3,"file":"spring-projects-config.js","sourceRoot":"","sources":["../../src/services/spring-projects-config.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AA6C5C;;;;;GAKG;AACH,MAAM,CAAC,MAAM,eAAe,GAAqC,IAAI,GAAG,CAA8B;IACpG;QACE,MAAM;QACN;YACE,EAAE,EAAE,MAAM;YACV,UAAU,EAAE,6BAA6B;YACzC,eAAe,EAAE,GAAG;YACpB,kBAAkB,EAAE,qCAAqC;YACzD,WAAW,EAAE,aAAa;YAC1B,gBAAgB,EAAE,oCAAoC;YACtD,eAAe,EAAE,WAAW;YAC5B,cAAc,EAAE;gBACd,YAAY,EAAE,mBAAmB;gBACjC,cAAc,EAAE,kCAAkC;gBAClD,wBAAwB,EAAE,iCAAiC;aAC5D;YACD,gBAAgB,EAAE,IAAI;YACtB,aAAa,EAAE,MAAM,EAAE,sCAAsC;YAC7D,iBAAiB,EAAE;gBACjB,UAAU;gBACV,OAAO;gBACP,KAAK;gBACL,MAAM;gBACN,WAAW;gBACX,IAAI;gBACJ,UAAU;gBACV,YAAY;gBACZ,cAAc;gBACd,SAAS;gBACT,wBAAwB;aACzB;SACF;KACF;IACD;QACE,IAAI;QACJ;YACE,EAAE,EAAE,IAAI;YACR,UAAU,EAAE,2BAA2B;YACvC,eAAe,EAAE,GAAG;YACpB,kBAAkB,EAAE,6CAA6C;YACjE,WAAW,EAAE,WAAW;YACxB,gBAAgB,EAAE,gDAAgD;YAClE,eAAe,EAAE,MAAM;YACvB,gBAAgB,EAAE,IAAI,EAAE,+EAA+E;YACvG,aAAa,EAAE,OAAO,EAAE,kDAAkD;YAC1E,iBAAiB,EAAE;gBACjB,YAAY;gBACZ,WAAW;gBACX,YAAY;gBACZ,WAAW;gBACX,gCAAgC;gBAChC,OAAO;gBACP,QAA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AO,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC,CAAC,WAAW;YACzC;gBACE,OAAO,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC,CAAC,wBAAwB;QACnD,CAAC;IACH,CAAC;IAED;;;OAGG;IACH,eAAe,CAAC,SAAiB,EAAE,OAAe;QAChD,MAAM,OAAO,GAAG,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC;QAE3C,wDAAwD;QACxD,IAAI,CAAC,OAAO,CAAC,iBAAiB,IAAI,OAAO,CAAC,iBAAiB,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;YACzE,OAAO,IAAI,CAAC;QACd,CAAC;QAED,OAAO,OAAO,CAAC,iBAAiB,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;IACrD,CAAC;CACF;AAED;;GAEG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,IAAI,oBAAoB,EAAE,CAAC"}
|
|
@@ -1,4 +1,8 @@
|
|
|
1
|
+
import { CacheService } from './cache.js';
|
|
2
|
+
import { WikiDocument } from './boot-wiki.js';
|
|
1
3
|
import { SpringProjectsConfig } from './spring-projects-config.js';
|
|
4
|
+
import { SearchIndex } from './search-index.js';
|
|
5
|
+
import { MigrationProject } from './migration-sources.js';
|
|
2
6
|
/**
|
|
3
7
|
* Spring Documentation Service - Supports multiple Spring projects (Boot, AI, Framework, etc.)
|
|
4
8
|
* Uses ONLY real Spring documentation APIs - no mock data
|
|
@@ -10,24 +14,28 @@ export declare class SpringBootDocsServiceOptimized {
|
|
|
10
14
|
private readonly springProjectsUrl;
|
|
11
15
|
private readonly springGuideUrl;
|
|
12
16
|
private projectsConfig;
|
|
13
|
-
private turndownService;
|
|
14
17
|
private cache;
|
|
15
|
-
private
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
*/
|
|
22
|
-
private extractIntelligentContent;
|
|
18
|
+
private searchIndex;
|
|
19
|
+
constructor(projectsConfig?: SpringProjectsConfig, cache?: CacheService, searchIndex?: SearchIndex);
|
|
20
|
+
/** Feeds the full-text index with a page already fetched; never breaks the read path. */
|
|
21
|
+
private indexPage;
|
|
22
|
+
/** Re-feeds the index from the cache when a page was evicted or read before the index existed. */
|
|
23
|
+
private reindexIfMissing;
|
|
23
24
|
/**
|
|
24
25
|
* Search Spring projects with caching and retry logic - REAL API ONLY
|
|
25
26
|
*/
|
|
26
27
|
searchSpringProjects(query: string, limit?: number): Promise<any[]>;
|
|
28
|
+
/**
|
|
29
|
+
* Get the full markdown of a Spring project page (cached) - REAL API ONLY
|
|
30
|
+
*/
|
|
31
|
+
getProjectMarkdown(projectName: string): Promise<{
|
|
32
|
+
markdown: string;
|
|
33
|
+
url: string;
|
|
34
|
+
}>;
|
|
27
35
|
/**
|
|
28
36
|
* Get Spring project details - REAL API ONLY
|
|
29
37
|
*/
|
|
30
|
-
getSpringProject(projectName: string): Promise<string>;
|
|
38
|
+
getSpringProject(projectName: string, offset?: number): Promise<string>;
|
|
31
39
|
/**
|
|
32
40
|
* Get all Spring guides - REAL API ONLY
|
|
33
41
|
*/
|
|
@@ -48,27 +56,60 @@ export declare class SpringBootDocsServiceOptimized {
|
|
|
48
56
|
* @param projectId - Project identifier ('boot', 'ai', 'framework', etc.)
|
|
49
57
|
* @param section - Documentation section (e.g., 'web', 'chatclient', 'core')
|
|
50
58
|
* @param subsection - Optional subsection for deeper navigation
|
|
59
|
+
* @param offset - Character offset for paginated reads
|
|
60
|
+
* @param version - Optional documentation version ('3.4' or '3.4.2'; omitted/'current' = latest)
|
|
51
61
|
* @returns Formatted markdown documentation with source URL
|
|
52
62
|
*/
|
|
53
|
-
getSpringReference(projectId: string, section: string, subsection?: string): Promise<string>;
|
|
63
|
+
getSpringReference(projectId: string, section: string, subsection?: string, offset?: number, version?: string): Promise<string>;
|
|
64
|
+
/**
|
|
65
|
+
* Get the Spring Boot migration guide or upgrade release notes from the GitHub wiki
|
|
66
|
+
*
|
|
67
|
+
* @param version - Target version ('3.0', '3.4' or '3.4.2'; the patch is ignored)
|
|
68
|
+
* @param document - 'auto' (migration guide for x.0, release notes otherwise) or an explicit document
|
|
69
|
+
* @param section - Optional keyword; only matching headings (with sub-sections) are returned
|
|
70
|
+
* @param offset - Character offset for paginated reads
|
|
71
|
+
*/
|
|
72
|
+
getMigrationGuide(version: string, document?: 'auto' | WikiDocument, section?: string, offset?: number, project?: MigrationProject): Promise<string>;
|
|
73
|
+
private fetchBootWikiPage;
|
|
74
|
+
/** Raw markdown wiki page (Framework, Batch): a missing page is a real 404, an HTML body is never a guide. */
|
|
75
|
+
private fetchRawWikiPage;
|
|
76
|
+
private referenceTitle;
|
|
77
|
+
/**
|
|
78
|
+
* Format one page of a full markdown document with a pagination footer
|
|
79
|
+
*/
|
|
80
|
+
private formatPage;
|
|
54
81
|
/**
|
|
55
82
|
* Search Spring concepts - alias for backward compatibility
|
|
56
83
|
*/
|
|
57
|
-
searchConcepts(concept: string,
|
|
84
|
+
searchConcepts(concept: string, version?: string): Promise<string>;
|
|
85
|
+
/**
|
|
86
|
+
* Entry page of the Spring Boot reference documentation: the current docs (legacy URL, unchanged)
|
|
87
|
+
* or the page of a published version ("3.4" or "3.4.2"; the patch is ignored).
|
|
88
|
+
*/
|
|
89
|
+
private bootReferenceIndexUrl;
|
|
90
|
+
private bootVersionNotFound;
|
|
58
91
|
/**
|
|
59
92
|
* Search Spring concepts - using real documentation
|
|
93
|
+
*
|
|
94
|
+
* @param version - Optional Spring Boot documentation version ('3.4' or '3.4.2'; omitted/'current' = latest)
|
|
60
95
|
*/
|
|
61
|
-
searchSpringConcepts(concept: string,
|
|
96
|
+
searchSpringConcepts(concept: string, version?: string): Promise<string>;
|
|
62
97
|
/**
|
|
63
98
|
* Search documentation with real API - alias for backward compatibility
|
|
64
99
|
*/
|
|
65
|
-
searchDocumentation(query: string, docType?: string, limit?: number): Promise<any[]>;
|
|
100
|
+
searchDocumentation(query: string, docType?: string, limit?: number, version?: string): Promise<any[]>;
|
|
66
101
|
/**
|
|
67
102
|
* Search documentation with real API
|
|
103
|
+
*
|
|
104
|
+
* @param version - Optional Spring Boot documentation version for the Boot reference part
|
|
105
|
+
* ('3.4' or '3.4.2'; omitted/'current' = latest). Guides and projects are not versioned and ignore it.
|
|
68
106
|
*/
|
|
69
|
-
searchSpringDocs(query: string, docType?: string, limit?: number): Promise<any[]>;
|
|
107
|
+
searchSpringDocs(query: string, docType?: string, limit?: number, version?: string): Promise<any[]>;
|
|
108
|
+
private mergeContentResults;
|
|
109
|
+
private searchTitleSources;
|
|
70
110
|
private searchInReference;
|
|
71
|
-
private
|
|
111
|
+
private extractGuideMarkdown;
|
|
112
|
+
private formatGuide;
|
|
72
113
|
private fetchWithRetry;
|
|
73
114
|
}
|
|
74
115
|
//# sourceMappingURL=springboot-docs-optimized.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"springboot-docs-optimized.d.ts","sourceRoot":"","sources":["../../src/services/springboot-docs-optimized.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"springboot-docs-optimized.d.ts","sourceRoot":"","sources":["../../src/services/springboot-docs-optimized.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAM1C,OAAO,EAAE,YAAY,EAA0G,MAAM,gBAAgB,CAAC;AACtJ,OAAO,EAAE,oBAAoB,EAAwB,MAAM,6BAA6B,CAAC;AACzF,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,gBAAgB,EAAgI,MAAM,wBAAwB,CAAC;AAKxL;;;;;GAKG;AACH,qBAAa,8BAA8B;IACzC,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA4B;IACpD,OAAO,CAAC,QAAQ,CAAC,iBAAiB,CAAgC;IAClE,OAAO,CAAC,QAAQ,CAAC,cAAc,CAA8B;IAC7D,OAAO,CAAC,cAAc,CAAuB;IAC7C,OAAO,CAAC,K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