fix: add comprehensive logging to track startup hooks
- Added logging when HTTP server OnStart hook is called - Added error logging for database migration failures - This will help identify if hooks are being called and where failures occur
This commit is contained in:
@@ -6,14 +6,14 @@ import (
|
||||
"net/http"
|
||||
"time"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
"go.opentelemetry.io/contrib/instrumentation/github.com/gin-gonic/gin/otelgin"
|
||||
"go.opentelemetry.io/otel/trace"
|
||||
"git.dcentral.systems/toolz/goplt/internal/health"
|
||||
"git.dcentral.systems/toolz/goplt/internal/metrics"
|
||||
"git.dcentral.systems/toolz/goplt/pkg/config"
|
||||
"git.dcentral.systems/toolz/goplt/pkg/errorbus"
|
||||
"git.dcentral.systems/toolz/goplt/pkg/logger"
|
||||
"github.com/gin-gonic/gin"
|
||||
"go.opentelemetry.io/contrib/instrumentation/github.com/gin-gonic/gin/otelgin"
|
||||
"go.opentelemetry.io/otel/trace"
|
||||
)
|
||||
|
||||
// Server wraps the HTTP server and Gin router.
|
||||
@@ -149,4 +149,3 @@ func (s *Server) Shutdown(ctx context.Context) error {
|
||||
func (s *Server) Router() *gin.Engine {
|
||||
return s.router
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user