> [Globals](../globals) / PgPubSubOptions # Interface: PgPubSubOptions Options accepted as option argument of PgPubSub constructor. It extends `pg.ClientConfig` options, mostly because it is used to construct PostgreSQL database connection, adding more properties required to configure PgBubSub objects behavior. ## Hierarchy * ClientConfig ↳ **PgPubSubOptions** ## Index ### Properties * [acquireInterval](PgPubSubOptions#acquireinterval) * [application\_name](PgPubSubOptions#application_name) * [connectionString](PgPubSubOptions#connectionstring) * [connectionTimeoutMillis](PgPubSubOptions#connectiontimeoutmillis) * [database](PgPubSubOptions#database) * [filtered](PgPubSubOptions#filtered) * [host](PgPubSubOptions#host) * [idle\_in\_transaction\_session\_timeout](PgPubSubOptions#idle_in_transaction_session_timeout) * [keepAlive](PgPubSubOptions#keepalive) * [keepAliveInitialDelayMillis](PgPubSubOptions#keepaliveinitialdelaymillis) * [parseInputDatesAsUTC](PgPubSubOptions#parseinputdatesasutc) * [password](PgPubSubOptions#password) * [pgClient](PgPubSubOptions#pgclient) * [port](PgPubSubOptions#port) * [query\_timeout](PgPubSubOptions#query_timeout) * [retryDelay](PgPubSubOptions#retrydelay) * [retryLimit](PgPubSubOptions#retrylimit) * [singleListener](PgPubSubOptions#singlelistener) * [ssl](PgPubSubOptions#ssl) * [statement\_timeout](PgPubSubOptions#statement_timeout) * [stream](PgPubSubOptions#stream) * [user](PgPubSubOptions#user) ## Properties ### acquireInterval • **acquireInterval**: number Time interval in milliseconds before `LISTEN` clients would re-try to acquire channel locks. It works from one hand as connection keep-alive periodical pings, from other hand adds additional level of reliability for the cases when connection, which holds the lock has been suddenly disconnected in a silent manner. By default is set to `30000ms` (`30sec`). Please, assume this value should be selected for a particular system with care of often acquire lock hits and overall infrastructure reliability. ___ ### application\_name • `Optional` **application\_name**: undefined \| string *Inherited from [PgPubSubOptions](PgPubSubOptions).[application_name](PgPubSubOptions.md#application_name)* ___ ### connectionString • `Optional` **connectionString**: undefined \| string *Inherited from [PgPubSubOptions](PgPubSubOptions).[connectionString](PgPubSubOptions.md#connectionstring)* ___ ### connectionTimeoutMillis • `Optional` **connectionTimeoutMillis**: undefined \| number *Inherited from [PgPubSubOptions](PgPubSubOptions).[connectionTimeoutMillis](PgPubSubOptions.md#connectiontimeoutmillis)* ___ ### database • `Optional` **database**: undefined \| string *Inherited from [PgPubSubOptions](PgPubSubOptions).[database](PgPubSubOptions.md#database)* ___ ### filtered • **filtered**: boolean If set to true, self emitted messages (those which were sent using `NOTIFY` on the same connection) will be filtered on this connection. By default is false - means that connection will `LISTEN` to the messages, which were notified on the same connection. ___ ### host • `Optional` **host**: undefined \| string *Inherited from [PgPubSubOptions](PgPubSubOptions).[host](PgPubSubOptions.md#host)* ___ ### idle\_in\_transaction\_session\_timeout • `Optional` **idle\_in\_transaction\_session\_timeout**: undefined \| number *Inherited from [PgPubSubOptions](PgPubSubOptions).[idle_in_transaction_session_timeout](PgPubSubOptions.md#idle_in_transaction_session_timeout)* ___ ### keepAlive • `Optional` **keepAlive**: undefined \| false \| true *Inherited from [PgPubSubOptions](PgPubSubOptions).[keepAlive](PgPubSubOptions.md#keepalive)* ___ ### keepAliveInitialDelayMillis • `Optional` **keepAliveInitialDelayMillis**: undefined \| number *Inherited from [PgPubSubOptions](PgPubSubOptions).[keepAliveInitialDelayMillis](PgPubSubOptions.md#keepaliveinitialdelaymillis)* ___ ### parseInputDatesAsUTC • `Optional` **parseInputDatesAsUTC**: undefined \| false \| true *Inherited from [PgPubSubOptions](PgPubSubOptions).[parseInputDatesAsUTC](PgPubSubOptions.md#parseinputdatesasutc)* ___ ### password • `Optional` **password**: string \| () => string \| Promise\ *Inherited from [PgPubSubOptions](PgPubSubOptions).[password](PgPubSubOptions.md#password)* ___ ### pgClient • `Optional` **pgClient**: Client Existing PostgreSQL client connection (optional). Can be passed if there is a need to re-use existing db connection from external code. Otherwise it is required to bypass correct options to instantiate new `pg.Client` connection properly. ___ ### port • `Optional` **port**: undefined \| number *Inherited from [PgPubSubOptions](PgPubSubOptions).[port](PgPubSubOptions.md#port)* ___ ### query\_timeout • `Optional` **query\_timeout**: undefined \| number *Inherited from [PgPubSubOptions](PgPubSubOptions).[query_timeout](PgPubSubOptions.md#query_timeout)* ___ ### retryDelay • **retryDelay**: number Specifies delay in milliseconds between re-connection retries ___ ### retryLimit • **retryLimit**: number Specifies maximum number of re-connection retries to process, before connection would be treated as broken (disconnected). By default is set to infinite number of retries. ___ ### singleListener • **singleListener**: boolean Boolean flag, which turns off/on single listener mode. By default is set to true, so instantiated PgPubSub connections will act using inter-process locking mechanism. ___ ### ssl • `Optional` **ssl**: boolean \| ConnectionOptions *Inherited from [PgPubSubOptions](PgPubSubOptions).[ssl](PgPubSubOptions.md#ssl)* ___ ### statement\_timeout • `Optional` **statement\_timeout**: false \| number *Inherited from [PgPubSubOptions](PgPubSubOptions).[statement_timeout](PgPubSubOptions.md#statement_timeout)* ___ ### stream • `Optional` **stream**: stream.Duplex *Inherited from [PgPubSubOptions](PgPubSubOptions).[stream](PgPubSubOptions.md#stream)* ___ ### user • `Optional` **user**: undefined \| string *Inherited from [PgPubSubOptions](PgPubSubOptions).[user](PgPubSubOptions.md#user)*