Now if only one host is in connection string and it ask for read_write connection(connect to master) I mean read_only is set 0 explicitly. With above logic we will allow it to connect to standby?. I still think psql connection to standby should be handled by changing the default value of readonly to 1 (which means connect to any). Thinking further probably replacing readonly parameter with targetServerType=any|master (with default being any) should clear some confusions and bring consistency since same is used in JDBC multi host connection string.