[go-nuts] Re: SDK aws S3 Download to stdout

2016-06-30 Thread Joshua Boelter
If you want to use the s3manager Downloader to gain parallel/chunked downloads, you can use a temp buffer like so. The seek error your getting is because it's using a io.WriterAt interface for io and pipes can't seek when you chain commands together (at least that I know of). https://gist.gith

[go-nuts] Re: SDK aws S3 Download to stdout

2016-06-30 Thread Walter Garcia
Excellent , this work fine I attach the final sample code s3Svc := s3.New(session.New(&aws.Config{Region: aws.String("us-west-2")})) result, err := s3Svc.GetObject(&s3.GetObjectInput{ Bucket: aws.String(bucket), Key:aws.String(key),

[go-nuts] Re: SDK aws S3 Download to stdout

2016-06-30 Thread Walter Garcia
I had already tried this option but does not work this is the error Failed to download file write /dev/stdout: illegal seek Thanks in advance El jueves, 30 de junio de 2016, 0:55:49 (UTC-3), Dave Cheney escribió: > > numBytes, err := downloader.Download(os.Stdout, &s3.GetObjectInput{ ... }) > >

[go-nuts] Re: SDK aws S3 Download to stdout

2016-06-29 Thread Dave Cheney
numBytes, err := downloader.Download(os.Stdout, &s3.GetObjectInput{ ... }) Should do it. On Thursday, 30 June 2016 13:53:31 UTC+10, Joshua Boelter wrote: > > I've been tinkering w/ the AWS Go SDK to get used to it ... this is one > method using the GetObject API; see the full gist for a working

[go-nuts] Re: SDK aws S3 Download to stdout

2016-06-29 Thread Joshua Boelter
I've been tinkering w/ the AWS Go SDK to get used to it ... this is one method using the GetObject API; see the full gist for a working example https://gist.github.com/jboelter/6f5bd598673eb0e606f10660495fc175 s3Svc := s3.New(awsSession) result, err := s3Svc.GetObject(&s3.GetObjectInput{ Bucke