Skip to content

Commit 150ed59

Browse files
committedMar 26, 2014
Tag release v2.0.0-rc13
References: #158, #202, #215, #221, #224, #225, #226, #229, #230, #233, #237, #241, #242, #246, #248
1 parent 4850244 commit 150ed59

File tree

7 files changed

+30
-17
lines changed

7 files changed

+30
-17
lines changed
 

‎README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ Release notes can be found at http://aws.amazon.com/releasenotes/SDK/JavaScript
1212
To use the SDK in the browser, simply add the following script tag to your
1313
HTML pages:
1414

15-
<script src="https://sdk.amazonaws.com/js/aws-sdk-2.0.0-rc12.min.js"></script>
15+
<script src="https://sdk.amazonaws.com/js/aws-sdk-2.0.0-rc13.min.js"></script>
1616

1717
### In Node.js
1818

‎dist/aws-sdk.js

+21-8
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// AWS SDK for JavaScript v2.0.0-rc12
1+
// AWS SDK for JavaScript v2.0.0-rc13
22
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
33
// License at https://sdk.amazonaws.com/js/BUNDLE_LICENSE.txt
44
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
@@ -177,7 +177,7 @@ require('./util');
177177
AWS.util.update(AWS, {
178178

179179

180-
VERSION: '2.0.0-rc12',
180+
VERSION: '2.0.0-rc13',
181181

182182

183183
ServiceInterface: {},
@@ -497,6 +497,7 @@ AWS.EventListeners = {
497497
delete req.httpRequest.headers['X-Amz-Date'];
498498

499499
signer.addAuthorization(credentials, date);
500+
req.signedAt = date;
500501
} catch (e) {
501502
req.response.error = e;
502503
}
@@ -517,6 +518,8 @@ AWS.EventListeners = {
517518

518519
addAsync('SEND', 'send', function SEND(resp, done) {
519520
resp.httpResponse._abortCallback = done;
521+
resp.error = null;
522+
resp.data = null;
520523

521524
function callback(httpResp) {
522525
resp.httpResponse.stream = httpResp;
@@ -568,13 +571,23 @@ AWS.EventListeners = {
568571
});
569572
}
570573

571-
resp.error = null;
572-
resp.data = null;
574+
function executeSend() {
575+
var http = AWS.HttpClient.getInstance();
576+
var httpOptions = resp.request.service.config.httpOptions || {};
577+
var stream = http.handleRequest(resp.request.httpRequest, httpOptions,
578+
callback, error);
579+
progress(stream);
580+
}
573581

574-
var http = AWS.HttpClient.getInstance();
575-
var httpOptions = resp.request.service.config.httpOptions || {};
576-
var s = http.handleRequest(this.httpRequest, httpOptions, callback, error);
577-
progress(s);
582+
var timeDiff = (AWS.util.date.getDate() - this.signedAt) / 1000;
583+
if (timeDiff >= 60 * 10) { // if we signed 10min ago, re-sign
584+
this.emit('sign', [this], function(err) {
585+
if (err) done(err);
586+
else executeSend();
587+
});
588+
} else {
589+
executeSend();
590+
}
578591
});
579592

580593
add('HTTP_HEADERS', 'httpHeaders',

‎dist/aws-sdk.min.js

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎doc-src/guide/browser-examples.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ and authenticated with the correct credentials.
77

88
The common preamble code can be summarized as follows:
99

10-
<script src="https://sdk.amazonaws.com/js/aws-sdk-2.0.0-rc12.min.js"></script>
10+
<script src="https://sdk.amazonaws.com/js/aws-sdk-2.0.0-rc13.min.js"></script>
1111
<script type="text/javascript">
1212
// See the Configuring section to configure credentials in the SDK
1313
AWS.config.credentials = ...;

‎doc-src/guide/browser-intro.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ The quickest way to get started with the SDK is to load it using the hosted
88
package directly from Amazon Web Services. To do this, simply add the following
99
script tag to your HTML pages:
1010

11-
<script src="https://sdk.amazonaws.com/js/aws-sdk-2.0.0-rc12.min.js"></script>
11+
<script src="https://sdk.amazonaws.com/js/aws-sdk-2.0.0-rc13.min.js"></script>
1212

1313
You can also download this package by clicking the following link:
14-
[aws-sdk-2.0.0-rc12.min.js](https://sdk.amazonaws.com/js/aws-sdk-2.0.0-rc12.min.js)
14+
[aws-sdk-2.0.0-rc13.min.js](https://sdk.amazonaws.com/js/aws-sdk-2.0.0-rc13.min.js)
1515

1616
Once the SDK is loaded in your page, the module will be available from
1717
the global variable `AWS` (or `window.AWS`).

‎lib/core.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ AWS.util.update(AWS, {
1818
/**
1919
* @constant
2020
*/
21-
VERSION: '2.0.0-rc12',
21+
VERSION: '2.0.0-rc13',
2222

2323
/**
2424
* @api private

‎package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "aws-sdk",
33
"description": "AWS SDK for JavaScript",
4-
"version": "2.0.0-rc12",
4+
"version": "2.0.0-rc13",
55
"author": {
66
"name":"Amazon Web Services",
77
"email":"",

0 commit comments

Comments
 (0)
Please sign in to comment.