2019/1/25 Workers Release Notes

New this week:

  • New JS API: ReadableStream.pipeTo()/pipeThrough(). This method allows scripts to pump the entirety of a ReadableStream to a WritableStream without using their allowed CPU time. We implement it as described in the MDN docs except for the preventAbort and preventCancel options. For now, it cannot be called on the readable side of a TransformStream.
  • Behavior change: the soft real time limit of 15 seconds has been removed. Worker scripts may now make new subrequests for as long as the client remains connected – when the client disconnects, the request’s tasks are proactively canceled. Tasks spawned with event.waitUntil() are given a 30-second grace period before this cancellation.
  • V8 updated: 7.2.502.20 -> 7.2.502.21

Is this preparation for/related to websocket support? Glad to see the hard limit removed.

1 Like

Yes, that’s one motivation. Another is that use cases for ReadableStream.pipeTo() often also require making new subrequests after 15 seconds.