Skip to content

Commit 8473d45

Browse files
authored
Merge pull request #468 from kuzzleio/remove-socketio
## What does this PR do? Socket.io is not supported by Kuzzle v2 anymore. ### Other changes - Update documentation and README links for Kuzzle v2
2 parents 9330826 + 7478617 commit 8473d45

File tree

101 files changed

+208
-845
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

101 files changed

+208
-845
lines changed

README.md

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,8 @@ This is the official Javascript SDK for the free and open-source backend Kuzzle.
2424

2525
#### Multiprotocols
2626

27-
Currently, the SDK provides 3 protocols: __Http, WebSocket and SocketIO.__
28-
WebSocket and Socket.IO protocols implement the whole Kuzzle API, while the HTTP protocol does not implement realtime features (rooms and subscriptions).
29-
While Socket.IO offers better compatibility with older web browsers, our raw WebSocket implementation is about 20% faster.
27+
Currently, the SDK provides 2 protocols: __Http and WebSocket.__
28+
WebSocket protocol implement the whole Kuzzle API, while the HTTP protocol does not implement realtime features (rooms and subscriptions).
3029

3130
#### Promises based
3231

@@ -35,7 +34,7 @@ For example, for the action create of the controller collection (_collection:cre
3534
Any error must be caught either at the end of the `Promise` chain, or by using `async/await` and a `try...catch`.
3635

3736
<p align="center">
38-
:books: <b><a href="https://docs-v2.kuzzle.io/sdk-reference/js/6/">Documentation</a></b>
37+
:books: <b><a href="https://docs.kuzzle.io/sdk-reference/js/7">Documentation</a></b>
3938
</p>
4039

4140
### Kuzzle
@@ -45,7 +44,7 @@ an administration console and a set of plugins that provide advanced functionali
4544

4645
* :octocat: __[Github](https://github.com/kuzzleio/kuzzle)__
4746
* :earth_africa: __[Website](https://kuzzle.io)__
48-
* :books: __[Documentation](https://docs-v2.kuzzle.io)__
47+
* :books: __[Documentation](https://docs.kuzzle.io)__
4948
* :email: __[Gitter](https://gitter.im/kuzzleio/kuzzle)__
5049

5150

@@ -113,13 +112,6 @@ Then the Kuzzle SDK will be available under the `KuzzleSDK` variable:
113112
</script>
114113
```
115114

116-
If you want to support older browser versions, you may load `socket.io` before Kuzzle, making the SDK compatible with browsers without websocket support:
117-
118-
```html
119-
<!-- Don't forget to include socketio before Kuzzle SDK -->
120-
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/socket.io/2.0.3/socket.io.slim.js"></script>
121-
```
122-
123115
#### Browser with Webpack
124116

125117
If you use Webpack, you'll likely use the NPM-packaged version of the SDK (like in Node)

doc/7/controllers/auth/get-current-user/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ Additional query options
3131

3232
## Resolves
3333

34-
A [User](/sdk/js/6/core-classes/user) representing the current user logged with the SDK.
34+
A [User](/sdk/js/7/core-classes/user) representing the current user logged with the SDK.
3535

3636
## Usage
3737

doc/7/controllers/auth/login/index.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ description: Authenticate a user
99

1010
Authenticates a user.
1111

12-
If this action is successful, then the [jwt](/sdk/js/6/core-classes/kuzzle/properties) property of this class instance is set to the new authentication token.
12+
If this action is successful, then the [jwt](/sdk/js/7/core-classes/kuzzle/properties) property of this class instance is set to the new authentication token.
1313

14-
All further requests emitted by this SDK instance will be on behalf of the authenticated user, until either the authenticated token expires, the [logout](/sdk/js/6/controllers/auth/logout) action is called, or the `jwt` property is manually set to another value.
14+
All further requests emitted by this SDK instance will be on behalf of the authenticated user, until either the authenticated token expires, the [logout](/sdk/js/7/controllers/auth/logout) action is called, or the `jwt` property is manually set to another value.
1515

1616
## Arguments
1717

@@ -29,16 +29,16 @@ login(strategy, [credentials], [expiresIn]);
2929

3030
### strategy
3131

32-
The name of the [authentication strategy](/core/1/guides/kuzzle-depth/authentication) used to log the user in.
32+
The name of the [authentication strategy](/core/2/guides/kuzzle-depth/authentication) used to log the user in.
3333

3434
Depending on the chosen authentication strategy, additional credential arguments may be required.
3535
The API request example in this page provides the necessary arguments for the [`local` authentication plugin](https://github.com/kuzzleio/kuzzle-plugin-auth-passport-local).
3636

37-
Check the appropriate [authentication plugin](/core/1/plugins/guides/strategies/overview) documentation to get the list of additional arguments to provide.
37+
Check the appropriate [authentication plugin](/core/2/plugins/guides/strategies/overview) documentation to get the list of additional arguments to provide.
3838

3939
### expiresIn
4040

41-
The default value for the `expiresIn` option is defined at server level, in Kuzzle's [configuration file](/core/1/guides/essentials/configuration).
41+
The default value for the `expiresIn` option is defined at server level, in Kuzzle's [configuration file](/core/2/guides/essentials/configuration).
4242

4343
## Resolves
4444

doc/7/controllers/auth/logout/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Revokes the current authentication token.
1111

1212
If there were any, real-time subscriptions are cancelled.
1313

14-
If this action is successful, then the [jwt](/sdk/js/6/core-classes/kuzzle/properties) property of this class instance is unset.
14+
If this action is successful, then the [jwt](/sdk/js/7/core-classes/kuzzle/properties) property of this class instance is unset.
1515

1616
<br/>
1717

doc/7/controllers/auth/refresh-token/index.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ description: Refresh an authentication token
1111

1212
Refreshes a valid, non-expired authentication token.
1313

14-
If this action is successful, then the [jwt](/sdk/js/6/core-classes/kuzzle/properties) property of this class instance is set to the new authentication token.
14+
If this action is successful, then the [jwt](/sdk/js/7/core-classes/kuzzle/properties) property of this class instance is set to the new authentication token.
1515

16-
All further requests emitted by this SDK instance will be on behalf of the authenticated user, until either the authenticated token expires, the [logout](/sdk/js/6/controllers/auth/logout) action is called, or the `jwt` property is manually set to another value.
16+
All further requests emitted by this SDK instance will be on behalf of the authenticated user, until either the authenticated token expires, the [logout](/sdk/js/7/controllers/auth/logout) action is called, or the `jwt` property is manually set to another value.
1717

1818

1919
## Arguments
@@ -40,15 +40,15 @@ Additional query options
4040

4141
### expiresIn
4242

43-
The default value for the `expiresIn` option is defined at server level, in Kuzzle's [configuration file](/core/1/guides/essentials/configuration).
43+
The default value for the `expiresIn` option is defined at server level, in Kuzzle's [configuration file](/core/2/guides/essentials/configuration).
4444

4545
## Resolves
4646

4747
The `refreshToken` action resolves to a token object with the following properties:
4848

4949
| Property | Type | Description |
5050
|--------------|---------|-------------|
51-
| `_id` | <pre>string</pre> | User unique identifier ([kuid](/core/1/guides/essentials/user-authentication#kuzzle-user-identifier-kuid)) |
51+
| `_id` | <pre>string</pre> | User unique identifier ([kuid](/core/2/guides/essentials/user-authentication#kuzzle-user-identifier-kuid)) |
5252
| `expiresAt` | <pre>number</pre> | Expiration timestamp in Epoch-millis format (UTC) |
5353
| `jwt` | <pre>string</pre> | Authentication token |
5454
| `ttl` | <pre>number</pre> | Time to live of the authentication token, in milliseconds |

doc/7/controllers/auth/update-self/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ description: Updates the current user object in Kuzzle.
99

1010
Updates the currently logged in user content.
1111

12-
This route cannot update the list of associated security profiles. To change a user's security profiles, the route [security:updateUser](/core/1/api/controllers/security/update-user) must be used instead.
12+
This route cannot update the list of associated security profiles. To change a user's security profiles, the route [security:updateUser](/core/2/api/controllers/security/update-user) must be used instead.
1313

1414
<br/>
1515

@@ -34,7 +34,7 @@ Additional query options
3434

3535
## Resolves
3636

37-
A [User](/sdk/js/6/core-classes/user) representing the current user logged with the SDK.
37+
A [User](/sdk/js/7/core-classes/user) representing the current user logged with the SDK.
3838

3939
## Usage
4040

doc/7/controllers/bulk/import/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ description: Performs a bulk import on a collection
99

1010
Create, update or delete large amount of documents as fast as possible.
1111

12-
This route is faster than the `document:m*` routes family (e.g. [document:mCreate](/sdk/js/6/controllers/document/m-create)), but no real-time notifications will be generated, even if some of the documents in the import match subscription filters.
12+
This route is faster than the `document:m*` routes family (e.g. [document:mCreate](/sdk/js/7/controllers/document/m-create)), but no real-time notifications will be generated, even if some of the documents in the import match subscription filters.
1313

1414
<br/>
1515

doc/7/controllers/bulk/mWrite/index.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ description: Creates or replaces multiple documents directly into the storage en
1414
Creates or replaces multiple documents directly into the storage engine.
1515

1616
This is a low level route intended to bypass Kuzzle actions on document creation, notably:
17-
- check [document validity](/core/1/guides/essentials/data-validation),
18-
- add [kuzzle metadata](/core/1/guides/essentials/document-metadata),
19-
- trigger [realtime notifications](/core/1/guides/essentials/real-time) (unless asked otherwise)
17+
- check [document validity](/core/2/guides/essentials/data-validation),
18+
- add [kuzzle metadata](/core/2/guides/essentials/document-metadata),
19+
- trigger [realtime notifications](/core/2/guides/essentials/real-time) (unless asked otherwise)
2020

2121
<br/>
2222

doc/7/controllers/bulk/write/index.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ description: Creates or replaces a document directly into the storage engine.
1414
Creates or replaces a document directly into the storage engine.
1515

1616
This is a low level route intended to bypass Kuzzle actions on document creation, notably:
17-
- check [document validity](/core/1/guides/essentials/data-validation),
18-
- add [kuzzle metadata](/core/1/guides/essentials/document-metadata),
19-
- trigger [realtime notifications](/core/1/guides/essentials/real-time) (unless asked otherwise).
17+
- check [document validity](/core/2/guides/essentials/data-validation),
18+
- add [kuzzle metadata](/core/2/guides/essentials/document-metadata),
19+
- trigger [realtime notifications](/core/2/guides/essentials/real-time) (unless asked otherwise).
2020

2121
<br/>
2222

doc/7/controllers/collection/create/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ description: Create a new collection
77

88
# create
99

10-
Creates a new [collection](/core/1/guides/essentials/store-access-data) in Kuzzle via the persistence engine, in the provided index.
10+
Creates a new [collection](/core/2/guides/essentials/store-access-data) in Kuzzle via the persistence engine, in the provided index.
1111

1212
You can also provide an optional data mapping that allow you to exploit the full capabilities of our
1313
persistent data storage layer, [ElasticSearch](https://www.elastic.co/products/elasticsearch) (check here the [mapping capabilities of ElasticSearch](https://www.elastic.co/guide/en/elasticsearch/reference/7.3/mapping.html)).
@@ -48,7 +48,7 @@ const mapping = {
4848
};
4949
```
5050

51-
More informations about database mappings [here](/core/1/guides/essentials/database-mappings).
51+
More informations about database mappings [here](/core/2/guides/essentials/database-mappings).
5252

5353
### options
5454

0 commit comments

Comments
 (0)