37

At GitHub we do not use foreign keys, ever, anywhere

 4 years ago
source link: https://github.com/github/gh-ost/issues/331
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

Hello,

Thanks for your hard work on gh-ost !

As I familiarize myself with the way it all works, I noted that foreign keys are explicitly not supported , but that they may be to some extent in the future.

Looking through issues in the repo, I also noted this expected feature that the table has neither foreign keys pointing to other tables, nor foreign keys pointing to it.

Could you please expand on your thoughs about foreign keys, and what you mean by “some extent” for their potential support? I am also curious: does this limitation mean that you don’t use foreign keys at all in GitHub’s MySQL databases, or do you use them and manage those tables somehow differently?

Thanks for your time and consideration!


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK