Commit graph

105 commits

Author SHA1 Message Date
RainbowBird
4ccfc4ab4b
chore: type 2026-03-15 19:25:31 +08:00
RainbowBird
db88569794 feat(server): add Redis pub/sub for cross-instance WS broadcast
When multiple server instances are deployed, new messages pushed via
WebSocket on one instance are now published to a Redis channel so that
other instances can deliver them to their locally connected clients.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-15 01:21:41 +08:00
RainbowBird
a25983977e
feat(server): integrate WS chat endpoint into Hono app
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-15 00:27:33 +08:00
RainbowBird
2650335e94
feat(server): add WS chat route with eventa RPC handlers and multi-device push
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-15 00:27:33 +08:00
RainbowBird
ac51b088d5
feat(server): rewrite chat routes as REST CRUD + member management
Replace POST /sync with full REST endpoints: POST/GET/PATCH/DELETE for
chats, POST/DELETE for members. All routes use authGuard and valibot
validation.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-15 00:27:32 +08:00
RainbowBird
75903ee424
feat(server): rewrite chat validation schemas for REST endpoints
Replace monolithic ChatSyncSchema with CreateChatSchema, UpdateChatSchema,
and AddMemberSchema using valibot v1 pipe() syntax.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-15 00:27:32 +08:00
RainbowBird
ce39a003b7
feat(server): rewrite chat service with chat mgmt + message sync split
Add WS metrics (wsConnectionsActive, wsMessagesSent, wsMessagesReceived)
to otel EngagementMetrics. Replace monolithic syncChat with REST-oriented
chat management methods and WS-oriented pushMessages/pullMessages with
seq-based ordering. Export pure helpers (clampLimit, resolveSenderId) for
unit testing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-15 00:27:32 +08:00
RainbowBird
697d50a80a
feat(server): add eventa Hono WebSocket adapter
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-15 00:27:32 +08:00
RainbowBird
d726dcd761
feat(server): add seq column and make senderId nullable on messages table
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-15 00:27:31 +08:00
RainbowBird
d7e38a809e
refactor(server): extract billing logic into services/billing.ts
Move UsageInfo, extractUsageFromBody, and calculateFluxFromUsage from
v1completions.ts into a dedicated billing service with comprehensive
unit tests (22 cases) covering token calculation, ceiling, minimums,
fallbacks, and edge cases.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-14 04:13:02 +08:00
RainbowBird
fa78684cae
feat(otel): more metrics 2026-03-14 04:02:37 +08:00
RainbowBird
4b00b9dd48
chore(stage-*): login component icon alignment 2026-03-14 03:40:18 +08:00
RainbowBird
b927ca1657
refactor(stage-ui): unify official provider to plug-able, add auth lifecycle hooks 2026-03-13 23:55:02 +08:00
RainbowBird
a8d28e6829
chore(server): update grafana dashboard 2026-03-13 23:55:02 +08:00
RainbowBird
3553b9cabd
feat(server): official provider router (#1117) 2026-03-13 23:55:02 +08:00
RainbowBird
88aae17d65
fix(server): collect metrics correctly 2026-03-13 23:55:01 +08:00
RainbowBird
262879a3b6
refactor(server): organize order 2026-03-13 23:55:01 +08:00
RainbowBird
517d62cbf4
feat(server): add OpenTelemetry observability stack (#1154)
Co-authored-by: Claude <noreply@anthropic.com>
2026-03-13 23:55:01 +08:00
RainbowBird
8f58476c02
refactor(server): rename configkv get or throw 2026-03-13 23:55:01 +08:00
RainbowBird
db4a13bb42
chore(server): stripe type 2026-03-13 23:55:01 +08:00
RainbowBird
9ef462c7a8
feat(server): enhance config guard with custom error messages and add FLUX_PACKAGES handling 2026-03-13 23:55:00 +08:00
RainbowBird
392bcc0539
fix(server): resolve config kv properly 2026-03-13 23:55:00 +08:00
RainbowBird
c484e0862c
feat(server): stripe service, more stripe table 2026-03-13 23:55:00 +08:00
RainbowBird
f00f0ba91f
feat(server): redis, config kv integration 2026-03-13 23:55:00 +08:00
RainbowBird
c79739785d
fix(server): customer id 2026-03-13 23:54:59 +08:00
RainbowBird
1e62341f8e
chore(server): resolve db type 2026-03-13 23:54:59 +08:00
RainbowBird
95b54f4a60
refactor(server): do not require backend llm api key and base url 2026-03-13 23:54:59 +08:00
RainbowBird
b21ac17b9e
refactor(server): add more error utils 2026-03-13 23:54:59 +08:00
RainbowBird
44ef5fca92
feat(server): stripe integration and credits system (#1024) 2026-03-13 23:54:58 +08:00
Neko Ayaka
da62f1c16b
release: v0.9.0-alpha.14 2026-03-12 01:48:21 +08:00
Neko Ayaka
53f79713d7
release: v0.9.0-alpha.13 2026-03-11 19:36:13 +08:00
Neko Ayaka
96d3149909
release: v0.9.0-alpha.12 2026-03-11 04:35:37 +08:00
Neko Ayaka
208ff1d8a5
release: v0.9.0-alpha.11 2026-03-11 02:03:28 +08:00
LemonNeko
38d41cca84
release: v0.9.0-alpha.10 2026-03-10 22:32:07 +08:00
Neko Ayaka
03a38f9e0c
release: v0.9.0-alpha.9 2026-03-10 19:33:11 +08:00
LemonNeko
7daaeece46
release: v0.9.0-alpha.8 2026-03-10 18:42:35 +08:00
Neko Ayaka
a5cca0225b
release: v0.9.0-alpha.7 2026-03-10 17:47:25 +08:00
Neko Ayaka
03188f9855
release: v0.9.0-alpha.6 2026-03-10 01:29:38 +08:00
RainbowBird
0732827a9e
refactor(server): replace postgres-js to pg to support auto-instrumentation 2026-03-09 18:47:34 +08:00
LemonNeko
583b54bfee
release: v0.9.0-alpha.5 2026-03-08 18:35:38 +08:00
LemonNeko
7b981d08de
release: v0.9.0-alpha.4 2026-03-08 17:37:59 +08:00
LemonNeko
9c514b17f0
release: v0.9.0-alpha.3 2026-03-08 17:20:32 +08:00
RainbowBird
47d97320ef
fix(server): collect metrics correctly 2026-03-06 04:14:04 +08:00
RainbowBird
284b100030
feat(server): add OpenTelemetry observability stack 2026-03-06 02:58:44 +08:00
Neko Ayaka
b24ba8cc26
release: v0.9.0-alpha.2 2026-03-05 15:52:21 +08:00
Neko Ayaka
41940242e0
release: v0.9.0-alpha.1 2026-03-05 03:45:19 +08:00
LemonNeko
a9900b3985
chore: release v0.8.5-beta.4 2026-03-04 21:41:04 +08:00
RainbowBird
6c7aa855cf
feat(server): log api error 2026-03-04 19:06:24 +08:00
RainbowBird
f38871b2d8
refactor(server): squash drizzle migration files 2026-03-04 18:41:21 +08:00
RainbowBird
a2356608fe
refactor(server): api server url env 2026-03-03 17:36:40 +08:00