MCPcopy Index your code
hub / github.com/feast-dev/feast / lifespan

Function lifespan

sdk/python/feast/feature_server.py:396–408  ·  view source on GitHub ↗
(app: FastAPI)

Source from the content-addressed store, hash-verified

394
395 @asynccontextmanager
396 async def lifespan(app: FastAPI):
397 # Load static artifacts before initializing store
398 await load_static_artifacts(app, store)
399
400 await store.initialize()
401 async_refresh()
402 try:
403 yield
404 finally:
405 stop_refresh()
406 if offline_batcher is not None:
407 offline_batcher.shutdown()
408 await store.close()
409
410 app = FastAPI(lifespan=lifespan)
411

Callers

nothing calls this directly

Calls 6

load_static_artifactsFunction · 0.85
stop_refreshFunction · 0.85
async_refreshFunction · 0.70
initializeMethod · 0.45
shutdownMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected