MariaDB & MySQL Database Mechanic
Performing MRO operations efficiently
Abstract

Abstract

Though most of us know the importance of clean DB standards, at the same time all have our own variances in implementing it. Especially for small teams with multi-role developers, it's a challenge to keep track of it.

In spite of paying high prices for ignoring DB standards, we had continuous challenges in following best practices in high development times. Practices like inconsistent naming, varied field sizes for the same purpose, ignoring relation setups, ignoring proper indexes, varied char set & collations, unjustified default values & null cases and a few more continued for a long time and it become a habit. The primary challenge that we observed is our laziness to do the manual repetitive stuff, ignoring the best practices in tight timelines. Also, the absence of documentation and manual processes stopped the juniors from carrying it out.

To overcome these challenges, we developed a repair tool that automates repetitive actions through configuration. This tool handles tasks ranging from simple field size alterations to complex trigger query creation, catering to every requirement. For every need, an action performer module was implemented to take inputs from a CSV file. The CSV based implementation helped in smoother execution and also served as a documentation to make test automation.

Now we are able to do MRO operations in DB effectively. Earlier the code was highly coupled with our internal library. Now we made it a separate app and planned to make it open to serve similar needs.

In this talk, I will share the use cases with hands-on-usage.

CSV Inputs


Naming & Sizing
Relation & Indexing
Extendable & Automatable
 

Talk

 

  • Good & Bad DB Practices

    • Initial usages
    • Real Time Challenges

  • Corrective Actions

    • Set Field Size & Default Values
    • Set Engine, Char & Collations
    • Set Index, Relations
    • Set & Unset actions
  • Benefits

    • Automated QA tests
    • Serves as a document/li>
    • Template based query generation
    • Rule Analyzer

  • MyCamel

    A Perl Ride