db.go 816 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. package entity
  2. import (
  3. "app.yhyue.com/moapp/jybase/mysql"
  4. )
  5. var (
  6. Mysql *mysql.Mysql
  7. )
  8. // MysqlMainStruct msyql
  9. type MysqlMainStruct struct {
  10. DbName string `json:"dbName"`
  11. Address string `json:"address"`
  12. UserName string `json:"userName"`
  13. PassWord string `json:"passWord"`
  14. MaxOpenConns int `json:"maxOpenConns"`
  15. MaxIdleConns int `json:"maxIdleConns"`
  16. }
  17. // Mgo mgo
  18. type Mgo struct {
  19. DbName string `json:"dbName"`
  20. Address string `json:"address"`
  21. Size int `json:"size"`
  22. ReplSet string `json:"replSet"`
  23. }
  24. // RedisStruct redis
  25. type RedisStruct struct {
  26. Addr string `json:"addr"`
  27. Modules string `json:"modules"`
  28. }
  29. // EsStruct es
  30. type EsStruct struct {
  31. Addr string `json:"addr"`
  32. Size int `json:"size"`
  33. Index string `json:"index"`
  34. Type string `json:"type"`
  35. }