Skip to content

Commit 34adcb9

Browse files
author
Deploy
committed
docs: added connect method
1 parent 3657e87 commit 34adcb9

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

docs/arangodb-client.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,22 @@ Pass chained method to the admin manager.
128128
$arangoClient->admin()->getVersion();
129129
```
130130

131+
### connect(array $config = [], ?GuzzleClient $httpClient = null): void
132+
You can update the config by calling the connect method. This replaces the underlying connection
133+
and prepares the connection for any requests that follow.
134+
135+
```
136+
$config = [
137+
'host' => 'http://localhost',
138+
'port' => '8529',
139+
'username' => 'your-other-database-username',
140+
'password' => 'your-other-database-password',
141+
'database'=> 'your-other-database'
142+
];
143+
144+
$arangoClient->connect($config): void
145+
```
146+
131147
### disconnect(): bool
132148
Disconnect from the current keep-alive connection, if any.
133149

0 commit comments

Comments
 (0)