planetscale / planetscale/vitess-operator

Feature Request: Provide for a way to populate time zone tables

Open
#697 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
372
Forks
102
Avg merge
3d 5h
Merged PRs (30d)
15

Description

Problem:
This returns null after cluster creation: SELECT CONVERT_TZ(NOW(), '+00:00', 'UTC');

So usually I would fix it by running this: mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root -p mysql but there is no way to do this in the vitess operator. I think it would have to run after mysql_install_db and before init_db.sql

Goal:
I would like to be able to put default-time-zone='UTC' into my [mysqld] configOverrides, not just default_time_zone = '+00:00'

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing how the operator processes mysqld configOverrides and the initialization sequence around mysql_install_db and init_db.sql. Check how mysql_tzinfo_to_sql could populate the time zone tables before init_db.sql runs, and verify completion with CONVERT_TZ(NOW(), '+00:00', 'UTC') when default-time-zone='UTC' is configured.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, kubernetes, mysql
Domain
database, infrastructure
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.