You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@guacamole.apache.org by GitBox <gi...@apache.org> on 2020/10/13 22:13:19 UTC

[GitHub] [guacamole-client] mike-jumper commented on a change in pull request #460: GUACAMOLE-760: Add support for configuring server timezone.

mike-jumper commented on a change in pull request #460:
URL: https://github.com/apache/guacamole-client/pull/460#discussion_r504288294



##########
File path: extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-mysql/src/main/java/org/apache/guacamole/auth/mysql/MySQLAuthenticationProviderModule.java
##########
@@ -82,6 +83,11 @@ public MySQLAuthenticationProviderModule(MySQLEnvironment environment)
         // Get the MySQL-compatible driver to use.
         mysqlDriver = environment.getMySQLDriver();
 
+        // If timezone is present, set it.
+        TimeZone serverTz = environment.getServerTimeZone();
+        if (serverTz != null)
+            driverProperties.setProperty("serverTimezone", serverTz.toString());

Review comment:
       Is it known that the `toString()` function of Java's `TimeZone` produces a string acceptable by the `serverTimezone` property of the MySQL/MariaDB driver?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org