((bucketName != null) ? bucketName + "/" : "") +
((key != null) ? HttpUtils.urlEncode(key, true) : "") +
((subResource != null) ? "?" + subResource : "");
AWSCredentials credentials = awsCredentialsProvider.getCredentials();
AmazonWebServiceRequest originalRequest = request.getOriginalRequest();
if (originalRequest != null && originalRequest.getRequestCredentials() != null) {
credentials = originalRequest.getRequestCredentials();
}
new S3QueryStringSigner<T>(methodName.toString(), resourcePath, expiration).sign(request, credentials);
// The Amazon S3 DevPay token header is a special exception and can be safely moved