> For the complete documentation index, see [llms.txt](https://docs.rierino.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.rierino.com/devops/microservices/building-blocks/query-and-search-sources.md).

# Query & Search Sources

Query managers are used for querying data from an underlying data store such as a SQL database

Connection details for query managers are defined using system elements, which allows defining them once and reusing them across different state and query elements.

Query managers connect to a specific system, translate Rierino query format to query statements in that system's domain specific language and return results in JSON form. Typically, a separate query manager is defined for each database.

It is possible to define any number and type of new query managers with specialized configurations, and typical managers deployed with Rierino are described in this section. A number of settings are shared across all query manager types:

| Setting           | Definition                                                                                                      | Example                                     | Default                        |
| ----------------- | --------------------------------------------------------------------------------------------------------------- | ------------------------------------------- | ------------------------------ |
| manager           | Fully qualified class name for the query manager                                                                | com.rierino.query.manager.MongoQueryManager | -                              |
| retriesPerStep    | Allowed number of retries at each backoff step during reconnect                                                 | 3                                           | 1                              |
| backoffSteps      | Comma separated list of milliseconds to wait between backoff steps                                              | 10,20,30                                    | 10,100,200,500,1000,1000,10000 |
| logDetail         | Whether detailed trace logs should be performed (always[^1]/never[^2]) independent of the current logging level | never                                       | -                              |
| telemetry.enabled | Whether handler should produce OpenTelemetry  traces & metrics                                                  | false                                       | true                           |

{% file src="/files/bWdAENTKrRG12uFu6Sql" %}
Example Query Manager Definition (Can be Imported on Element Screen)
{% endfile %}

[^1]: Typically used for debugged managers

[^2]: Typically used for sensitive managers &#x20;


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.rierino.com/devops/microservices/building-blocks/query-and-search-sources.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
