Commit 0de414d
committed
feat (user counert): add active_sessions table for counter
- Add active_sessions schema with session tracking
- Add index on last_activity for performance optimization
- Prepare database structure for live online user counter
Table structure:
- session_id (text, PK): unique session identifier
- last_activity (timestamp): tracks user's last activity time
Migration file: drizzle/0002_clean_martin_li.sql
Related to: (SP: 3) [Frontend + Backend] Track all active users and display live online counter on Home page1 parent d7c63a3 commit 0de414d
5 files changed
Lines changed: 2736 additions & 1 deletion
File tree
- frontend
- db/schema
- drizzle
- meta
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
| 9 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
0 commit comments