Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
runarheggset committed Aug 28, 2018
2 parents fc163e5 + 61e071d commit 7864e1d
Show file tree
Hide file tree
Showing 21 changed files with 6,727 additions and 1,912 deletions.
15 changes: 8 additions & 7 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,8 @@ env:
- GLOBAL_TESTSERVER=true
- SEPARATE_TEST_SUITES=true
matrix:
# Browsers that do not support trusting self-signed certs for wss:// connections are disabled (see https://github.com/improbable-eng/grpc-web/issues/165)
- GOTEST=1
- BROWSER=nodejs
- BROWSER=edge14_win
- BROWSER=edge13_win
- BROWSER=ie11_win DISABLE_WEBSOCKET_TESTS=true
- BROWSER=firefox53_osx
- BROWSER=firefox39_osx
- BROWSER=firefox38_osx
Expand All @@ -28,6 +25,12 @@ env:
- BROWSER=chrome_43
- BROWSER=chrome_42
- BROWSER=chrome_41
# Edge does not support aborting fetch requests (documented known limitation in project README)
- BROWSER=edge15_win DISABLE_ABORT_TESTS=true
- BROWSER=edge14_win DISABLE_ABORT_TESTS=true
- BROWSER=edge13_win DISABLE_ABORT_TESTS=true
# Browsers that do not support trusting self-signed certs for wss:// connections are disabled (see https://github.com/improbable-eng/grpc-web/issues/165)
- BROWSER=ie11_win DISABLE_WEBSOCKET_TESTS=true
- BROWSER=safari11 DISABLE_WEBSOCKET_TESTS=true
- BROWSER=safari9_1 DISABLE_WEBSOCKET_TESTS=true
- BROWSER=safari8 DISABLE_WEBSOCKET_TESTS=true
Expand All @@ -37,16 +40,14 @@ cache:
- node_modules
before_install:
- sudo apt-get install unzip
- bash install-protobuf.sh
- . ./install-protobuf.sh
- true && `base64 --decode <<< ZXhwb3J0IEJST1dTRVJfU1RBQ0tfVVNFUk5BTUU9aW1wcm9iYWJsZWVuZ2JvdDEK`
- true && `base64 --decode <<< ZXhwb3J0IEJST1dTRVJfU1RBQ0tfQUNDRVNTX0tFWT1SRG1Cc2pwQUJ4RlljcEVkeVp5bwo=`
install:
- go get -u github.com/golang/dep/cmd/dep
- go get -u golang.org/x/tools/cmd/goimports
- go get -u github.com/robertkrimen/godocdown/godocdown
- go get -u github.com/golang/protobuf/protoc-gen-go
- dep ensure
- export PATH=/home/travis/gopath/src/github.com/improbable-eng/grpc-web/protobuf/bin:$PATH
- nvm install
- npm install
before_script:
Expand Down
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -172,9 +172,17 @@ The code here is `alpha` quality. It is being used for a subset of Improbable's

## Known Limitations

### Edge - Unable to abort RPCs

When using Fetch - the default transport for Edge 13+ - RPCs will fail to be aborted. The signal to abort will not be received by the server, potentially resulting in zombie streams in the case of infinite server-streams.

The connection will be closed as normal if the user navigates away from the browser context making the RPC.

See this issue: https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/13009916/

### Server-side streaming with XHR

Browsers that don't support [Fetch with `body.getReader`](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStream) (Currently only supported by Edge 14+, Chrome 43+ - full ReadableStream was added in Chrome 52, but only `body.getReader()` is used) or `XMLHttpRequest.responseType = moz-chunked-arraybuffer` (Firefox 38+) use [XmlHttpRequest (XHR)](https://developer.mozilla.org/en/docs/Web/API/XMLHttpRequest).
Browsers that don't support [Fetch with `body.getReader`](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStream) (Currently only supported by Edge 13+, Chrome 43+ - full ReadableStream was added in Chrome 52, but only `body.getReader()` is used) or `XMLHttpRequest.responseType = moz-chunked-arraybuffer` (Firefox 38+) use [XmlHttpRequest (XHR)](https://developer.mozilla.org/en/docs/Web/API/XMLHttpRequest).

XHR keeps the entire server response in memory. This means that a long-lived or otherwise large streaming response will consume a large amount of memory in the browser and may cause instability. Fetch does not suffer from this issue. It is therefore advised that you don't use open-ended or large payload server streaming if you intend to support browsers that do not support Fetch.

Expand Down
10 changes: 5 additions & 5 deletions example/go/Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 7864e1d

Please sign in to comment.