Repository navigation
Conversation
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The upload client can hang indefinitely after receiving response headers despite a configured HTTP timeout, and its GUID validation accepts whitespace-padded values that can cause acknowledgment mismatches.
2 open issues
What changed in this PR
Adds an opt-in transport for sending prepared Bowl schema 2 crash ZIPs to GeneralSpace, without integrating outbox consumption or evidence deletion.
Changes:
- Adds HTTPS multipart uploads with configured tenant/app identity, size limits, response validation, and optional SHA-256 verification.
- Adds tests for upload formatting, validation, retries, snapshot isolation, and cancellation.
- Documents host security responsibilities and prerequisites for safe outbox integration.
| File | Description |
|---|---|
tests/CoreTest/Diagnostics/ArtifactUploadClientTests.cs |
Tests upload behavior and failure handling. |
src/GeneralUpdate.Core/Diagnostics/ArtifactUploadClient.cs |
Implements the transport, metadata, and acknowledgment types. |
docs/diagnostic-artifact-transport.md |
Documents usage, security requirements, and lifecycle boundaries. |
Review effort: Balanced
| var guid = artifact.Guid; | ||
| var kind = artifact.Kind; | ||
| var schema = artifact.Schema; | ||
| if (!Guid.TryParseExact(guid, "D", out _) || |
| if (!requestLength.HasValue || requestLength.Value > RequestLimit) | ||
| throw new InvalidOperationException("The multipart request exceeds the GeneralSpace transport limit."); | ||
|
|
||
| using var response = await _client.SendAsync(request, HttpCompletionOption.ResponseHeadersRead, cancellationToken) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
Scope and dependencies
This is a transport-only first step. It does not scan or delete the Bowl outbox, create durable snapshots, schedule retries, or integrate with the bootstrap lifecycle. Safe consumption depends on Bowl's
outboxProtocol: 1writer/GC/consumer lock protocol and a GeneralSpace release that verifies and returns stored ZIP hashes. The current anonymous endpoint does not authenticate AppKey; a deployment must supply authenticated access.Verification
dotnet test tests\CoreTest\CoreTest.csproj --no-restore --filter FullyQualifiedName~ArtifactUploadClientTests(15 passed)dotnet build src\GeneralUpdate.Core\GeneralUpdate.Core.csproj --no-restore(all target frameworks passed)