Skip to content

Commit 12849b5

Browse files
committed
refactor: rename rust fast server to fast time
Signed-off-by: lucarlig <lucarlig@protonmail.com>
1 parent cc2b51d commit 12849b5

51 files changed

Lines changed: 229 additions & 932 deletions

Some content is hidden

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

.github/workflows/sql-sanitizer.yml

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
- "mcpgateway/**"
99
- "plugins/**"
1010
- "crates/sql-sanitizer/**"
11-
- "mcp-servers/rust/fast-test-server/**"
11+
- "mcp-servers/rust/fast-time-server/**"
1212
- "pyproject.toml"
1313
- "uv.lock"
1414
- ".github/workflows/sql-sanitizer.yml"
@@ -160,44 +160,44 @@ jobs:
160160
-H "Content-Type: application/json" | yq
161161
162162
163-
- name: Build fast-test-server
164-
working-directory: mcp-servers/rust/fast-test-server
163+
- name: Build fast-time-server
164+
working-directory: mcp-servers/rust/fast-time-server
165165
run: |
166166
cargo build
167167
168-
- name: Start fast-test-server
168+
- name: Start fast-time-server
169169
run: |
170-
pkill -9 -f "fast-test-server" 2>/dev/null || true
170+
pkill -9 -f "fast-time-server" 2>/dev/null || true
171171
sleep 1
172172
173-
nohup mcp-servers/rust/fast-test-server/target/debug/fast-test-server \
174-
> fast-test-server.log 2>&1 &
175-
echo $! > fast-test-server.pid
173+
nohup mcp-servers/rust/fast-time-server/target/debug/fast-time-server \
174+
> fast-time-server.log 2>&1 &
175+
echo $! > fast-time-server.pid
176176
177-
echo "Waiting for fast-test-server..."
177+
echo "Waiting for fast-time-server..."
178178
for i in {1..30}; do
179179
if curl -s http://localhost:9080/health >/dev/null 2>&1; then
180-
echo "fast-test-server is up!"
180+
echo "fast-time-server is up!"
181181
break
182182
fi
183-
echo "Waiting for fast-test-server... (attempt $i)"
183+
echo "Waiting for fast-time-server... (attempt $i)"
184184
sleep 2
185185
done
186186
187187
if ! curl -s http://localhost:9080/health >/dev/null 2>&1; then
188-
echo "ERROR: fast-test-server failed to start"
189-
cat fast-test-server.log
188+
echo "ERROR: fast-time-server failed to start"
189+
cat fast-time-server.log
190190
exit 1
191191
fi
192-
echo "fast-test-server PID: $(cat fast-test-server.pid)"
192+
echo "fast-time-server PID: $(cat fast-time-server.pid)"
193193
194194
- name: Register gateway and create virtual server
195195
run: |
196196
TOKEN="${{ steps.generate_jwt.outputs.token }}"
197197
198198
if ! curl -s http://localhost:9080/health >/dev/null 2>&1; then
199-
echo "ERROR: fast-test-server is not running"
200-
cat fast-test-server.log
199+
echo "ERROR: fast-time-server is not running"
200+
cat fast-time-server.log
201201
exit 1
202202
fi
203203
@@ -316,7 +316,7 @@ jobs:
316316
with:
317317
name: sql-sanitizer-test-logs
318318
path: |
319-
fast-test-server.log
319+
fast-time-server.log
320320
sql-sanitizer_output.json
321321
sql-sanitizer_test.log
322322
gateway.log

.github/workflows/wrapper.yml

