Skip to content

feat: Create provisioner abstraction #12

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 14 commits into from
Jan 8, 2022
Prev Previous commit
Next Next commit
Fix serve closed pipe
  • Loading branch information
kylecarbs committed Jan 7, 2022
commit fc6ca00ef9a78f7640aeaf1c9109212493aaceee
4 changes: 4 additions & 0 deletions provisionersdk/serve.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package provisionersdk
import (
"context"
"errors"
"io"

"golang.org/x/xerrors"
"storj.io/drpc"
Expand Down Expand Up @@ -42,6 +43,9 @@ func Serve(ctx context.Context, server proto.DRPCProvisionerServer, options *Ser
if errors.Is(err, context.Canceled) {
return nil
}
if errors.Is(err, io.ErrClosedPipe) {
return nil
}
return xerrors.Errorf("serve transport: %w", err)
}
return nil
Expand Down