mirror of
https://github.com/documize/community.git
synced 2025-07-20 05:39:42 +02:00
send ready signal after HTTP server init
This commit is contained in:
parent
00c2d17fcb
commit
4b24cbc686
2 changed files with 3 additions and 1 deletions
|
@ -19,7 +19,6 @@ import (
|
|||
|
||||
// AttachStore selects database persistence layer
|
||||
func AttachStore(r *env.Runtime, s *domain.Store) {
|
||||
|
||||
switch r.DbVariant {
|
||||
case env.DbVariantMySQL, env.DBVariantPercona, env.DBVariantMariaDB:
|
||||
StoreMySQL(r, s)
|
||||
|
|
|
@ -85,6 +85,9 @@ func Start(rt *env.Runtime, s *domain.Store, ready chan struct{}) {
|
|||
n.Use(negroni.HandlerFunc(cm.metrics))
|
||||
n.UseHandler(router)
|
||||
|
||||
// tell caller we are ready to serve HTTP
|
||||
ready <- struct{}{}
|
||||
|
||||
// start server
|
||||
if !rt.Flags.SSLEnabled() {
|
||||
rt.Log.Info("Starting non-SSL server on " + rt.Flags.HTTPPort)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue