Skip to content

Add transfer retries and batches#1664

Open
jpdillingham wants to merge 30 commits intomasterfrom
retries
Open

Add transfer retries and batches#1664
jpdillingham wants to merge 30 commits intomasterfrom
retries

Conversation

@jpdillingham
Copy link
Member

@jpdillingham jpdillingham commented Mar 7, 2026

Testing

I ran another copy of slskd with the following adjustment to the upload code:

governor: (tx, req, ct) =>
{
    if (Random.Shared.NextDouble() < 0.5)
    {
        Log.Error("Unlucky!!!");
        throw new Exception("unlucky");
    }
    return Governor.GetBytesAsync(tx.Username, req, ct);
},

This gives uploads a 50% chance of failing each time the governor is asked for a block of bytes, which is every iteration of the send loop. With this in place, I downloaded a directory:

image

Each file failed and was automatically retried, up to 96 times. I found and fixed a bug with progress reporting in Soulseek.NET here, and with that, everything seems to be working perfectly.

Source files:

image

Downloaded files:

image

@jpdillingham jpdillingham added the breaking change This is a breaking change label Mar 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant