forked from mtusi2026/mtusi2026lab4
lab4: память загрузок и S3 под лимитом, документация защиты
- тело загрузки: один буфер ровно Content-Length, без копий до S3 и djpeg; - PNG: zlib получает вход кусками по 64 KiB (unconsumed_tail копировал остаток IDAT); - djpeg, убитый OOM-killer'ом, -> 503 (ресурсы сервера), а не 415; - api: memswap_limit = memory (жёсткий лимит без swap); S3: GOMEMLIMIT и лимиты одновременных загрузок SeaweedFS, память 1g; - docs: CONSISTENCY.md, DEFENSE.md, WINDOWS.md, DATA_MODEL.md под lab4; scripts/demo_attachments.py для сценария защиты; CI и collect_evidence под lab4; - bench/reconcile_faults.py: отчёты трека 2 (ошибки с обеих сторон, прерванный apply). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
a2d867bec6
commit
4ea6924db1
@@ -30,11 +30,16 @@ cat > /tmp/s3.json <<EOF
|
||||
]
|
||||
}
|
||||
EOF
|
||||
# Memory: by default SeaweedFS buffers every in-flight upload without a limit and the Go runtime
|
||||
# keeps freed heap; measured ~1 GB under 16 parallel 9.4 MiB PUTs (evidence/memory). The upload
|
||||
# limits make excess PUTs wait inside SeaweedFS instead of growing the heap, and GOMEMLIMIT (set
|
||||
# in compose.yaml below the container limit) makes the Go GC return memory before the cgroup OOM.
|
||||
exec weed server \
|
||||
-dir=/data \
|
||||
-ip=127.0.0.1 -ip.bind=127.0.0.1 \
|
||||
-master.telemetry=false \
|
||||
-master.volumeSizeLimitMB=1024 -volume.max=0 \
|
||||
-filer -filer.disableDirListing \
|
||||
-s3 -s3.ip.bind=0.0.0.0 -s3.port=8333 -s3.config=/tmp/s3.json \
|
||||
-filer -filer.disableDirListing -filer.concurrentUploadLimitMB=128 \
|
||||
-volume.concurrentUploadLimitMB=128 \
|
||||
-s3 -s3.ip.bind=0.0.0.0 -s3.port=8333 -s3.config=/tmp/s3.json -s3.concurrentUploadLimitMB=128 \
|
||||
-s3.iam=false -s3.autoCreateBucket=false -s3.port.iceberg=0 -s3.port.lance=0
|
||||
|
||||
Reference in New Issue
Block a user