---
title: "danog\\AsyncOrm\\Settings\\PostgresSettings: Postgres backend settings."
description: ""

---
# `danog\AsyncOrm\Settings\PostgresSettings`
[Back to index](../../../index.md)

> Author: Daniil Gentili <daniil@daniil.it>  
> Author: Alexander Pankratov <alexander@i-c-a.su>  
  

Postgres backend settings.  




## Constants
* `danog\AsyncOrm\Settings\PostgresSettings::DEFAULT_SQL_MAX_CONNECTIONS`: 

* `danog\AsyncOrm\Settings\PostgresSettings::DEFAULT_SQL_IDLE_TIMEOUT`: 

* `danog\AsyncOrm\Settings\PostgresSettings::DEFAULT_CACHE_TTL`: 

## Properties
* `$maxConnections`: `positive-int` Maximum connection limit.
* `$idleTimeout`: `positive-int` Idle timeout.
* `$config`: `T` 
* `$serializer`: `danog\AsyncOrm\Serializer` 
* `$cacheTtl`: `int<0, max>` For how long to keep records in memory after last read.

## Method list:
* [`__construct(\Amp\Postgres\PostgresConfig $config, ?\danog\AsyncOrm\Serializer $serializer = NULL, int<0, max> $cacheTtl = \self::DEFAULT_CACHE_TTL, int<1, max> $maxConnections = \self::DEFAULT_SQL_MAX_CONNECTIONS, int<1, max> $idleTimeout = \self::DEFAULT_SQL_IDLE_TIMEOUT)`](#__construct)
* [`getDriverClass(): string`](#getDriverClass)

## Methods:
### <a name="__construct"></a> `__construct(\Amp\Postgres\PostgresConfig $config, ?\danog\AsyncOrm\Serializer $serializer = NULL, int<0, max> $cacheTtl = \self::DEFAULT_CACHE_TTL, int<1, max> $maxConnections = \self::DEFAULT_SQL_MAX_CONNECTIONS, int<1, max> $idleTimeout = \self::DEFAULT_SQL_IDLE_TIMEOUT)`




Parameters:

* `$config`: `\Amp\Postgres\PostgresConfig`   
* `$serializer`: `?\danog\AsyncOrm\Serializer` to use for object and mixed type values, if null defaults to either Igbinary or Native.  
* `$cacheTtl`: `int<0, max>` Cache TTL in seconds  
* `$maxConnections`: `int<1, max>` Maximum connection limit  
* `$idleTimeout`: `int<1, max>` Idle timeout  


#### See also: 
* `\Amp\Postgres\PostgresConfig`
* [`\danog\AsyncOrm\Serializer`: Serializer interface.](../../../danog/AsyncOrm/Serializer.md)
* `max`




### <a name="getDriverClass"></a> `getDriverClass(): string`





---
Generated by [danog/phpdoc](https://phpdoc.daniil.it)
