MCPcopy
hub / github.com/argoproj/argo-workflows / Load

Method Load

workflow/artifacts/plugin/plugin.go:140–153  ·  view source on GitHub ↗

Load implements ArtifactDriver.Load by calling the plugin service

(ctx context.Context, inputArtifact *wfv1.Artifact, path string)

Source from the content-addressed store, hash-verified

138
139// Load implements ArtifactDriver.Load by calling the plugin service
140func (d *Driver) Load(ctx context.Context, inputArtifact *wfv1.Artifact, path string) error {
141 grpcArtifact := convertToGRPC(inputArtifact)
142 resp, err := d.client.Load(ctx, &artifact.LoadArtifactRequest{
143 InputArtifact: grpcArtifact,
144 Path: path,
145 })
146 if err != nil {
147 return fmt.Errorf("plugin %s load failed: %w", d.pluginName, err)
148 }
149 if !resp.Success {
150 return fmt.Errorf("plugin %s load failed: %s", d.pluginName, resp.Error)
151 }
152 return nil
153}
154
155// OpenStream implements ArtifactDriver.OpenStream by calling the plugin service
156func (d *Driver) OpenStream(ctx context.Context, a *wfv1.Artifact) (io.ReadCloser, error) {

Callers

nothing calls this directly

Calls 2

convertToGRPCFunction · 0.85
LoadMethod · 0.65

Tested by

no test coverage detected