Lines changed: 7 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
types: [opened, synchronize, reopened]
77
paths:
88
- "crates/wrapper/**"
9-
- "mcp-servers/go/fast-time-server/**"
9+
- "mcp-servers/rust/fast-time-server/**"
1010
- "Cargo.toml"
1111
- "Cargo.lock"
1212
- "rust-toolchain.toml"
@@ -123,26 +123,19 @@ jobs:
123123
-H "Authorization: Bearer ${{ steps.generate_jwt.outputs.token }}" \
124124
-H "Content-Type: application/json"
125125
126-
- name: Setup Go
127-
uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0
128-
with:
129-
go-version: "1.23"
130-
cache-dependency-path: mcp-servers/go/fast-time-server/go.sum
131-
cache: true
132-
133126
- name: Build fast-time-server
134-
working-directory: mcp-servers/go/fast-time-server
127+
working-directory: mcp-servers/rust/fast-time-server
135128
run: |
136-
go build -o fast-time-server .
137-
chmod +x fast-time-server
129+
cargo build --release
130+
chmod +x target/release/fast-time-server
138131
139132
- name: Start fast-time-server
140133
run: |
141134
pkill -9 -f "fast-time-server" 2>/dev/null || true
142135
sleep 1
143136
144-
nohup mcp-servers/go/fast-time-server/fast-time-server \
145-
-transport=dual -listen=0.0.0.0 -port=8080 -log-level=info \
137+
BIND_ADDRESS=0.0.0.0:8080 \
138+
nohup mcp-servers/rust/fast-time-server/target/release/fast-time-server \
146139
> fast-time-server.log 2>&1 &
147140
echo $! > fast-time-server.pid
148141
@@ -180,7 +173,7 @@ jobs:
180173
-H "Content-Type: application/json" \
181174
-d '{
182175
"name": "fast_time",
183-
"url": "http://localhost:8080/http",
176+
"url": "http://localhost:8080/mcp",
184177
"transport": "STREAMABLEHTTP"
185178
}')
186179
echo "Gateway response: $GATEWAY_RESPONSE"

Makefile

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1514,7 +1514,7 @@ langfuse-up: ## Start Langfuse LLM observability s
15141514
@# Bring up the same lightweight MCP/A2A test targets used by the live smoke
15151515
@# suites so Langfuse runs can generate real end-to-end tool traffic without
15161516
@# depending on stale registrations from the testing profile.
1517-
$(LANGFUSE_COMPOSE) up -d fast_test_server register_fast_test a2a_echo_agent register_a2a_echo
1517+
$(LANGFUSE_COMPOSE) up -d fast_time_server register_fast_time a2a_echo_agent register_a2a_echo
15181518
$(VERIFY_LANGFUSE_GATEWAY_EXPORT)
15191519
@echo "⏳ Waiting for Langfuse to be ready..."
15201520
@for i in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15; do \
@@ -1630,8 +1630,8 @@ langfuse-monitoring-down: ## Stop Langfuse + monitoring stack
16301630
@echo "✅ Langfuse + monitoring stack stopped."
16311631

16321632
# =============================================================================
1633-
# help: 🧪 TESTING STACK (Locust + A2A echo + fast_test_server)
1634-
# help: testing-up - Start testing stack (Locust + A2A echo + fast_test_server)
1633+
# help: 🧪 TESTING STACK (Locust + A2A echo + fast_time_server)
1634+
# help: testing-up - Start testing stack (Locust + A2A echo + fast_time_server)
16351635
# help: testing-down - Stop testing stack
16361636
# help: testing-status - Show status of testing services
16371637
# help: testing-logs - Show testing stack logs
@@ -1643,8 +1643,8 @@ HOST_UID ?= $(shell id -u 2>/dev/null || echo 1000)
16431643
HOST_GID ?= $(shell id -g 2>/dev/null || echo 1000)
16441644

