| 1 | # Example |
| 2 | |
| 3 | This is an example demonstrates how you can use the AWS Elemental MediaStore |
| 4 | API PutObject operation with a non-seekable io.Reader. |
| 5 | |
| 6 | # Usage |
| 7 | |
| 8 | The example will create an Elemental MediaStore container, and upload a |
| 9 | contrived non-seekable io.Reader to that container. Using the SDK's |
| 10 | [aws.ReadSeekCloser](https://docs.aws.amazon.com/sdk-for-go/api/aws/#ReadSeekCloser) |
| 11 | utility for wrapping the `io.Reader` in a value the |
| 12 | [mediastore#PutObjectInput](https://docs.aws.amazon.com/sdk-for-go/api/service/mediastoredata/#PutObjectInput).Body will accept. |
| 13 | |
| 14 | The example will attempt to create the container if it does not already exist. |
| 15 | |
| 16 | ```sh |
| 17 | AWS_REGION=<region> go run -tags example main.go <containerName> <object-path> |