HardAtWork
09/08/2021, 7:40 PMlukeed
09/08/2021, 8:44 PMfetch()
but there are some abstractions in there that allow for non-fetch()
communicationlukeed
09/08/2021, 8:44 PMWallacy
09/08/2021, 10:05 PMWallacy
09/08/2021, 10:09 PMDatSparrow
09/09/2021, 1:09 AMErwin
09/09/2021, 4:43 AMlukeed
09/09/2021, 4:49 AMlukeed
09/09/2021, 4:49 AMeavestreasure
09/09/2021, 8:43 AMErwin
09/09/2021, 4:38 PMmatt
09/09/2021, 10:53 PMmatt
09/09/2021, 10:54 PMunalignedant
09/09/2021, 10:54 PM43fce291c00c55cba840abb1af0740c038cbf94d07976f7dd355080500a3a3dd
and it's exhibiting the behavior describedmatt
09/09/2021, 11:01 PMmatt
09/09/2021, 11:01 PMunalignedant
09/09/2021, 11:01 PMunalignedant
09/09/2021, 11:02 PMmatt
09/09/2021, 11:04 PMhttp://example.com/
work?unalignedant
09/09/2021, 11:05 PMhttp://example.com
and report back in a few min.matt
09/09/2021, 11:05 PMunalignedant
09/09/2021, 11:15 PMhttp://example.com
is failing as well. Here is what I did, and here are the resulting logs.
typescript
console.log('Requesting example dot com')
try {
await fetch('http://example.com')
} catch (e) {
// @ts-ignore
console.log('Error fetching example.com', e.message)
throw e
}
console.log('Fetched example dot com')
logs": [
{
"message": [
"handling queued video",
{
"type": "queue",
"videoId": "Rj-m1ploAys"
}
],
"level": "log",
"timestamp": 1631229159271
},
{
"message": [
"Requesting example dot com"
],
"level": "log",
"timestamp": 1631229159271
},
{
"message": [
"Error fetching example.com",
"Network connection lost."
],
"level": "log",
"timestamp": 1631229205273
}
]
unalignedant
09/09/2021, 11:16 PMwebsocket.addEventListener('message', () => {})
) to the DO, whereas the fetch that "succeeds" is part of the DO fetch
handlerunalignedant
09/09/2021, 11:16 PMhttp://example.com
in the fetch
handler path as well, and see if it then succeeds?unalignedant
09/09/2021, 11:21 PMfetch
path as wellmatt
09/09/2021, 11:23 PMunalignedant
09/09/2021, 11:25 PMfetch()
const pair = new WebSocketPair();
const serverSocket = pair[1];
const clientSocket = pair[0];
returning the clientSocket
in return new Response(null, { status: 101, webSocket: clientSocket });
matt
09/09/2021, 11:26 PMunalignedant
09/09/2021, 11:26 PMmatt
09/09/2021, 11:31 PM