16451645
.PHONY: testing-up
1646-
testing-up: ## Start testing stack (Locust + A2A echo + fast_test_server)
1647-
@echo "🧪 Starting testing stack (fast_test_server)..."
1646+
testing-up: ## Start testing stack (Locust + A2A echo + fast_time_server)
1647+
@echo "🧪 Starting testing stack (fast_time_server)..."
16481648
@echo " 🦗 Locust workers: $(TESTING_LOCUST_WORKERS) (override: TESTING_LOCUST_WORKERS=4 make testing-up)"
16491649
@# Fail early if port 8080 is already bound (nginx needs it)
16501650
@if lsof -Pi :8080 -sTCP:LISTEN >/dev/null 2>&1 || ss -tlnp 2>/dev/null | grep -q ':8080'; then \
@@ -1664,15 +1664,15 @@ testing-up: ## Start testing stack (Locust + A2A
16641664
@echo "──────────────────────────────────────────────────────────────────────────"
16651665
@echo "Gateway (nginx) http://localhost:8080 API proxy"
16661666
@echo "Locust Web UI http://localhost:8089 Load testing (master+workers)"
1667-
@echo "Fast Test Server http://localhost:8880 MCP benchmark target"
1667+
@echo "Fast Time Server http://localhost:8880 MCP benchmark target"
16681668
@echo "A2A Echo Agent http://localhost:9100 A2A protocol target"
16691669
@echo "MCP Inspector http://localhost:6274 Interactive MCP client"
16701670
@echo "Keycloak http://localhost:8180 SSO / OAuth 2.1 provider (realm: mcp-gateway)"
16711671
@echo ""
16721672
@echo " 🔒 For DAST security scanning, also start ZAP: make testing-zap-up"
16731673
@echo ""
16741674
@echo " 📝 Auto-registered:"
1675-
@echo " • MCP gateway: fast_test (from fast_test_server)"
1675+
@echo " • MCP gateway: fast_time (from fast_time_server)"
16761676
@echo " • A2A agent: a2a-echo-agent"
16771677
@echo ""
16781678
@echo " Next:"
@@ -1720,7 +1720,7 @@ testing-down: ## Stop testing stack
17201720
.PHONY: testing-status
17211721
testing-status: ## Show status of testing services
17221722
@echo "🧪 Testing stack status:"
1723-
@$(COMPOSE_CMD_MONITOR) ps | grep -E "(fast_test|a2a_echo_agent|locust|mcp_inspector)" || \
1723+
@$(COMPOSE_CMD_MONITOR) ps | grep -E "(fast_time|a2a_echo_agent|locust|mcp_inspector)" || \
17241724
echo " No testing services running. Start with 'make testing-up'"
17251725
@WORKERS=$$($(COMPOSE_CMD_MONITOR) ps | grep -c "locust_worker" || true); \
17261726
echo " 🦗 Locust workers: $$WORKERS"
@@ -3081,7 +3081,7 @@ ocp-uninstall: ## Uninstall the ContextForge Helm
30813081
# help: jmeter-ui - Launch JMeter GUI for interactive test editing
30823082
# help: jmeter-rest-baseline - Run REST API baseline test (1,000 RPS, 10min)
30833083
# help: jmeter-mcp-baseline - Run MCP JSON-RPC baseline test (1,000 RPS, 15min)
3084-
# help: jmeter-mcp-servers-baseline - Run MCP test servers baseline (fast_time, fast_test)
3084+
# help: jmeter-mcp-servers-baseline - Run MCP test servers baseline (fast_time, fast_time)
30853085
# help: jmeter-load - Run load test (4,000 RPS, 30min)
30863086
# help: jmeter-stress - Run stress test (ramp to 10,000 RPS)
30873087
# help: jmeter-spike - Run spike test (1K→10K→1K recovery)
@@ -3212,10 +3212,10 @@ jmeter-mcp-baseline: jmeter-check ## Run MCP JSON-RPC baseline test (1,
32123212
-e -o $(JMETER_RESULTS_DIR)/mcp_baseline_$$TIMESTAMP/
32133213
@echo "📄 Report: $(JMETER_RESULTS_DIR)/mcp_baseline_*/index.html"
32143214

