> For the complete documentation index, see [llms.txt](https://docs.cmsfullform.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cmsfullform.com/documents/drivers.md).

# Drivers

The **PHPFast** framework features a powerful and adaptable driver system that streamlines key functionalities such as database management, caching, and more. Designed for flexibility, these drivers abstract complex implementation details, enabling developers to seamlessly switch between different technologies or services without modifying the core application logic

## [**Cache Drivers**](https://docs.cmsfullform.com/documents/drivers/cache.md)

* Provide caching mechanisms to improve application performance.
* **Supported Cache Systems**: Redis, File-based caching, ...

```php
<?php
$cache = new RedisCache($config);
$cache->set('key', 'value', 600); // Cache for 10 minutes
$value = $cache->get('key');
```

* Store and retrieve cached data.
* Manage cache expiration and invalidation.
* Support for various caching strategies (e.g., in-memory, distributed).

## [**Database Drivers**](https://docs.cmsfullform.com/documents/drivers/database.md)

* Facilitate interactions with different database management systems (DBMS).
* **Supported Databases**: MySQL, PostgreSQL, SQLite, and more.

```php
?php
$configdb = config('db');
$dbConnection = loadDatabaseDriver($configdb['db_driver'], $configdb);
```

* Establish connections to the database.
* Execute queries and retrieve results.
* Handle transactions and ensure data integrity.

{% hint style="success" %}
Summary

The driver system in the **PHPFast** framework provides a powerful and flexible way to interact with various services and technologies. By abstracting the underlying implementation details, drivers allow developers to easily switch between different systems without changing the core application logic. This modular approach enhances the maintainability and scalability of the application, making it easier to integrate new technologies and optimize performance.
{% endhint %}


---

# 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.cmsfullform.com/documents/drivers.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.
