Skip to content

Commit 184dca3

Browse files
committed
fix: incorrect use of host instead of host_and_port
1 parent 9371ea8 commit 184dca3

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

aws_advanced_python_wrapper/failover_plugin.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -325,12 +325,12 @@ def _failover_writer(self):
325325

326326
writer_host = self._get_writer(result.topology)
327327
allowed_hosts = self._plugin_service.hosts
328-
allowed_hostnames = [host.host for host in allowed_hosts]
328+
allowed_hostnames = [host.get_host_and_port() for host in allowed_hosts]
329329
if writer_host.get_host_and_port() not in allowed_hostnames:
330330
raise FailoverFailedError(
331331
Messages.get_formatted(
332332
"FailoverPlugin.NewWriterNotAllowed",
333-
"<null>" if writer_host is None else writer_host.host,
333+
"<null>" if writer_host is None else writer_host.get_host_and_port(),
334334
LogUtils.log_topology(allowed_hosts)))
335335

336336
self._plugin_service.set_current_connection(result.new_connection, writer_host)

0 commit comments

Comments
 (0)