Skip to content

func RestFetchSpecs

Jihoon Seo edited this page Jul 29, 2020 · 6 revisions

Code file: https://github.com/cloud-barista/cb-tumblebug/blob/master/src/core/mcir/spec.go


Call chain:

  1. POST http://tb_ip:tb_port/tumblebug/ns/:nsId/resources/fetchSpecs (in api/rest/server/server.go)
  2. func RestFetchSpecs(c echo.Context) error (in api/rest/server/mcir/spec.go)
  3. func FetchSpecs(nsId string) (connConfigCount uint, specCount uint, err error) (in core/mcir/spec.go)

Usage: Please refer to fetch-specs.sh

ApiUsername=default
ApiPassword=default
AUTH="Authorization: Basic $(echo -n $ApiUsername:$ApiPassword | base64)"
curl -H "${AUTH}" -sX POST http://$TumblebugServer/tumblebug/ns/$NS_ID/resources/fetchSpecs | json_pp
Clone this wiki locally