mirror of
git://f0xx.org/android_cast
synced 2026-07-29 04:18:09 +03:00
Merge branch 'feature/gzip-ota-build-deploy' into next.
Resolve deploy.sh migration helper duplication and combine gitignore entries for out/ and ota-publish/. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
|
||||
- **Main process:** `CrashReporter.install()` — any uncaught Java exception (cast or idle UI) → `files/crash_reports/pending/crash_yyyyMMdd_HHmmss.json` (same stamp as `session_*.json`). Active cast session stats are flushed with `globals.reason: "crash"` when applicable.
|
||||
- **Runtime context:** every report includes `runtime_context` (foreground activity, `CastActiveState`, last `session_*.json` name) and `scenario` (`cast_session` vs `app_runtime`).
|
||||
- **Watcher process:** `CrashWatcherService` in `:crashwatcher` — reads `settings.json` → `crash`, uploads pending reports, ingests native stub files.
|
||||
- **Watcher process:** `CrashWatcherService` in `:crashwatcher` — reads `settings.json` → `crash`, uploads pending reports (JSON body gzip-compressed), ingests native stub files.
|
||||
- **Native:** `crash_hook.c` (unwind + `dladdr`) writes stubs to `crash_reports/native/`; watcher converts to schema v1 JSON.
|
||||
- **User toggle:** Settings drawer → **Send anonymous crash logs** (`AppPreferences.send_anonymous_crash_logs`, default on).
|
||||
|
||||
|
||||
@@ -27,6 +27,8 @@ Store in DB:
|
||||
|
||||
## Upload API (`POST …/api/upload.php`)
|
||||
|
||||
Clients may send **`Content-Encoding: gzip`** with a gzip-compressed JSON body (same schema). The BE nginx upload `location` should use `gunzip on` + `gunzip_types application/json`; PHP accepts plain or gzip.
|
||||
|
||||
Phases:
|
||||
|
||||
1. **Phase A (now):** Accept extra JSON fields; persist inside `payload_json`; console search includes `ingest.source` in blob.
|
||||
|
||||
14
docs/OTA.md
14
docs/OTA.md
@@ -111,10 +111,20 @@ When `ota.trusted=true` and build is debug, strict checksum/sign enforcement is
|
||||
|
||||
```bash
|
||||
chmod +x scripts/generate-ota-v0.sh
|
||||
./scripts/generate-ota-v0.sh app/build/outputs/apk/release/app-release.apk https://your-host:port ./ota-publish
|
||||
./scripts/generate-ota-v0.sh app/build/outputs/apk/release/app-release.apk https://your-host:port ./ota-publish staging
|
||||
```
|
||||
|
||||
Upload the contents of `ota-publish/` to your web root so `https://your-host/v0/ota/...` resolves.
|
||||
Fourth argument is the **channel** file name (`stable`, `staging`, `next`, …). Upload `ota-publish/v0/` to your web root so `https://your-host/v0/ota/...` resolves.
|
||||
|
||||
### Docker build + staging channel
|
||||
|
||||
See [BUILD_DEPLOY.md](BUILD_DEPLOY.md):
|
||||
|
||||
```bash
|
||||
export OTA_BASE_URL=https://apps.f0xx.org
|
||||
./scripts/docker-build-ota.sh
|
||||
./scripts/deploy-ota-staging.sh # after setting OTA_DEPLOY_TARGET
|
||||
```
|
||||
|
||||
## App configuration
|
||||
|
||||
|
||||
@@ -170,4 +170,5 @@ See [ndk/README.md](../ndk/README.md).
|
||||
- [PRO_AAR.md](PRO_AAR.md) — cast-core / cast-pro entitlements
|
||||
- [OPEN_API.md](OPEN_API.md) — crash ingest triage API
|
||||
- [OTA.md](OTA.md) — backend layout v0
|
||||
- [BUILD_DEPLOY.md](BUILD_DEPLOY.md) — Docker build, staging OTA, deploy flow
|
||||
- [CRASH_REPORTER.md](CRASH_REPORTER.md) — crash upload
|
||||
|
||||
Reference in New Issue
Block a user