textileio / js-textile

Textile's JavaScript Libs. Home of ThreadDB, Buckets, and more. Available on npm as `@textile/hub`.
https://textileio.github.io/js-textile/docs
MIT License
84 stars 19 forks source link

Add Node transport by env #596

Closed andrewxhill closed 4 years ago

andrewxhill commented 4 years ago

https://github.com/textileio/js-hub/blob/a62eb930868b2f3f7621a98f485663e142eb524f/packages/grpc-connection/src/index.ts#L19

@asutula is doing this in pow

export const getTransport = (): grpc.TransportFactory | undefined =>
  isNode ? NodeHttpTransport() : undefined

not sure if we need it here or if it is redundant with other things we are doing. so needs deeper look, just recording.

asutula commented 4 years ago

I don't think this is needed because the Node transport doesn't support client or bidirectional streams. For this reason, Powergate now uses only the Textile WebSocketTransport for browser and Node.