Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ Test the connection using the following example script:
const firebolt = Firebolt();
await firebolt.testConnection(connectionOptions)
```
which will perform authentication and a simple `select 1` query
which will perform authentication and a simple `select 1` query. This method is designed to verify the connection end-to-end and will fail if an engine is stopped, even if it's set to auto-start. In order to start a stopped engine with auto-start enabled submit a query via `connection.execute`.

<a id="engine-url"></a>
### Engine URL
Expand Down
2 changes: 2 additions & 0 deletions src/connection/connection_v2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,8 @@ export class ConnectionV2 extends BaseConnection {
}

async testConnection() {
// Test the connection without starting the engine
// Will fail if the engine is stopped even with auto-start enabled
const settings = { internal: [{ auto_start_stop_control: "ignore" }] };
await this.execute("select 1", { settings });
}
Expand Down