Skip to content

wazho/mysql-health

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Installation

npm install mysql-health

Usage

TypeScript

import { healthCheckup } from 'mysql-health';

(async () => {
    const { isHealthy, error } = await healthCheckup({
        host: 'localhost',
        port: 3306,
        user: 'root',
        password: '',
    });

    // Successful case:
    //   true undefined
    // Error case:
    //   false 'Client does not support authentication protocol requested by server; consider upgrading MySQL client'
    console.log(isHealthy, error);
})();

Command line

npx mysql-health -h <host> -p <port> -u <user> -P <password>

About

MySQL connection health checking.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published