MCPcopy
hub / github.com/containerd/containerd / CloseIO

Method CloseIO

client/process.go:196–212  ·  view source on GitHub ↗
(ctx context.Context, opts ...IOCloserOpts)

Source from the content-addressed store, hash-verified

194}
195
196func (p *process) CloseIO(ctx context.Context, opts ...IOCloserOpts) error {
197 ctx, span := tracing.StartSpan(ctx, "process.CloseIO",
198 tracing.WithAttribute("process.id", p.ID()),
199 )
200 defer span.End()
201 r := &tasks.CloseIORequest{
202 ContainerID: p.task.id,
203 ExecID: p.id,
204 }
205 var i IOCloseInfo
206 for _, o := range opts {
207 o(&i)
208 }
209 r.Stdin = i.Stdin
210 _, err := p.task.client.TaskService().CloseIO(ctx, r)
211 return errgrpc.ToNative(err)
212}
213
214func (p *process) IO() cio.IO {
215 return p.io

Callers

nothing calls this directly

Calls 6

IDMethod · 0.95
StartSpanFunction · 0.92
WithAttributeFunction · 0.92
EndMethod · 0.80
TaskServiceMethod · 0.80
CloseIOMethod · 0.65

Tested by

no test coverage detected