static register(db) {
        const cnKey = DatabasePool.createContextKey(db);
        npm.utils.addReadProp(db, '$cnKey', cnKey, true);
        const {dbMap, dbs} = DatabasePool.instance;
        if (cnKey in dbMap) {
            dbMap[cnKey]++;
            /* istanbul ignore if */
            if (!db.$config.options.noWarnings) {
                ColorConsole.warn(`WARNING: Creating a duplicate database object for the same connection.\n${npm.utils.getLocalStack(4, 3)}\n`);
            }
        } else {
            dbMap[cnKey] = 1;
        }
        dbs.push(db);
    }
@method DatabasePool.register
@static
@description
 - Registers each database object, to make sure no duplicates connections are used,
   and if they are, produce a warning;
 - Registers each Pool object, to be able to release them all when requested.

@param {Database} db - The new Database object being registered.