MCPcopy Create free account
hub / github.com/baidu/EasyFaaS / GetResourceHandler

Method GetResourceHandler

pkg/controller/handler.go:143–151  ·  view source on GitHub ↗
(c *routing.Context)

Source from the content-addressed store, hash-verified

141}
142
143func (controller *Controller) GetResourceHandler(c *routing.Context) error {
144 resource := controller.runtimeDispatcher.ResourceStatistics()
145 body, err := json.Marshal(resource)
146 if err != nil {
147 return err
148 }
149 c.Response.SetBody(body)
150 return nil
151}
152
153func (controller *Controller) InvalidateRuntime(c *routing.Context) error {
154 runtimeID := c.Param("runtimeID")

Callers

nothing calls this directly

Calls 3

MarshalFunction · 0.92
ResourceStatisticsMethod · 0.65
SetBodyMethod · 0.45

Tested by

no test coverage detected