3215-
jmeter-mcp-servers-baseline: jmeter-check ## Run MCP test servers baseline (fast_time, fast_test)
3215+
jmeter-mcp-servers-baseline: jmeter-check ## Run MCP test servers baseline (fast_time, fast_time)
32163216
@echo "📊 Running MCP test servers baseline..."
32173217
@echo " Fast Time Server: $(JMETER_FAST_TIME_URL)"
3218-
@echo " Fast Test Server: $(JMETER_FAST_TEST_URL)"
3218+
@echo " Fast Time Server: $(JMETER_FAST_TEST_URL)"
32193219
@echo " Target: 2,000 RPS per server for 10 minutes"
32203220
@mkdir -p $(JMETER_RESULTS_DIR)
32213221
@TIMESTAMP=$$(date +%Y%m%d_%H%M%S); \

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -477,7 +477,7 @@ kubectl exec deployment/mcp-gateway-mcp-context-forge -- \
477477
```
478478

479479
> SSRF note: Helm defaults to strict SSRF settings (`SSRF_ALLOW_PRIVATE_NETWORKS=false`).
480-
> If you register in-cluster tool URLs (for example fast-time or fast-test services),
480+
> If you register in-cluster tool URLs (for example fast-time or fast-time services),
481481
> allow only your cluster CIDRs via `mcpContextForge.config.SSRF_ALLOWED_NETWORKS` or,
482482
> for local-only benchmark setups, temporarily set `SSRF_ALLOW_PRIVATE_NETWORKS=true`.
483483
> See `docs/docs/manage/configuration.md#ssrf-protection` and `docs/docs/deployment/helm.md`.

