package
1.7.0
Repository: https://github.com/pilinux/gorest.git
Documentation: pkg.go.dev

# Packages

Package migrate to migrate the schema.
Package model contains all the models required for a functional database management system.

# Functions

GetDB - get a connection.
GetMongo - get a connection.
GetRedis - get a connection.
InitDB - function to initialize db.
InitMongo - function to initialize mongo client.
InitRedis - function to initialize redis client.
InitTLSMySQL registers a custom tls.Config Tutorial: How to configure MySQL instance and enable TLS support 1.0 generate CA's private key and certificate to omit password: `-nodes -keyout` `openssl req -x509 -sha512 -newkey rsa:4096 -days 10950 -keyout ca-key.pem -out ca.pem` 2.0 generate web server's private key and certificate signing request (CSR) to omit password: `-nodes -keyout` Common Name (e.g.
MongoCreateIndex - create one index for a mongo collection.
MongoCreateIndexes - create many indexes for a mongo collection.
MongoDropAllIndexes - drop all indexes from a mongo collection except the index on the _id field.
MongoDropIndex - drop one/multiple indexes from a mongo collection.

# Constants

RecordNotFound record not found error message.

# Variables

RedisConnTTL - context deadline in second.