Skip to content

Commit 8f08b28

Browse files
authored
Merge pull request #476 from primus/remove/socket.io
Remove Socket.IO transformer
2 parents df17f2a + aa0ae57 commit 8f08b28

9 files changed

Lines changed: 0 additions & 4109 deletions

File tree

README.md

Lines changed: 0 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@ repository.
7373
- [BrowserChannel](#browserchannel)
7474
- [Engine.IO](#engineio)
7575
- [Faye](#faye)
76-
- [Socket.IO](#socketio)
7776
- [SockJS](#sockjs)
7877
- [uws](#uws)
7978
- [WebSockets](#websockets)
@@ -1262,53 +1261,6 @@ var Socket = primus.Socket
12621261
, socket = new Socket('url');
12631262
```
12641263

1265-
#### Socket.IO
1266-
1267-
The Socket.IO transport was written against Socket.IO 0.9.x. It was one of the
1268-
first real-time servers written on Node.js and is one of the most used modules
1269-
in Node.js. It uses multiple transports to connect the server. To use Socket.IO
1270-
you need to install the `socket.io` module:
1271-
1272-
```
1273-
npm install socket.io@0.9.x --save
1274-
```
1275-
1276-
And tell `Primus` that you want to use `socket.io` as transformer:
1277-
1278-
```js
1279-
var primus = new Primus(server, { transformer: 'socket.io' });
1280-
```
1281-
1282-
If you want to use the client interface inside of Node.js you also need to
1283-
install the `primus-socket.io-client` module. This a fork of `socket.io-client`
1284-
maintained by us to fix the bugs found on the 0.9 branch which is no longer
1285-
supported upstream:
1286-
1287-
```
1288-
npm install primus-socket.io-client --save
1289-
```
1290-
1291-
If you want, you can opt out of our fixes and use the original `socket.io-client`.
1292-
To do that just install `socket.io-client` instead of `primus-socket.io-client`:
1293-
1294-
```
1295-
npm install socket.io-client@0.9.x --save
1296-
```
1297-
1298-
And then you can access it from your server instance:
1299-
1300-
```js
1301-
var Socket = primus.Socket
1302-
, socket = new Socket('url');
1303-
```
1304-
1305-
**Please keep in mind that the browser client will always use our fixes.**
1306-
1307-
**Note: Primus will never support Socket.IO 1.0. As it's just an abstraction built
1308-
upon Engine.IO so it makes more sense to use Engine.IO in Primus directly.
1309-
Socket.IO 0.9.x will be supported as it uses a completely different transport
1310-
system.**
1311-
13121264
#### SockJS
13131265

13141266
SockJS is a real-time server that focuses on cross-domain connections and does

package.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,14 +77,12 @@
7777
"faye-websocket": "0.11.x",
7878
"mocha": "2.5.x",
7979
"pre-commit": "1.1.x",
80-
"primus-socket.io-client": "2.0.x",
8180
"pumpify": "1.3.x",
8281
"querystringify": "0.0.x",
8382
"recovery": "0.2.x",
8483
"request": "2.72.x",
8584
"rocambole": "0.7.x",
8685
"rocambole-node-remove": "1.0.x",
87-
"socket.io": "0.9.x",
8886
"sockjs": "0.3.x",
8987
"sockjs-client": "1.1.x",
9088
"through2": "2.0.x",

test/socket.io.integration.js

Lines changed: 0 additions & 3 deletions
This file was deleted.

transformers.json

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,6 @@
77
"server": "engine.io",
88
"client": "engine.io-client"
99
},
10-
"socket.io": {
11-
"server": "socket.io",
12-
"client": "primus-socket.io-client"
13-
},
1410
"browserchannel": {
1511
"server": "browserchannel",
1612
"client": "browserchannel"

transformers/socket.io/client.js

Lines changed: 0 additions & 113 deletions
This file was deleted.

transformers/socket.io/index.js

Lines changed: 0 additions & 15 deletions
This file was deleted.

0 commit comments

Comments
 (0)