gateway: add cap to detect metadata support

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
(cherry picked from commit de5af7d6c2)
v0.7
Tonis Tiigi 2020-04-17 16:18:47 -07:00
parent 45fe809cff
commit c158b8178d
1 changed files with 10 additions and 0 deletions

View File

@ -32,6 +32,9 @@ const (
// CapFrontendInputs is a capability to request frontend inputs from the
// LLBBridge GRPC server.
CapFrontendInputs apicaps.CapID = "frontend.inputs"
// CapGatewaySolveMetadata can be used to check if solve calls from gateway reliably return metadata
CapGatewaySolveMetadata apicaps.CapID = "gateway.solve.metadata"
)
func init() {
@ -126,4 +129,11 @@ func init() {
Enabled: true,
Status: apicaps.CapStatusExperimental,
})
Caps.Init(apicaps.Cap{
ID: CapGatewaySolveMetadata,
Name: "gateway metadata",
Enabled: true,
Status: apicaps.CapStatusExperimental,
})
}