use of com.amazonaws.services.kinesisvideo.model.TagStreamRequest in project aws-sdk-android by aws-amplify.
the class KinesisVideoAndroidServiceClient method tagStream.
@Override
public void tagStream(@NonNull final String streamArn, @Nullable final Map<String, String> tags, long timeoutInMillis, @Nullable final KinesisVideoCredentialsProvider credentialsProvider) throws KinesisVideoException {
final AWSKinesisVideoClient serviceClient = createAwsKinesisVideoClient(credentialsProvider, Region.getRegion(Regions.fromName(configuration.getRegion())), configuration.getEndpoint(), (int) timeoutInMillis);
final TagStreamRequest tagStreamRequest = new TagStreamRequest().withStreamARN(streamArn).withTags(tags);
log.debug("calling tag resource: " + tagStreamRequest.toString());
final TagStreamResult tagStreamResult;
try {
tagStreamResult = serviceClient.tagStream(tagStreamRequest);
} catch (final AmazonClientException e) {
log.exception(e, "Service call failed.");
throw new KinesisVideoException(e);
}
log.debug("tag resource result: " + tagStreamResult.toString());
}
Aggregations