Skip to content

Commit

Permalink
StorageLoader: added tcpKeepAlive=true to JDBC for long-running COPYs…
Browse files Browse the repository at this point in the history
… via NAT (closes #2145)
  • Loading branch information
alexanderdean authored and fblundun committed Nov 26, 2015
1 parent d571843 commit 358a71b
Showing 1 changed file with 1 addition and 0 deletions.
Expand Up @@ -178,6 +178,7 @@ def self.get_connection(target)
props.set_property :user, target[:username]
props.set_property :password, target[:password]
props.set_property :sslmode, target.fetch(:ssl_mode, "disable")
props.set_property :tcpKeepAlive, "true" # TODO: make this configurable if any adverse effects

# Used instead of Java::JavaSql::DriverManager.getConnection to prevent "no suitable driver found" error
org.postgresql.Driver.new.connect(connection_url, props)
Expand Down

0 comments on commit 358a71b

Please sign in to comment.