Intelligence, Advanced Charting & Trading Platform
fix(ws): align Cloudflare Durable Object deployment template with React client protocol
davoodmehraban89 committed
Oct 12, 2026 at 00:27 UTC
c8f3554c2e6bbb2a11363aebd77e5aeb218dd6a7
1 file changed
+17
-10
deploy/chartnova/wrangler.realtime.example.toml
+17
-10
@@ -1,18 +1,25 @@
1
-# Architecture example only. NEVER deploy without explicit approval and security review.
2
-name = "chartnova-realtime-gateway"
3
-main = "realtime-gateway.mjs"
1
+# Review template only — deploying a Durable Object may have billing implications.
2
+# Do not deploy without explicit authorization, secrets, provider rights and network smoke tests.
3
+name = "chartnova-market-stream"
4
+main = "market-stream-worker.mjs"
5
compatibility_date = "2026-10-12"
6
workers_dev = false
7
8
+[vars]
9
+# Actual allowed symbols must be reviewed before the streaming service is enabled.
10
+STREAM_SYMBOL_ALLOWLIST = "EUR_USD_ECB,EUR_GBP_ECB,EUR_CHF_ECB"
11
+STREAM_ALLOWED_ORIGINS = "https://chartnova.ir,https://app.chartnova.ir"
12
+
13
[[durable_objects.bindings]]
8
-name = "CHARTNOVA_REALTIME_HUB"
9
-class_name = "ChartNovaRealtimeHub"
14
+name = "STREAM_ROOMS"
15
+class_name = "SymbolStreamRoom"
16
17
[[migrations]]
18
tag = "v1"
13
-new_sqlite_classes = ["ChartNovaRealtimeHub"]
19
+new_sqlite_classes = ["SymbolStreamRoom"]
20
15
-# Set CHARTNOVA_REALTIME_PUBLISH_TOKEN only with:
16
-# wrangler secret put CHARTNOVA_REALTIME_PUBLISH_TOKEN --config deploy/chartnova/wrangler.realtime.example.toml
17
-# This does not create data licenses, market providers or a live stream.
18
-# Add explicit custom route, staging domain, quota limits and monitoring before deploy.
21
+# Activate private publisher only by Cloudflare secret manager:
22
+# wrangler secret put STREAM_INGEST_TOKEN --config deploy/chartnova/wrangler.realtime.example.toml
23
+# Configure a custom WSS route /stream and private internal publisher route.
24
+# The /internal/market-update entry must be further restricted by Cloudflare Access/WAF/IP policy.
25
+# Keep legacy Worker velyqor-preview, KV, and all existing secrets untouched.