GitHub user dosubot[bot] added a comment to the discussion: DB connection issue

<!-- Answer -->
To address the issue where the database connection only succeeds on the third 
attempt, you can adjust the retry settings in Superset. Superset uses a 
configuration setting called `fetchRetryOptions` to handle connection retries. 
By default, it retries the connection three times. You can modify this setting 
to change the number of retry attempts.

To do this, you can set the `retries` option in `fetchRetryOptions` to a 
different value, such as 0, to disable retries, or adjust it to a number that 
suits your needs. Here's an example of how you might configure it:

```ts
await callApi({
  fetchRetryOptions: { retries: 0 }, // Set to 0 to disable retries
  url: mockErrorUrl,
  method: 'GET',
});
```

Additionally, ensure that the database driver is correctly installed, as the 
error message suggests. You can refer to the Superset documentation for 
guidance on installing the necessary drivers for your specific database 
<sup>[[1]](https://github.com/apache/superset/blob/master/superset-frontend/packages/superset-ui-core/test/connection/callApi/callApi.test.ts)</sup>.


<!-- Dosu Comment Footer -->
*To continue talking to [Dosu](https://dosu.dev), mention @dosu.*

---
<sup>Help Dosu learn! Give it feedback: [Great 
Response](https://app.dosu.dev/response-feedback/098d1bfa-9a0f-42a2-8869-8563776481e4?feedback_type=great_response)
 | [Irrelevant 
Answer](https://app.dosu.dev/response-feedback/098d1bfa-9a0f-42a2-8869-8563776481e4?feedback_type=irrelevant_answer)
 | [Incorrect 
Sources](https://app.dosu.dev/response-feedback/098d1bfa-9a0f-42a2-8869-8563776481e4?feedback_type=incorrect_sources)
 | [Too 
Verbose](https://app.dosu.dev/response-feedback/098d1bfa-9a0f-42a2-8869-8563776481e4?feedback_type=too_verbose)
 | 
[Hallucination](https://app.dosu.dev/response-feedback/098d1bfa-9a0f-42a2-8869-8563776481e4?feedback_type=hallucination)
 | [Bug 
Report](https://app.dosu.dev/response-feedback/098d1bfa-9a0f-42a2-8869-8563776481e4?feedback_type=bug_report)
 | 
[Other](https://app.dosu.dev/response-feedback/098d1bfa-9a0f-42a2-8869-8563776481e4?feedback_type=other)</sup>


GitHub link: 
https://github.com/apache/superset/discussions/32998#discussioncomment-12721394

----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: 
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to