MCPcopy Create free account
hub / github.com/bep/s3deploy / pathsToInvalidationBatch

Method pathsToInvalidationBatch

lib/cloudfront.go:116–129  ·  view source on GitHub ↗
(ref string, paths ...string)

Source from the content-addressed store, hash-verified

114}
115
116func (*cloudFrontClient) pathsToInvalidationBatch(ref string, paths ...string) *types.InvalidationBatch {
117 cfpaths := &types.Paths{}
118 for _, p := range paths {
119 cfpaths.Items = append(cfpaths.Items, pathEscapeRFC1738(p))
120 }
121
122 qty := int32(len(paths))
123 cfpaths.Quantity = &qty
124
125 return &types.InvalidationBatch{
126 CallerReference: &ref,
127 Paths: cfpaths,
128 }
129}
130
131// determineRootAndSubPath takes the bucketPath, as set as a flag,
132// and the originPath, as set in the CDN config, and

Callers 2

InvalidateCDNCacheMethod · 0.95

Calls 1

pathEscapeRFC1738Function · 0.85

Tested by 1