debian-forge-composer/internal/worker
Tomas Hozza bdf009f800 UploadJobArtifact(): return 400 if not accepting artifacts
The worker server API handler `UploadJobArtifact()` was previously
silently discarding artifacts uploaded by the worker, if the server was
configured to not accept artifacts.

Change the behavior to return HTTP error "Bad Request" (`400`) to the
worker, in case it tries to upload artifact to the server, but the
server is configured to not accept any artifacts.

Add a new unit test testing the new behavior and adjust existing unit
tests, which were relying on the artifact being previously silently
discarded.
2022-06-17 17:37:15 +02:00
..
api api/{cloud,worker}: used channel name based on JWT claims for new jobs 2022-03-08 12:07:00 +01:00
clienterrors worker: treat ErrorKojiFailedDependency as a dependency error 2022-06-10 14:48:18 +01:00
client.go worker: add proxy support to composer and oauth calls 2022-05-03 06:19:31 +01:00
client_test.go worker: define job types as constants 2022-06-10 14:48:18 +01:00
json.go cloudapi: switch osbuild-koji -> osbuild for Koji build jobs 2022-06-10 14:48:18 +01:00
proxy_test.go worker: add proxy support to composer and oauth calls 2022-05-03 06:19:31 +01:00
server.go UploadJobArtifact(): return 400 if not accepting artifacts 2022-06-17 17:37:15 +02:00
server_test.go UploadJobArtifact(): return 400 if not accepting artifacts 2022-06-17 17:37:15 +02:00