charts/mcp-stack/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ When you enable testing registration jobs (`testing.fastTime.register.enabled` o
3939
in-cluster service URLs:
4040

4141
- `fast-time`: `http://<release>-mcp-fast-time-server:80/http`
42-
- `fast-test`: `http://<release>-fast-test-server:8880/mcp`
42+
- `fast-time`: `http://<release>-fast-time-server:8880/mcp`
4343

4444
Those destinations are private cluster addresses and will be blocked under strict SSRF defaults.
4545

@@ -1434,7 +1434,7 @@ When `RATELIMITER_REDIS_URL` is not set during start time, the gateway automatic
14341434
| testing.fastTime.register.virtualServerName | string | `"Fast Time Server"` | |
14351435
| testing.fastTime.register.virtualServerDescription | string | `"Virtual server exposing Fast Time MCP tools/resources/prompts"` | |
14361436
| testing.fastTestServer.enabled | bool | `true` | |
1437-
| testing.fastTestServer.image.repository | string | `"mcpgateway/fast-test-server"` | |
1437+
| testing.fastTestServer.image.repository | string | `"mcpgateway/fast-time-server"` | |
14381438
| testing.fastTestServer.image.tag | string | `"latest"` | |
14391439
| testing.fastTestServer.image.pullPolicy | string | `"IfNotPresent"` | |
14401440
| testing.fastTestServer.service.type | string | `"ClusterIP"` | |
@@ -1462,7 +1462,7 @@ When `RATELIMITER_REDIS_URL` is not set during start time, the gateway automatic
14621462
| testing.fastTestServer.probes.liveness.successThreshold | int | `1` | |
14631463
| testing.fastTestServer.probes.liveness.failureThreshold | int | `3` | |
14641464
| testing.fastTest.register.enabled | bool | `true` | |
1465-
| testing.fastTest.register.gatewayName | string | `"fast_test"` | |
1465+
| testing.fastTest.register.gatewayName | string | `"fast_time"` | |
14661466
| testing.fastTest.register.gatewayPath | string | `"/mcp"` | |
14671467
| testing.fastTest.register.transport | string | `"STREAMABLEHTTP"` | |
14681468
| testing.a2aEchoAgent.enabled | bool | `true` | |

charts/mcp-stack/templates/registration-jobs.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ spec:
151151
apiVersion: batch/v1
152152
kind: Job
153153
metadata:
154-
name: {{ $fullName }}-register-fast-test
154+
name: {{ $fullName }}-register-fast-time
155155
labels:
156156
{{- include "mcp-stack.labels" . | nindent 4 }}
157157
app.kubernetes.io/component: registration
@@ -174,7 +174,7 @@ spec:
174174
{{- end }}
175175
automountServiceAccountToken: {{ .Values.serviceAccount.automountServiceAccountToken }}
176176
containers:
177-
- name: register-fast-test
177+
- name: register-fast-time
178178
image: {{ $registrationImage | quote }}
179179
imagePullPolicy: {{ .Values.testing.registration.image.pullPolicy }}
180180
command: ["/bin/sh", "-c"]
@@ -188,7 +188,7 @@ spec:
188188
189189
targets = [
190190
("gateway", "http://{{ $gatewayHost }}:{{ $gatewayPort }}/health", 90),
191-
("fast_test_server", "http://{{ $fullName }}-fast-test-server:{{ .Values.testing.fastTestServer.service.port }}/health", 60),
191+
("fast_time_server", "http://{{ $fullName }}-fast-time-server:{{ .Values.testing.fastTestServer.service.port }}/health", 60),
192192
]
193193
194194
for name, url, tries in targets:
@@ -214,7 +214,7 @@ spec:
214214
token = os.environ["TOKEN"]
215215
base = "http://{{ $gatewayHost }}:{{ $gatewayPort }}"
216216
gateway_name = "{{ .Values.testing.fastTest.register.gatewayName }}"
217-
gateway_url = "http://{{ $fullName }}-fast-test-server:{{ .Values.testing.fastTestServer.service.port }}{{ .Values.testing.fastTest.register.gatewayPath }}"
217+
gateway_url = "http://{{ $fullName }}-fast-time-server:{{ .Values.testing.fastTestServer.service.port }}{{ .Values.testing.fastTest.register.gatewayPath }}"
218218
transport = "{{ .Values.testing.fastTest.register.transport }}"
219219
220220
def api_request(method: str, path: str, payload=None):
@@ -236,7 +236,7 @@ spec:
236236
pass
237237
238238
api_request("POST", "/gateways", {"name": gateway_name, "url": gateway_url, "transport": transport})
239-
print("fast_test registration complete")
239+
print("fast_time registration complete")
240240
PY
241241
242242
exit 0

charts/mcp-stack/templates/testing-stack.yaml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,19 +18,19 @@
1818
apiVersion: apps/v1
1919
kind: Deployment
2020
metadata:
21-
name: {{ $fullName }}-fast-test-server
21+
name: {{ $fullName }}-fast-time-server
2222
labels:
2323
{{- include "mcp-stack.labels" . | nindent 4 }}
24-
app: {{ $fullName }}-fast-test-server
24+
app: {{ $fullName }}-fast-time-server
2525
spec:
2626
replicas: 1
2727
selector:
2828
matchLabels:
29-
app: {{ $fullName }}-fast-test-server
29+
app: {{ $fullName }}-fast-time-server
3030
template:
3131
metadata:
3232
labels:
33-
app: {{ $fullName }}-fast-test-server
33+
app: {{ $fullName }}-fast-time-server
3434
spec:
3535
{{- if .Values.global.imagePullSecrets }}
3636
imagePullSecrets:
@@ -43,7 +43,7 @@ spec:
4343
{{- end }}
4444
automountServiceAccountToken: {{ .Values.serviceAccount.automountServiceAccountToken }}
4545
containers:
46-
- name: fast-test-server
46+
- name: fast-time-server
4747
image: "{{ .Values.testing.fastTestServer.image.repository }}:{{ .Values.testing.fastTestServer.image.tag }}"
4848
imagePullPolicy: {{ .Values.testing.fastTestServer.image.pullPolicy }}
4949
ports:
@@ -68,14 +68,14 @@ spec:
6868
apiVersion: v1
6969
kind: Service
7070
metadata:
71-
name: {{ $fullName }}-fast-test-server
71+
name: {{ $fullName }}-fast-time-server
7272
labels:
7373
{{- include "mcp-stack.labels" . | nindent 4 }}
74-
app: {{ $fullName }}-fast-test-server
74+
app: {{ $fullName }}-fast-time-server
7575
spec:
7676
type: {{ .Values.testing.fastTestServer.service.type }}
7777
selector:
78-
app: {{ $fullName }}-fast-test-server
78+
app: {{ $fullName }}-fast-time-server
7979
ports:
8080
- name: http
8181
port: {{ .Values.testing.fastTestServer.service.port }}

charts/mcp-stack/values-minikube.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ redisCommander:
112112
minio:
113113
enabled: false
114114

115-
# Enable testing profile (fast-test-server + auto-registration)
115+
# Enable testing profile (fast-time-server + auto-registration)
116116
testing:
117117
enabled: true
118118
registration:

charts/mcp-stack/values.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -435,7 +435,7 @@ mcpContextForge:
435435
# Cloud metadata endpoints (169.254.169.254, etc.) are ALWAYS blocked by default.
436436
# Helm testing registration uses private in-cluster Service DNS names by default:
437437
# fast-time: http://<release>-mcp-fast-time-server:80/http
438-
# fast-test: http://<release>-fast-test-server:8880/mcp
438+
# fast-time: http://<release>-fast-time-server:8880/mcp
439439
# With strict defaults, those targets are rejected with HTTP 422 during gateway registration.
440440
SSRF_PROTECTION_ENABLED: "true" # master switch for SSRF protection
441441
SSRF_ALLOW_LOCALHOST: "false" # block localhost/loopback by default
@@ -1839,7 +1839,7 @@ monitoring:
18391839
memory: 256Mi
18401840

18411841
########################################################################
1842-
# TESTING PROFILE - fast-test server, A2A echo agent, locust, auto-register
1842+
# TESTING PROFILE - fast-time server, A2A echo agent, locust, auto-register
18431843
########################################################################
18441844
testing:
18451845
enabled: false
@@ -1874,7 +1874,7 @@ testing:
18741874
fastTestServer:
18751875
enabled: true
18761876
image:
1877-
repository: mcpgateway/fast-test-server
1877+
repository: mcpgateway/fast-time-server
18781878
tag: latest
18791879
pullPolicy: IfNotPresent
18801880
service:
@@ -1913,9 +1913,9 @@ testing:
19131913
fastTest:
19141914
register:
19151915
enabled: true
1916-
# Uses in-cluster Service URL: http://<release>-fast-test-server:8880/mcp
1916+
# Uses in-cluster Service URL: http://<release>-fast-time-server:8880/mcp
19171917
# Requires SSRF_ALLOW_PRIVATE_NETWORKS=true OR SSRF_ALLOWED_NETWORKS to include cluster CIDR.
1918-
gatewayName: fast_test
1918+
gatewayName: fast_time
19191919
gatewayPath: /mcp
19201920
transport: STREAMABLEHTTP
19211921

crates/mcp_runtime/FOLLOWUPS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -705,7 +705,7 @@ Observed behavior:
705705
produced `20` failures in `1,842,181` requests on the richer `fast_time`
706706
server profile.
707707
- After isolating the upstreams:
708-
- the simpler `fast_test` server reduced the same class of load to `3`
708+
- the simpler `fast_time` server reduced the same class of load to `3`
709709
failures in `1,042,973` requests, all plain `502`s
710710
- a controlled `fast_time` run with
711711
`MCP_RUST_USE_RMCP_UPSTREAM_CLIENT=false` removed the `HTTP 0` / ~30s tail

0 commit comments

Comments
 (0)