MCPcopy
hub / github.com/gofiber/fiber / mountStartupProcess

Method mountStartupProcess

mount.go:115–127  ·  view source on GitHub ↗

mountStartupProcess Handles the startup process of mounted apps by appending sub-app routes, generating app list keys, and processing sub-app routes.

()

Source from the content-addressed store, hash-verified

113
114// mountStartupProcess Handles the startup process of mounted apps by appending sub-app routes, generating app list keys, and processing sub-app routes.
115func (app *App) mountStartupProcess() {
116 if app.hasMountedApps() {
117 // add routes of sub-apps
118 app.mountFields.subAppsProcessed.Do(func() {
119 app.appendSubAppLists(app.mountFields.appList)
120 app.mountFields.appListKeysOnce.Do(app.generateAppListKeys)
121 })
122 // adds the routes of the sub-apps to the current application.
123 app.mountFields.subAppsRoutesAdded.Do(func() {
124 app.processSubAppsRoutes()
125 })
126 }
127}
128
129// generateAppListKeys generates app list keys for Render, should work after appendSubAppLists
130func (app *App) generateAppListKeys() {

Callers 1

startupProcessMethod · 0.95

Calls 4

hasMountedAppsMethod · 0.95
appendSubAppListsMethod · 0.95
processSubAppsRoutesMethod · 0.95
DoMethod · 0.65

Tested by

no test coverage detected