Documentation ¶
Index ¶
- Variables
- func CreateConnectionString(username string, password string, hostname string, port string, ...) string
- func CreateGormContext(username string, password string, hostname string, port string, ...) (*gorm.DB, error)
- func EnsureDatabaseExists(username string, password string, hostname string, port string, ...) error
- type ServiceConfig
- type Timestamp
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrorServiceMissingParameter used when one or more parameters are missing ErrorServiceMissingParameter = errors.New("Parameter is missing") // ErrorServiceUserNotActive used when a user does not exist ErrorServiceUserNotActive = errors.New("User not active") // ErrorServiceNoSuchFlight no such flight exists ErrorServiceNoSuchFlight = errors.New("No such flight") // ErrorServiceNoSuchLocation when the location does not exist ErrorServiceNoSuchLocation = errors.New("No such location") // ErrorServiceBadCoordinates when coordinates are wrong ErrorServiceBadCoordinates = errors.New("Invalid coordinate set") ErrorServiceBadDirectionSet = errors.New("The given wind directions are not valid") )
Functions ¶
func CreateConnectionString ¶
func CreateConnectionString(username string, password string, hostname string, port string, database string) string
CreateConnectionString creates a MySql / MariaDB connection string from parameters hostname and database can be empty strings
func CreateGormContext ¶
Types ¶
type ServiceConfig ¶
ServiceConfig describes service wide config parameters
func (*ServiceConfig) IsDevMode ¶
func (s *ServiceConfig) IsDevMode() bool
IsDevMode returns true if application is in devmode
Click to show internal directories.
Click to hide internal directories.