Documentation ¶
Index ¶
- Variables
- func Exit(ctx context.Context)
- func Exiting() bool
- func Init(ctx context.Context, cfg *xconfig.Config) context.Context
- func IsDebug() bool
- func NewPostgres(cfg *xconfig.Postgres, usePool bool) *pg.DB
- func OnExit(h hookFn)
- func OnExitSecondary(h hookFn)
- func OnInit(fn hookFn)
- func PGMain() *pg.DB
- func PGMainTx() *pg.DB
- func RateLimiter() *redis_rate.Limiter
- func RedisCache() *cache.Cache
- func RedisRing() *redis.Ring
- func Running() bool
- func Uptrace() *uptrace.Client
- func WaitExitSignal() os.Signal
Constants ¶
This section is empty.
Variables ¶
View Source
var ( WaitGroup sync.WaitGroup ExitCh = make(chan struct{}) )
View Source
var ( Config *xconfig.Config Ctx context.Context )
View Source
var ( Router *gin.Engine API *gin.RouterGroup )
View Source
var Clock = clock.New()
View Source
var (
Tracer = global.Tracer("github.com/uptrace/go-realworld-example-app")
)
Functions ¶
func NewPostgres ¶
func OnExitSecondary ¶
func OnExitSecondary(h hookFn)
func RateLimiter ¶
func RateLimiter() *redis_rate.Limiter
func RedisCache ¶
func RedisCache() *cache.Cache
func WaitExitSignal ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.