MCPcopy Create free account
hub / github.com/zalando/skipper / UpdateDoc

Method UpdateDoc

routing/testdataclient/dataclient.go:117–125  ·  view source on GitHub ↗

Updates the current set of routes with new/modified and deleted route definitions in eskip format. In case the parsing of the document fails, it returns an error.

(upsertDoc string, deletedIDs []string)

Source from the content-addressed store, hash-verified

115// route definitions in eskip format. In case the parsing of the
116// document fails, it returns an error.
117func (c *Client) UpdateDoc(upsertDoc string, deletedIDs []string) error {
118 routes, err := eskip.Parse(upsertDoc)
119 if err != nil {
120 return err
121 }
122
123 c.Update(routes, deletedIDs)
124 return nil
125}
126
127// Sets the Client to fail on the next call to LoadAll or LoadUpdate.
128// Repeated call to FailNext will result the Client to fail as many

Calls 2

UpdateMethod · 0.95
ParseFunction · 0.92