managarten/apps-archived/uload/docs/REDIS-SETUP.md
Till-JS ee42b6cc76 feat: major update with network graphs, themes, todo extensions, and more
## New Features

### Network Graph Visualization (Contacts, Calendar, Todo)
- D3.js force simulation for physics-based layout
- Zoom & pan with mouse/touchpad
- Keyboard shortcuts: +/- zoom, 0 reset, Esc deselect, / search, F focus
- Filtering by tags, company/location/project, connection strength
- Shared components in @manacore/shared-ui

### Central Tags API (mana-core-auth)
- CRUD endpoints for tags
- Schema: tags table with userId, name, color, app
- Shared tag components in @manacore/shared-ui

### Custom Themes System
- Theme editor with live preview and color picker
- Community theme gallery
- Theme sharing (public, unlisted, private)
- Backend API in mana-core-auth

### Todo App Extensions
- Glass-pill design for task input and items
- Settings page with 20+ preferences
- Task edit modal with inline editing
- Statistics page with visualizations
- PWA support with offline capabilities
- Multiple kanban boards

### Contacts App Features
- Duplicate detection
- Photo upload
- Batch operations
- Enhanced favorites page with multiple view modes
- Alphabet view improvements
- Search modal

### Help System
- @manacore/shared-help-content
- @manacore/shared-help-ui
- @manacore/shared-help-types

### Other Features
- Themes page for all apps
- Referral system frontend
- CommandBar (global search)
- Skeleton loaders
- Settings page improvements

## Bug Fixes
- Network graph simulation initialization
- Database schema TEXT for user_id columns (Better Auth compatibility)
- Various styling fixes

## Documentation
- Daily report for 2025-12-10
- CI/CD deployment guide

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-10 02:37:46 +01:00

113 lines
2.2 KiB
Markdown

# Redis Cache Setup - Erfolgreich konfiguriert! 🎉
## Was wurde gemacht:
### 1. Redis lokal installiert
- Redis via Homebrew installiert: `brew install redis`
- Redis-Service gestartet: `brew services start redis`
- Läuft jetzt permanent im Hintergrund
### 2. Umgebungsvariablen konfiguriert
**Lokal (.env.development):**
```env
REDIS_HOST=localhost
REDIS_PORT=6379
REDIS_PASSWORD=
```
**Produktion (.env):**
```env
# Füge deine Coolify Redis-Daten hier ein:
REDIS_HOST=your-redis-host
REDIS_PORT=6379
REDIS_USERNAME=default
REDIS_PASSWORD=your-redis-password
```
### 3. Robuster Fallback-Mechanismus
- App funktioniert auch OHNE Redis
- Automatische Erkennung ob Redis verfügbar ist
- Graceful degradation wenn Redis offline ist
## So prüfst du ob Redis funktioniert:
### 1. Status-Endpoint
```bash
# Lokal
curl http://localhost:5173/api/redis-status
# Produktion
curl https://ulo.ad/api/redis-status
```
### 2. Console Logs
Beim App-Start siehst du:
- ✅ Redis: Connected successfully (wenn verbunden)
- ⚠️ Redis: Disabled (wenn nicht konfiguriert)
### 3. Performance Test
1. Besuche einen Link zum ersten Mal → "Cache MISS"
2. Besuche denselben Link nochmal → "Cache HIT!" (viel schneller!)
### 4. Redis CLI
```bash
# Zeige alle gecachten Links
redis-cli keys "redirect:*"
# Zeige Cache-Inhalt
redis-cli get "redirect:dein-link-code"
```
## Befehle für Redis-Management:
```bash
# Redis starten
brew services start redis
# Redis stoppen
brew services stop redis
# Redis Status
brew services list | grep redis
# Redis Monitor (live traffic)
redis-cli monitor
# Cache leeren
redis-cli flushall
```
## Test-Scripts:
- `test-local-redis.mjs` - Testet lokale Redis-Verbindung
- `test-redis-cache.mjs` - Umfassender Cache-Test
- `check-prod-redis.sh` - Testet Produktion Cache
## Nächste Schritte für Produktion:
1. Redis in Coolify einrichten
2. Umgebungsvariablen in Coolify setzen:
- REDIS_HOST
- REDIS_PORT
- REDIS_PASSWORD
- REDIS_USERNAME (optional)
3. Deploy und mit `/api/redis-status` prüfen
## Cache-Strategie:
- **Normale Links**: 5 Minuten Cache
- **Populäre Links**: 24 Stunden Cache
- **Passwort-geschützte Links**: Kein Cache
- **Abgelaufene Links**: Kein Cache
Der Cache beschleunigt Redirects von ~100ms auf ~10ms! 🚀