Skip to content

Commit b31bae3

Browse files
committed
update docs
1 parent ee022cb commit b31bae3

File tree

4 files changed

+10
-4
lines changed

4 files changed

+10
-4
lines changed

Dockerfile

-1
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,3 @@ RUN apk --no-cache upgrade && apk --no-cache add ca-certificates
55
COPY centrifugo /usr/local/bin/centrifugo
66

77
CMD ["centrifugo"]
8-

docs/content/faq.md

+4
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,10 @@ No - Centrifugo is best-effort transport. This means that if you want strongly g
8080

8181
Centrifugo can keep message history for a while and you can want to rely on it for your needs. Centrifugo is not designed as data storage - it uses message history mostly for recovering missed messages after short client internet connection disconnects. It's not designed to be used to sync client state after being offline for a long time - this logic should be on your app backend.
8282

83+
### What is the difference between Centrifugo and Centrifuge
84+
85+
[Centrifugo](https://github.com/centrifugal/centrifugo) is server built on top of [Centrifuge](https://github.com/centrifugal/centrifuge) library for Go language.
86+
8387
### I have not found an answer on my question here:
8488

8589
We have [gitter chat room](https://gitter.im/centrifugal/centrifugo) - welcome!

docs/content/misc/migrate.md

+5-2
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,15 @@ Centrifugo v2 simplified communication with API - requests should not be signed
1414

1515
Centrifugo v1 could process messages published in Redis queue. In v2 this possibility was removed because this technique is not good in terms of error handling and non-deterministic delay before message will be processed by Centrifugo node worker. Migrate to using HTTP or GRPC API.
1616

17-
### Use JWT instead of hand-crafted token
17+
### Use JWT instead of hand-crafted connection token
1818

1919
In Centrifugo v2 you must use JWT instead of hand-crafted tokens of v1. This means that you need to download JWT library for your language (there are plenty of them – see jwt.io) and build connection token with it.
2020

2121
See dedicated docs chapter to see how token can be built.
2222

2323
All connection information will be passed inside this single token string. This means you only need to pass one string to your frontend. No need to pass `user`, `timestamp`, `info` anymore. This also means that you will have less problems with escaping features of template engines - because JWT is safe base64 string.
2424

25-
###
25+
### Use JWT instead of hand-crafted signature for private subscriptions
26+
27+
Read chapter about private subscriptions to find how you should now use JWT for private channel subscriptions.
28+

docs/content/server/protocol.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ The tip whether or not connection must be refreshed comes in reply to `connect`
222222

223223
When client connection expire mechanism is on the value of field `expires` in connect reply is `true`. In this case client implementation should look at `ttl` value which is seconds left until connection will be considered expired. Client must send `refresh` command after this `ttl` seconds. Server gives client a configured window to refresh token after `ttl` passed and then closes connection if client have not updated its token.
224224

225-
When connecting with already expired token an error will be returned (with code `110`). In this case client should refresh its token and reconnect with exponential backoff.
225+
When connecting with already expired token an error will be returned (with code `109`). In this case client should refresh its token and reconnect with exponential backoff.
226226

227227
### RPC-like calls: publish, history, presence
228228

0 commit comments

Comments
 (0)