Returns the read-only provider if one is configured. Otherwise returns the first (read-write)
provider ONLY when options.allowFallbackToReadWrite is true, and null when it is omitted.
The read-only pool exists only when dbReadOnlyUsername/dbReadOnlyPassword are set, which
most deployments leave unset — so a caller that omits the flag gets null on those servers.
Pass it for any pure read.
Returns the read-only provider if one is configured. Otherwise returns the first (read-write) provider ONLY when
options.allowFallbackToReadWriteis true, andnullwhen it is omitted.The read-only pool exists only when
dbReadOnlyUsername/dbReadOnlyPasswordare set, which most deployments leave unset — so a caller that omits the flag getsnullon those servers. Pass it for any pure read.