feat: replace ?offset= seek with HTTP Range streaming across API, proxy, and client
- API: enableRangeProcessing true on no-offset FileStream path - Proxy: transparent Range relay, forwards 206/416/Content-Range verbatim - TrackMediaClient: Range: bytes=X- replaces ?offset=X; response disposed via TrackMediaResponse - StreamDecoder: reinitializeForRangeContinuation retains wavHeader, counts raw PCM against 206 Content-Length - AudioPlayer: seekBeyondBuffer adds headerSize for file-absolute offset; duration guard prevents continuation overwriting full-track duration - StreamingAudioPlayerService: seek guard corrected to >= 0 (file-absolute offset contract)
This commit is contained in:
@@ -403,8 +403,10 @@ public class TrackController : ControllerBase
|
||||
_logger.LogInformation(
|
||||
"Streaming track from disk: {TrackId}, Size: {Size} bytes",
|
||||
trackId, streamLength);
|
||||
// enableRangeProcessing: false — seek is served by WavOffsetService, not Range.
|
||||
return File(innerStream, streamMimeType, enableRangeProcessing: false);
|
||||
// enableRangeProcessing: true — seek is served by HTTP Range requests.
|
||||
// The FileStream is seekable, so ASP.NET Core honours an incoming
|
||||
// Range header by slicing the file and responding 206 Partial Content.
|
||||
return File(innerStream, streamMimeType, enableRangeProcessing: true);
|
||||
}
|
||||
|
||||
// Offset path: route through TrackContentService.GetAudioBinaryAsync (Track B's
|
||||
|
||||
Reference in New Issue
Block a user