@@ -63,17 +63,24 @@ These are uploaded to S3 directly by the GitHub workflows in `pytorch/pytorch`.
6363
6464### Logs and log classifications
6565
66- Logs are downloaded by the [ ` github-status-test ` ] AWS lambda, which receives
67- webhooks through a manual connection with the ` pytorch/pytorch ` repo.
68- ` github-status-test ` then pings another lambda, [ ` log-classifier ` ] , which
69- performs log classification (more detail in the [ README] ).
66+ The PyTorch bot's ` workflow_job ` handler (` lib/bot/logUploader.ts ` ) asynchronously
67+ invokes the [ ` gha-log-uploader ` ] lambda when a job completes. That lambda
68+ downloads the log from GitHub and puts it in the [ ` ossci-raw-job-status ` ] bucket
69+ under ` log/ ` . An S3 ` ObjectCreated ` notification on that prefix then invokes
70+ ` call-log-classifier ` , which invokes [ ` log-classifier ` ] to do the classification
71+ (more detail in the [ README] ).
7072
7173[ readme ] : https://github.com/pytorch/test-infra/blob/main/aws/lambda/log-classifier/README.md
7274
73- The logic in ` github-status-test ` could be moved to the ` hud.pytorch.org `
74- webhooks endpoint, and modified so that all repos that ` torchci ` is installed
75- on benefits from log downloads and classifications, but this is not currently
76- implemented. Add @suo as a reviewer on a PR if you want to add it!
75+ Because this hangs off the App webhook rather than a per-repo one, every repo the
76+ bot is installed on gets log downloads and classifications without an admin
77+ configuring anything. Which repos are enabled is controlled by the
78+ ` LOG_UPLOADER_REPOS ` env var while the cutover from [ ` github-status-test ` ] is in
79+ progress; see https://github.com/pytorch/test-infra/issues/7549 .
80+
81+ Missing logs are re-requested through ` backfillMissingLog ` in ` lib/jobUtils.ts ` ,
82+ which Dr.CI calls when it finds a failed job with no log. Callers outside HUD use
83+ the authenticated ` POST /api/log-uploader/backfill ` route.
7784
7885### Test statistics
7986
@@ -91,11 +98,17 @@ an example.
9198
9299### Raw webhook payloads
93100
94- For archival purposes, we save all raw webhook payloads to S3. This is done
95- through the [ ` github-status-test ` ] lambda (the same one that downloads logs).
96- The raw webhook payloads are uploaded to the [ ` ossci-raw-job-status ` ] S3 bucket.
101+ The [ ` github-status-test ` ] lambda archives raw webhook payloads to the
102+ [ ` ossci-raw-job-status ` ] S3 bucket, under a prefix per event type. Nothing reads
103+ them: ` clickhouse-replicator-s3 ` has no ` SUPPORTED_PATHS ` entry for
104+ ` workflow_job/ ` , ` workflow_run/ ` , or ` full_workflow_*/ ` , and ClickHouse gets jobs
105+ from DynamoDB through ` clickhouse-replicator-dynamo ` .
106+
107+ This archive goes away with the lambda. It is not reproduced in
108+ [ ` gha-log-uploader ` ] .
97109
98110[ `github-status-test` ] : https://us-east-1.console.aws.amazon.com/lambda/home?region=us-east-1#/functions/github-status-test?tab=code
111+ [ `gha-log-uploader` ] : https://github.com/pytorch/test-infra/blob/main/aws/lambda/gha-log-uploader/README.md
99112[ `ossci-raw-job-status` ] : https://s3.console.aws.amazon.com/s3/buckets/ossci-raw-job-status?region=us-east-1&tab=overview
100113
101114## Adding a new repo to ` torchci `
0 commit comments