MCPcopy Create free account
hub / github.com/cool-sun/cloudApp / init

Function init

controller/artifacthub.go:35–38  ·  view source on GitHub ↗

1.先把所有静态文件路径加载到数组中,避免每次收到请求都要进行io操作 2.这样做能提升性能,但是也存在问题,如果在程序运行中修改了静态文件资源,程序一定要重启才能生效 3.为了避免重启,可以定时执行1步骤

()

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers

nothing calls this directly

Calls 2

GetAllFilesFunction · 0.92
loadFilePathArrFunction · 0.85

Tested by

no test coverage detected