MCPcopy Create free account
hub / github.com/porsager/postgres / tryNext

Function tryNext

cf/src/connection.js:792–800  ·  view source on GitHub ↗
(x, xs)

Source from the content-addressed store, hash-verified

790 }
791
792 function tryNext(x, xs) {
793 return (
794 (x === 'read-write' && xs.default_transaction_read_only === 'on') ||
795 (x === 'read-only' && xs.default_transaction_read_only === 'off') ||
796 (x === 'primary' && xs.in_hot_standby === 'on') ||
797 (x === 'standby' && xs.in_hot_standby === 'off') ||
798 (x === 'prefer-standby' && xs.in_hot_standby === 'off' && options.host[retries])
799 )
800 }
801
802 function fetchState() {
803 const query = new Query([`

Callers 1

ReadyForQueryFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected