# WebRTC in SharedWorker
## Attendees
- @gozala
- @lidel
- @vasco
## Context
It appears that websocket-star / web webrtc-star are being deprecated in favor of circuit-relays (See [libp2p/js-libp2p#385][]) which affects [node sharing endeavor][] due to lack of [WebRTC][] support in workers.
@gozala called for a meeting and hopes to take away following from this meeting:
- Do we absolutely need [WebRTC][] transport from the get go in [SharedWorker][] context ?
- No we don't.
- Are there are viable alternative to [WebRTC][] transport in [SharedWorker][] context ?
- Yes websocket-startdust -> relay-circuit
- General outline of exposing [WebRTC][] transport in [SharedWorker][] (e.g. tunneled [RTCDataChannel][] through [MessagePort][]) ?
- Warry about that later
- Probably as a followup
- What are the the tradeoffs in exposing tunneled [WebRTC][] vs other transport.
- Reduces transport options
- TODO: Look at the default bootstrap nodes
- If there are `n>=2` tabs with same IPFS app should we end up with `n` [WebRTC][] connections or could we keep `m<n` and reconnect when tab holding [RTCDataChannel][] is closed ?
### Notes
- no canonical place on how to setup a browser node.
- ipfs/in-web-browsers for have some guides
- Config for transports https://github.com/libp2p/js-libp2p/blob/master/doc/CONFIGURATION.md#transport
- websocket
- webrtc
- `-star` allows peers to receive connections
- multiaddr to wrap the address
- we are still supporting web-sockets
- we're not going to support web-socket-*
- migration path from web-socket-*
- docs are coming about runing js-ipfs in browsers
- we want to encouarge self-hosting instead of using our websocket-*
- because of refactor websocket-star was shut down (which is why we only have webrtc-star)
- startdust-websocket is same websocket-star but without socket-io
- currently deployed ones are incompatible with new ones
- next step
[libp2p/js-libp2p#385]:https://github.com/libp2p/js-libp2p/issues/385
[node sharing endeavor]:https://github.com/ipfs/js-ipfs/issues/3022
[WebRTC]:https://developer.mozilla.org/en-US/docs/Web/API/WebRTC_API
[RTCDataChannel]:https://developer.mozilla.org/en-US/docs/Web/API/RTCDataChannel
[MessagePort]:https://developer.mozilla.org/en-US/docs/Web/API/MessagePort
[SharedWorker]:https://developer.mozilla.org/en-US/docs/Web/API/SharedWorker