You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 06ffbd3
Browse filesBrowse the repository at this point in the historyBrowse files
Implement block on connect with Rust SDK (agones-dev#953)
- Uses a simple polling mechanism to confirm the connection is live
- Add `ready` to the SDK documentation.
- Implements and documents a sdk.connect() function
- Tweaks the conformance tests to add a random delay to ensure future
testing of SDK blocking.
Fixesagones-dev#938
Copy file name to clipboardExpand all lines: site/content/en/docs/Guides/Client SDKs/nodejs.md
+11-1Lines changed: 11 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -28,14 +28,24 @@ Add the agones dependency to `package.json`, replacing with the download locatio
28
28
}
29
29
```
30
30
31
-
To begin working with the SDK, create an instance of it. This will open a connection to the SDK server.
31
+
To begin working with the SDK, create an instance of it. {{< feature expiryVersion="0.12.0" >}}This will open a connection to the SDK server.{{< /feature >}}
32
32
33
33
```javascript
34
34
constAgonesSDK=require('agones');
35
35
36
36
let agonesSDK =newAgonesSDK();
37
37
```
38
38
39
+
{{% feature publishVersion="0.12.0" %}}
40
+
41
+
To connect to the SDK server, either local or when running on Agones, run the `async` method `sdk.connect()`, which will
42
+
`resolve` once connected or `reject` on error or if no connection can be made after 30 seconds.
43
+
44
+
```javascript
45
+
awaitagonesSDK.connect();
46
+
```
47
+
{{% /feature %}}
48
+
39
49
To send a [health check]({{< relref "_index.md#health" >}}) ping call `health()`.
0 commit comments