Recently merged
grpc-web
support #109 uses anXhrTransport
suitable for the browser. This project uses'dart:io'
for a regularHTTP transport
for non-brower clients.
Although this is a hack/experiment to get gRPC working over HTTP/1 with https://github.com/improbable-eng/grpc-web; it has been in use for a while using this setup.
It provides an implementation of ClientChannel as suggested grpc/grpc-dart - issue 43
The message is unpacked using grpcwebstreamparser.js
from github.com/grpc/grpc-dart
Only regular RPC calls have been implemented.
final channel = useHttp2 == true
? new ClientChannel(...)
: new WebClientChannel(...);
final client = BookServiceClient(channel);
client.getBook(new GetBookRequest()..isbn = new Int64(60929871));
make serve &
make test
- Streaming
- Create a
HTTP Transport
that fits well with the changes forgrpc-web
support #109 ingrpc-dart
.