summaryrefslogtreecommitdiffstats
path: root/heartbeat.cgi
diff options
context:
space:
mode:
authorDylan William Hardison <dylan@hardison.net>2018-08-04 18:24:15 +0200
committerDylan William Hardison <dylan@hardison.net>2018-08-04 18:24:15 +0200
commitf44392e8cdbea85ac308b2472f813ee605ebae4b (patch)
tree6e7adaf99a0e5a43eb1bf5a0d673d86b60f34f99 /heartbeat.cgi
parent5be3a7fd0061aa0bc3059e09079741873b9b833f (diff)
parent4528b21bc922f8b1e0ba8581d230a492aa43c9cf (diff)
downloadbugzilla-f44392e8cdbea85ac308b2472f813ee605ebae4b.tar.gz
bugzilla-f44392e8cdbea85ac308b2472f813ee605ebae4b.tar.xz
Merge branch 'mojo-poc'
Diffstat (limited to 'heartbeat.cgi')
-rwxr-xr-xheartbeat.cgi9
1 files changed, 9 insertions, 0 deletions
diff --git a/heartbeat.cgi b/heartbeat.cgi
index 773673697..11bb3ac30 100755
--- a/heartbeat.cgi
+++ b/heartbeat.cgi
@@ -29,6 +29,15 @@ my $ok = eval {
die "database not available" unless $database_ok;
die "memcached server(s) not available" unless $memcached_ok;
+ if ($dbh->isa('Bugzilla::DB::Mysql') && Bugzilla->params->{utf8} eq 'utf8mb4') {
+ my $mysql_var = $dbh->selectall_hashref(q{SHOW VARIABLES LIKE 'character_set%'}, 'Variable_name');
+ foreach my $name (qw( character_set_client character_set_connection character_set_database )) {
+ my $value = $mysql_var->{$name}{Value};
+ if ($value ne 'utf8mb4') {
+ die "Expected MySQL variable '$name' to be 'utf8mb4', found '$value'";
+ }
+ }
+ }
1;
};
FATAL("heartbeat error: $@") if !$ok && $@;