UNPKG

32.2 kBMarkdownView Raw
1# Release History
2
3## 3.14.1 (2021-09-02)
4
5### Bugs Fixed
6
7- Fix @azure/core-rest-pipeline version for AAD auth.
8
9## 3.14.0 (2021-09-01)
10
11### Features Added
12
13- _PREVIEW_ Adds `container.item(itemId).patch()`. `patch()` is an alternative to `replace()` for item updates. https://github.com/Azure/azure-sdk-for-js/pull/16264/files#diff-7caca690c469e2025576523c0377ac71815f001024fde7c48b20cd24adaa6977R561
14- _PREVIEW_ Adds support for Bulk operation PATCH.
15- _PREVIEW_ Adds support for Batch operation PATCH.
16
17### Bugs Fixed
18
19- Fixes bug where Batch was passing the wrong header for batch requests with partition keys
20- Fixes 401s when using AAD auth. AAD credentials should now work and no longer cause 429s from @azure/identity at high throughput.
21
22## 3.13.1 (2021-08-23)
23
24### Bugs Fixed
25
26- Fixed bugs in session token clearing logic. Session Not found (404, substatus 1002) was not being handled correctly by the session retry policy and would mistakenly retry the request with the same session token.
27
28## 3.13.0 (2021-08-10)
29
30### Features Added
31
32- Adds TransactionalBatch to items `container.items.batch(operations)`
33
34### Bugs Fixed
35
36- Fixed bulk requests which had operations without partitionKey specified.
37
38## 3.12.3 (2021-07-23)
39
40### Bugs Fixed
41
42- Fix bulk operations on containers with multiple partitions with nested partition keys
43
44## 3.12.2 (2021-07-21)
45
46### Features Added
47
48- Adopted target ES2017 to reduce bundle size.
49
50## 3.12.1 (2021-07-16)
51
52### Bugs Fixed
53
54- Returned default retryPolicy option `fixedRetryIntervalInMilliseconds` to its original default 0.
55
56## 3.12.0 (2021-07-06)
57
58### Features Added
59
60- With the dropping of support for Node.js versions that are no longer in LTS, the dependency on `@types/node` has been updated to version 12. Read our [support policy](https://github.com/Azure/azure-sdk-for-js/blob/main/SUPPORT.md) for more details.
61- Added background refresher for endpoints, and new `ConnectionPolicy` options. Refreshing defaults to true, and the default refresh rate is every 5 minutes.
62
63```js
64const client = new CosmosClient({
65 endpoint,
66 key: masterKey,
67 connectionPolicy: {
68 ...defaultConnectionPolicy,
69 endpointRefreshRateInMs: 700,
70 enableBackgroundEndpointRefreshing: true
71 }
72});
73```
74
75- Added `client.dispose()` for closing the endpoint refresher verbosely. Necessary when destroying the CosmosClient inside existing processes like an express web server, or when you want to destroy the client and create a new one in the same process.
76
77```js
78const client = new CosmosClient();
79client.dispose(); // cancels background endpoint refreshing
80```
81
82## 3.11.5 (2021-06-10)
83
84### Features Added
85
86### Breaking Changes
87
88### Key Bugs Fixed
89
90### Fixed
91
92- BUGFIX: Adds another failover condition.
93
94## 3.11.4 (2021-06-10)
95
96- BUGFIX: Correctly failover to new regions when regional DNS has gone offline.
97
98## 3.11.3 (2021-05-21)
99
100- BUGFIX: Sanitize user endpoint URLs for AAD DataPlane RBAC token generation.
101
102## 3.11.2 (2021-05-11)
103
104- BUGFIX: Cache https client between requests.
105
106## 3.11.1 (2021-05-06)
107
108- BUGFIX: Import URL from Browser/Node shim rather than built-in module.
109
110## 3.11.0 (2021-04-21)
111
112- FEATURE: Internal client update. No user facing changes, but major version bump to be safe.
113
114## 3.10.6 (2021-04-14)
115
116- BUGFIX: Adds partitionKey parameter to `container.conflicts.delete`
117
118## 3.10.5 (2021-03-25)
119
120- BUGFIX: Pins node-abort-controller version as we depend on a type in v1.2.0.
121
122## 3.10.4 (2021-03-23)
123
124- FEATURE: Adds Bulk continueOnError option.
125
126## 3.10.3 (2021-03-12)
127
128- BUGFIX: Removes direct dependency on @azure/identity while retaining compatibility.
129
130## 3.10.2 (2021-03-11)
131
132- BUGFIX: Fixes @azure/identity dependency in dev deps.
133
134## 3.10.1 (2021-03-10)
135
136- BUGFIX: Autogenerates IDs for Upsert operations in bulk.
137
138## 3.10.0 (2021-01-21)
139
140- FEATURE: Adds AAD authentication via @azure/identity.
141
142## 3.9.5 (2021-01-18)
143
144- BUGFIX: Throws correct Invalid Continuation Token error when making request with malformed token
145- BUGFIX: Defaults partitionKeyValue to `'[{}]'` when missing in Read/Delete bulk operations
146- BUGFIX: Sums group by operations for cross-partition queries correctly with null values.
147
148## 3.9.3 (2020-10-19)
149
150- BUGFIX: Fixes bulk operations with top level partitionKey values that are undefined or null.
151
152## 3.9.2 (2020-09-16)
153
154- BUGFIX: Fixes slow `userAgent` lookup on azure functions.
155
156## 3.9.1 (2020-08-28)
157
158- BUGFIX: Fixes `OperationInput` type to be more accurate based on `OperationType`.
159- FEATURE: Bulk requests with `Create` operations will now autogenerate IDs if they are not present.
160- FEATURE: The `BulkOperationType` enum now exists and can be used when making bulk requests.
161
162## 3.9.0 (2020-08-13)
163
164- FEATURE: Adds support for autoscale parameters on container and database create methods
165
166Note that `maxThroughput` cannot be passed with `throughput`.
167
168```js
169// correct
170const containerDefinition = {
171 id: "sample container",
172 indexingPolicy: { indexingMode: IndexingMode.consistent },
173 maxThroughput: 500,
174 autoUpgradePolicy: {
175 throughputPolicy: {
176 incrementPercent: 15
177 }
178 }
179};
180database.container.create(containerDefinition)
181
182// incorrect
183const containerDefinition = {
184 id: "sample container",
185 indexingPolicy: { indexingMode: IndexingMode.consistent },
186 throughput: 500, // do not specify throughput with maxThroughput
187 maxThroughput: 500
188 autoUpgradePolicy: {
189 throughputPolicy: {
190 incrementPercent: 15
191 }
192 }
193};
194database.container.create(containerDefinition)
195```
196
197## 3.8.2 (2020-08-12)
198
199- BUGFIX: Fix checkURL function for Node 8
200
201## 3.8.1 (2020-08-12)
202
203- BUGFIX: Adds separate URL module for browser/node.
204
205## 3.8.0 (2020-08-10)
206
207- FEATURE: Throws when initializing ClientContext with an invalid endpoint
208- FEATURE: Changes JSONArray type internal from Array to ArrayLike to avoid requiring type coercion for immutable data
209- FEATURE: Adds bulk request to container.items. Allows aggregate bulk request for up to 100 operations on items with the types: Create, Upsert, Read, Replace, Delete
210
211```js
212// up to 100 operations
213const operations: OperationInput[] = [
214 {
215 operationType: "Create",
216 resourceBody: { id: "doc1", name: "sample", key: "A" }
217 },
218 {
219 operationType: "Upsert",
220 resourceBody: { id: "doc2", name: "other", key: "A" }
221 },
222 {
223 operationType: "Read",
224 id: "readItemId",
225 partitionKey: "key"
226 }
227];
228
229await database.container.items.bulk(operations);
230```
231
232## 3.7.4 (2020-06-30)
233
234- BUGFIX: Properly escape ASCII "DEL" character in partition key header
235
236## 3.7.3 (2020-06-29)
237
238- BUGFIX: Cannot create item with automatic id generation and a container partitioned on ID (#9734)
239
240## 3.7.2 (2020-06-16)
241
242- BUGFIX: Internal abort signal incorrectly triggered when user passes a custom abort signal. See #9510 for details.
243
244## 3.7.1 (2020-06-12)
245
246- BUGFIX: Typo in globalCrypto.js causing errors in IE browser
247- BUGFIX: Resource tokens not matching for item delete operations (#9110)
248
249## 3.7.0 (2020-06-08)
250
251- BUGFIX: Support crypto functions in Internet Explorer browser
252- BUGFIX: Incorrect key casing in object returned by `setAuthorizationHeader`
253- FEATURE: Adds `readOffer` methods to container and database
254- FEATURE: Allows string value `partitionKey` parameter when creating containers
255
256The following result in the same behavior:
257
258```js
259const containerDefinition = {
260 id: "sample container",
261 indexingPolicy: { indexingMode: IndexingMode.consistent },
262 throughput: 400,
263 partitionKey: { paths: ["/key"] }
264};
265database.container.create(containerDefinition);
266
267// OR as a string
268
269const containerDefinition = {
270 id: "sample container",
271 indexingPolicy: { indexingMode: IndexingMode.consistent },
272 throughput: 400,
273 partitionKey: "/key" } // must have leading slash "/"
274};
275database.container.create(containerDefinition);
276```
277
278## 3.6.3 (2020-04-08)
279
280- FEATURE: Add `partitionKey` to `FeedOptions` for scoping a query to a single partition key value
281
282@azure/cosmos V2 has two different but equivalent ways to specify the partition key for a query:
283
284```js
285// V2 These are effectively the same
286container.items.query("SELECT * from c", { partitionKey: "foo" }).toArray();
287container.items.query('SELECT * from c WHERE c.yourPartitionKey = "foo"').toArray();
288```
289
290In an effort to simplify, the V3 SDK removed `partitionKey` from `FeedOptions` so there was only one way to specify the partition key:
291
292```js
293// V3
294container.items.query('SELECT * from c WHERE c.yourPartitionKey = "foo"').fetchAll();
295```
296
297Based on customer feedback, we identified scenarios where it still makes sense to support passing the partition key via `FeedOptions` and have decided to restore the behavior.
298
299## 3.6.2 (2020-02-20)
300
301- BUG FIX: Support signing in web workers where this === self
302
303## 3.6.1 (2020-02-11)
304
305- BUG FIX: Normalize location names when selecting endpoint. Allows passing of normalized endpoint names
306
307## 3.6.0 (2020-02-10)
308
309- FEATURE: Add support for spatial indexing, bounding boxes, and geospatial configuration
310- BUG FIX: Fix bug when passing forceQueryPlan to QueryIterator for non-item resources (#7333)
311
312## 3.5.4 (2020-01-28)
313
314- BUG FIX: Return parsed number instead of string for request charge
315
316## 3.5.3 (2020-01-06)
317
318- BUG FIX: maxDegreeOfParallelism was defaulting to 1 and should default to the number of partitions of the collection
319- BUG FIX: maxItemCount was defaulting to 10 and should default to undefined
320- Set default TLS version to 1.2 (#6761)
321- Use tslib 1.10.0 (#6710)
322- Add partition key to code sample (#6612)
323
324## 3.5.2 (2019-12-03)
325
326- Fix handling of special characters in item ids when signing tokens in the browser (#6379)
327
328## 3.5.1 (2019-11-25)
329
330- Fix bug when paginating GROUP BY queries or using in conjunction with TOP/OFFSET/LIMIT (#6003)
331- Improve error message for mixed type ORDER BY (#6306)
332
333## 3.5.0 (2019-11-21)
334
335- FEATURE: Endpoint discovery and multi-region failover improvements. See https://github.com/Azure/azure-sdk-for-js/pull/6283 for more information on this change. (#6283)
336- Makes changeFeed and query options optional. Fix #6232 Fix #6277 (#6273)
337
338## 3.4.2 (2019-11-07)
339
340- Fixes bug where the query may throw a 410 error during a split operation. Instead, throw 503 (#6074)
341
342## 3.4.1 (2019-11-05)
343
344- Fix region drop failover scenario and add test (#5892)
345
346## 3.4.0 (2019-10-28)
347
348- FEATURE: GROUP BY query support (#5749)
349- Update proxy-agent. Remove types folder (#5854)
350- Typo: Fix "an" vs "a" (#5812)
351- Update to Mocha 6.2.2 (#5824)
352- Remove unused Range type (#5686)
353- Remove universal-user-agent (#5869)
354
355## 3.3.4 (2019-10-14)
356
357- Query bug fix. Empty result last call not reporting proper RUs (#5517)
358- Sign headers using internal package (#5523)
359- Use internal digest function instead of crypto-hash package (#5493)
360- Remove internal binary-search-bounds package (#5417)
361- Fix atob bug impacting browser users (#5375)
362
363## 3.3.2 (2019-10-03)
364
365- Export TokenProvider and RequestInfo types (#5262)
366- Remove atob package in favor of local version (#5334)
367- Fix incorrect lib version in UserAgent (#5295)
368- Allow zero for Item TTL (#5257)
369
370## 3.3.0 (2019-09-24)
371
372- FEATURE: Add userAgentSuffix to CosmosClient constructor options (#5068)
373- Guard process.env to fix webpack issues (#5223)
374- Fixes bug where initial QueryIterator promise was not being created (#5215)
375- Fix aggregates bug when query was returning no results (#5184)
376- sideEffects field set to false (#5022)
377
378## 3.2.0 (2019-08-26)
379
380- FEATURE: Endpoint resolution now blocks until initialized (#409)
381- FEATURE: Add bufferItems support & other cross-partition perf improvements (#397)
382- Fix missing AbortSignal type for users not targeting the DOM (#416)
383- Add sample for bulk update with continuation token (#402)
384- Export default partition key path (#405)
385
386## 3.1.1 (2019-08-07)
387
388- Fix bug where offset limit iterator was being called for each item under the offset count (#398)
389- Add retry on EPIPE error (#400)
390
391## 3.1.0 (2019-07-26)
392
393- FEATURE: Set default ResponseContinuationTokenLimitInKB to 1kb. Prevents header limit errors (#384)
394- Remove unused disableSSLVerification options (#388)
395
396## 3.0.4 (2019-07-22)
397
398- Allow initialHeaders to explicitly set partition key header (#383)
399- Use package.json#files to prevent extraneous files from being pubished (#382)
400- Fix for routing map sort error on older version of node+v8 (#378)
401- Fixes bug when user supplies partial retry options. Close #377 (#379)
402- README updates (#374)
403
404## 3.0.3 (2019-07-17)
405
406- Fix webpack usage. Prevent resolving modules called with `require` (#373)
407- Various internal API cleanups and sample fixes
408
409## 3.0.2 (2019-07-09)
410
411Fixes a long outstanding bug where RUs were always being reported as 0 for aggregate queries (#366)
412
413## 3.0.1 (2019-07-02)
414
415Fixes broken session tokens in the browser. Cosmos uses file system friendly base64 to represent resources internally but does not work with the builtin browser atob function (#363)
416
417## 3.0.0 (2019-06-28)
418
419🎉 v3 release! 🎉 Many new features, bug fixes, and a few breaking changes. Primary goals of this release:
420
421- Implement major new features:
422 - DISTINCT queries
423 - LIMIT/OFFSET queries
424 - User cancelable requests
425- Update to the latest Cosmos REST API version where [all containers have unlimited scale](https://docs.microsoft.com/azure/cosmos-db/migrate-containers-partitioned-to-nonpartitioned)
426- Make it easier to use Cosmos from the browser
427- Better align with the new [Azure JS SDK guidlines](https://azure.github.io/azure-sdk/typescript_introduction.html)
428
429### Migration Guide for Breaking Changes
430
431#### Improved Client Constructor Options (#246)
432
433Constructor options have been simplified:
434
435- `masterKey` was renamed `key` and moved to the top-level
436- Properties previously under `options.auth` have moved to the top-level
437
438```js
439// v2
440const client = new CosmosClient({
441 endpoint: "https://your-database.cosmos.azure.com",
442 auth: {
443 masterKey: "your-primary-key"
444 }
445});
446
447// v3
448const client = new CosmosClient({
449 endpoint: "https://your-database.cosmos.azure.com",
450 key: "your-primary-key"
451});
452```
453
454#### Simplified QueryIterator API (#238 #316)
455
456In v2 there were many different ways to iterate or retrieve results from a query. We have attempted to simplify the v3 API and remove similar or duplciate APIs:
457
458- Remove iterator.next() and iterator.current(). Use fetchNext() to get pages of results.
459- Remove iterator.forEach(). Use async iterators instead.
460- iterator.executeNext() renamed to iterator.fetchNext()
461- iterator.toArray() renamed to iterator.fetchAll()
462- Pages are now proper `Response` objects intead of plain JS objects
463
464```js
465const container = client.database(dbId).container(containerId)
466
467// v2
468container.items.query('SELECT * from c').toArray()
469container.items.query('SELECT * from c').executeNext()
470container.items.query('SELECT * from c').forEach(({ body: item }) => { console.log(item.id) })
471
472// v3
473container.items.query('SELECT * from c').fetchAll()
474container.items.query('SELECT * from c').fetchNext()
475for await(const { result: item } in client.databases.readAll().getAsyncIterator()) {
476 console.log(item.id)
477}
478```
479
480#### Simplified Partition Keys for Queries
481
482v2 has two different but equivalent ways to specify the partition key for a query:
483
484```js
485// v2. These are effectively the same
486container.items.query("SELECT * from c", { partitionKey: "foo" }).toArray();
487container.items.query('SELECT * from c WHERE c.yourPartitionKey = "foo"').toArray();
488```
489
490v3 removed `partitionKey` from `FeedOptions` so there is now only one way to specify the partition key:
491
492```js
493// v3
494container.items.query('SELECT * from c WHERE c.yourPartitionKey = "foo"').fetchAll();
495```
496
497#### Fixed Containers are now Paritioned (#308)
498
499[The Cosmos service now supports partition keys on all containers, including those that were previously created as fixed containers](https://docs.microsoft.com/azure/cosmos-db/migrate-containers-partitioned-to-nonpartitioned). The v3 SDK updates to the latest API version that implements this change, but it is not breaking. If you do not supply a partition key for operations, we will default to a system key that works with all your existing containers and documents.
500
501#### `upsert` removed for Stored Procedures (#356)
502
503Previously `upsert` was allowed for non-partitioned collections, but with the API version update, all collections are partitioned so we removed it entirely.
504
505#### Item reads will not throw on 404 (#343, Community Request)
506
507```js
508const container = client.database(dbId).container(containerId);
509
510// v2
511try {
512 container.items.read(id, undefined);
513} catch (e) {
514 if (e.code === 404) {
515 console.log("item not found");
516 }
517}
518
519// v3
520const { result: item } = container.items.read(id, undefined);
521if (item === undefined) {
522 console.log("item not found");
523}
524```
525
526#### Default Multi Region Write (#335)
527
528The SDK will now write to multiple regions by default if your database configuration supports it. This was previously opt-in behavior.
529
530#### Proper Error Objects (#334, Community Request)
531
532Failed requests now throw proper `Error` or subclasses of `Error`. Previously they threw plain JS objects.
533
534### New Features
535
536#### User Cancellable Requests (#263, Community Request)
537
538The move to `fetch` internally allows us to use the browser `AbortController` API to support user cancellable operations. In the case of operations where multiple requests are potentially in progress (like cross partition queries), all requests for the operation will be canceled. Modern browser users will already have `AbortController`. Node.js users will need to use a [polyfill library](https://www.npmjs.com/package/node-abort-controller)
539
540```js
541const controller = new AbortController();
542const { result: item } = await items.query("SELECT * from c", { abortSignal: controller.signal });
543controller.abort();
544```
545
546#### Set throughput as part of db/container create operation (#220)
547
548```js
549const { database } = client.databases.create({ id: "my-database", throughput: 10000 });
550database.containers.create({ id: "my-container", throughput: 10000 });
551```
552
553#### @azure/cosmos-sign (#213)
554
555Header token generation was split out into a new library, @azure/cosmos-sign. Anyone calling the Cosmos REST API directly can use this to sign headers using the same code we call inside @azure/cosmos.
556
557#### UUID for generated IDs (#355)
558
559v2 had custom code to generate item IDs. We have switched to the well known and maintained community library `uuid`.
560
561#### Connection Strings (#350, Community Request)
562
563It is now possible to pass a connection string copied from the Azure portal:
564
565```js
566const client = new CosmosClient(
567 "AccountEndpoint=https://test-account.documents.azure.com:443/;AccountKey=<KEY HERE>;"
568);
569```
570
571#### Add DISTINCT and LIMIT/OFFSET queries (#306)
572
573```js
574const { results } = await items.query("SELECT DISTINCT VALUE r.name FROM ROOT").fetchAll();
575const { results } = await items.query("SELECT * FROM root r OFFSET 1 LIMIT 2").fetchAll();
576```
577
578### Improved Browser Experience
579
580While it was possible to use the v2 SDK in the browser it was not an ideal experience. You needed to polyfill several node.js built-in libraries and use a bundler like Webpack or Parcel. The v3 SDK makes the out of the box experience much better for browser users.
581
582- Replace request internals with `fetch` (#245)
583- Remove usage of Buffer (#330)
584- Remove node builtin usage in favor of universal packages/APIs (#328)
585- Switch to node-abort-controller (#294)
586
587### Bug Fixes
588
589- Fix offer read and bring back offer tests (#224)
590- Fix EnableEndpointDiscovery (#207)
591- Fix missing RUs on paginated results (#360)
592- Expand SQL query parameter type (#346)
593- Add ttl to ItemDefinition (#341)
594- Fix CP query metrics (#311)
595- Add activityId to FeedResponse (#293)
596- Switch \_ts type from string to number (#252)(#295)
597- Fix Request Charge Aggregation (#289)
598- Allow blank string partition keys (#277)
599- Add string to conflict query type (#237)
600- Add uniqueKeyPolicy to container (#234)
601
602### Engineering Systems
603
604Not always the most visible changes, but they help our team ship better code, faster.
605
606- Use rollup for production builds (#104)
607- Update to Typescript 3.5 (#327)
608- Convert to TS project references. Extract test folder (#270)
609- Enable noUnusedLocals and noUnusedParameters (#275)
610- Azure Pipelines YAML for CI builds (#298)
611
612## 2.0.1 (2018-09-25)
613
614- Fix type issue (See #141)
615
616## 2.0.0 (2018-09-24)
617
618- Multi-region Write support
619- Shared resource response properties added to responses
620- Changed query to allow for customer types for all Resource types
621- Modified items.query to allow for cross partition query
622- Misc fixes/doc updates
623
624## 2.0.0-3 (2018-08-02)
625
626- New object model
627- Updated documentation and samples
628- Improved types
629- Added `createdIfNotExists` for database and container
630- Added prettier
631- Added public CI (Travis and VSTS)
632
633## 2.0.0-0 (2018-08-01)
634
635- Added Promise support
636- Added token handler option for auth
637- typings now emitted from source (moved source to TypeScript)
638- Added CosmosClient (DocumentClient now considered deprecated)
639
640## 1.14.4 (2018-05-03)
641
642- npm documentation fixed.
643
644## 1.14.3 (2018-05-03)
645
646- Added support for default retries on connection issues.
647- Added support to read collection change feed.
648- Fixed session consistency bug that intermittently caused "read session not available".
649- Added support for query metrics.
650- Modified http Agent's maximum number of connections.
651
652## 1.14.2 (2017-12-21)
653
654- Updated documentation to use Azure Cosmos DB.
655- Added Support for proxyUrl setting in ConnectionPolicy.
656
657## 1.14.1 (2017-11-10)
658
659- Minor fix for case sensitive file systems.
660
661## 1.14.0 (2017-11-09)
662
663- Adds support for Session Consistency.
664- This SDK version requires the latest version of Azure Cosmos DB Emulator available for download from https://aka.ms/cosmosdb-emulator.
665
666## 1.13.0 (2017-10-11)
667
668- Splitproofed cross partition queries.
669- Adds supports for resource link with leading and trailing slashes (and corresponding tests).
670
671## 1.12.2 (2017-08-10)
672
673- npm documentation fixed.
674
675## 1.12.1 (2017-08-10)
676
677- Fixed bug in executeStoredProcedure where documents involved had special unicode characters (LS, PS).
678- Fixed bug in handling documents with unicode characters in partition key.
679- Fixed support for creating collection with name media (github #114).
680- Fixed support for permission authorization token (github #178).
681
682## 1.12.0 (2017-05-10)
683
684- Added support for Request Unit per Minute (RU/m) feature.
685- Added support for a new consistency level called ConsistentPrefix.
686- Added support for UriFactory.
687- Fixed the unicode support bug (github #171)
688
689## 1.11.0 (2017-03-16)
690
691- Added the support for aggregation queries (COUNT, MIN, MAX, SUM, and AVG).
692- Added the option for controlling degree of parallelism for cross partition queries.
693- Added the option for disabling SSL verification when running against Emulator.
694- Lowered minimum throughput on partitioned collections from 10,100 RU/s to 2500 RU/s.
695- Fixed the continuation token bug for single partition collection (github #107).
696- Fixed the executeStoredProcedure bug in handling 0 as single param (github #155).
697
698## 1.10.2 (2017-01-27)
699
700- Fixed user-agent header to include the SDK version.
701- Minor code cleanup.
702
703## 1.10.1 (2016-12-22)
704
705- Disabling SSL verification when using the SDK to target the emulator(hostname=localhost).
706- Added support for enabling script logging during stored procedure execution.
707
708## 1.10.0 (2016-10-03)
709
710- Added support for cross partition parallel queries.
711- Added support for TOP/ORDER BY queries for partitioned collections.
712
713## 1.9.0 (2016-07-07)
714
715- Added retry policy support for throttled requests. (Throttled requests receive a request rate too large exception, error code 429.)
716 By default, DocumentClient retries nine times for each request when error code 429 is encountered, honoring the retryAfter time in the response header.
717 A fixed retry interval time can now be set as part of the RetryOptions property on the ConnectionPolicy object if you want to ignore the retryAfter time returned by server between the retries.
718 DocumentClient now waits for a maximum of 30 seconds for each request that is being throttled (irrespective of retry count) and returns the response with error code 429.
719 This time can also be overriden in the RetryOptions property on ConnectionPolicy object.
720
721- DocumentClient now returns x-ms-throttle-retry-count and x-ms-throttle-retry-wait-time-ms as the response headers in every request to denote the throttle retry count and the cummulative time the request waited between the retries.
722
723- The RetryOptions class was added, exposing the RetryOptions property on the ConnectionPolicy class that can be used to override some of the default retry options.
724
725## 1.8.0 (2016-06-14)
726
727- Added the support for geo-replicated database accounts.
728
729## 1.7.0 (2016-04-26)
730
731- Added the support for TimeToLive(TTL) feature for documents.
732
733## 1.6.0 (2016-03-29)
734
735- Added support for Partitioned Collections.
736- Added support for new offer types.
737
738## 1.5.6 (2016-03-08)
739
740- Fixed RangePartitionResolver.resolveForRead bug where it was not returning links due to a bad concat of results.
741- Move compareFunction from Range class to RangePartitionResolver class.
742
743## 1.5.5 (2016-02-02)
744
745- Fixed hashParitionResolver resolveForRead(): When no partition key supplied was throwing exception, instead of returning a list of all registered links.
746
747## 1.5.4 (2016-02-01)
748
749- Dedicated HTTPS Agent: Avoid modifying the global. Use a dedicated agent for all of the lib’s requests.
750
751## 1.5.3 (2016-01-26)
752
753- Properly handle dashes in the mediaIds.
754
755## 1.5.2 (2016-01-22)
756
757- Fix memory leak.
758
759## 1.5.1 (2016-01-04)
760
761- Renamed "Hash" directory to "hash".
762
763## 1.5.0 (2015-12-31)
764
765- Added client-side sharding support.
766- Added hash partition resolver implementation.
767- Added range partitoin resolver implementation.
768
769## 1.4.0 (2015-10-06)
770
771- Implement Upsert. New upsertXXX methods on documentClient.
772
773## 1.3.0 (2015-10-06)
774
775- Skipped to bring version numbers in alignment with other SDKs.
776
777## 1.2.2 (2015-09-10)
778
779- Split Q promises wrapper to new repository.
780- Update to package file for npm registry.
781
782## 1.2.1 (2015-08-15)
783
784- Implements ID Based Routing.
785- Fixes Issue [#49](https://github.com/Azure/azure-documentdb-node/issues/49) - current property conflicts with method current().
786
787## 1.2.0 (2015-08-05)
788
789- Added support for GeoSpatial index.
790- Validates id property for all resources. Ids for resources cannot contain ?, /, #, \\, characters or end with a space.
791- Adds new header "index transformation progress" to ResourceResponse.
792
793## 1.1.0 (2015-07-09)
794
795- Implements V2 indexing policy.
796
797## 1.0.3 (2015-06-04)
798
799- Issue [#40](https://github.com/Azure/azure-documentdb-node/issues/40) - Implemented eslint and grunt configurations in the core and promise SDK.
800
801## 1.0.2 (2015-05-23)
802
803- Issue [#45](https://github.com/Azure/azure-documentdb-node/issues/45) - Promises wrapper does not include header with error.
804
805## 1.0.1 (2015-05-15)
806
807- Implemented ability to query for conflicts by adding readConflicts, readConflictAsync, queryConflicts.
808- Updated API documentation.
809- Issue [#41](https://github.com/Azure/azure-documentdb-node/issues/41) - client.createDocumentAsync error.
810
811Microsoft will provide notification at least **12 months** in advance of retiring an SDK in order to smooth the transition to a newer/supported version.
812
813New features, functionality, and optimizations are only added to the current SDK. So it's recommended that you always upgrade to the latest SDK version as early as possible.
814
815Any request to Cosmos DB using a retired SDK will be rejected by the service.
816
817> [!WARNING]
818> All versions **1.x** of the Cosmos JavaScript SDK for SQL API will be retired on **August 30, 2020**.
819>
820> <br/>
821
822| Version | Release Date | Retirement Date |
823| ------------------------ | ------------------ | --------------- |
824| [3.4.2](#3.4.2) | November 7, 2019 | --- |
825| [3.4.1](#3.4.1) | November 5, 2019 | --- |
826| [3.4.0](#3.4.0) | October 28, 2019 | --- |
827| [3.3.6](#3.3.6) | October 14, 2019 | --- |
828| [3.3.5](#3.3.5) | October 14, 2019 | --- |
829| [3.3.4](#3.3.4) | October 14, 2019 | --- |
830| [3.3.3](#3.3.3) | October 3, 2019 | --- |
831| [3.3.2](#3.3.2) | October 3, 2019 | --- |
832| [3.3.1](#3.3.1) | October 1, 2019 | --- |
833| [3.3.0](#3.3.0) | September 24, 2019 | --- |
834| [3.2.0](#3.2.0) | August 26, 2019 | --- |
835| [3.1.1](#3.1.1) | August 7, 2019 | --- |
836| [3.1.0](#3.1.0) | July 26, 2019 | --- |
837| [3.0.4](#3.0.4) | July 22, 2019 | --- |
838| [3.0.3](#3.0.3) | July 17, 2019 | --- |
839| [3.0.2](#3.0.2) | July 9, 2019 | --- |
840| [3.0.0](#3.0.0) | June 28, 2019 | --- |
841| [2.1.5](#2.1.5) | March 20, 2019 | --- |
842| [2.1.4](#2.1.4) | March 15, 2019 | --- |
843| [2.1.3](#2.1.3) | March 8, 2019 | --- |
844| [2.1.2](#2.1.2) | January 28, 2019 | --- |
845| [2.1.1](#2.1.1) | December 5, 2018 | --- |
846| [2.1.0](#2.1.0) | December 4, 2018 | --- |
847| [2.0.5](#2.0.5) | November 7, 2018 | --- |
848| [2.0.4](#2.0.4) | October 30, 2018 | --- |
849| [2.0.3](#2.0.3) | October 30, 2018 | --- |
850| [2.0.2](#2.0.2) | October 10, 2018 | --- |
851| [2.0.1](#2.0.1) | September 25, 2018 | --- |
852| [2.0.0](#2.0.0) | September 24, 2018 | --- |
853| [2.0.0-3 (RC)](#2.0.0-3) | August 2, 2018 | --- |
854| [1.14.4](#1.14.4) | May 03, 2018 | August 30, 2020 |
855| [1.14.3](#1.14.3) | May 03, 2018 | August 30, 2020 |
856| [1.14.2](#1.14.2) | December 21, 2017 | August 30, 2020 |
857| [1.14.1](#1.14.1) | November 10, 2017 | August 30, 2020 |
858| [1.14.0](#1.14.0) | November 9, 2017 | August 30, 2020 |
859| [1.13.0](#1.13.0) | October 11, 2017 | August 30, 2020 |
860| [1.12.2](#1.12.2) | August 10, 2017 | August 30, 2020 |
861| [1.12.1](#1.12.1) | August 10, 2017 | August 30, 2020 |
862| [1.12.0](#1.12.0) | May 10, 2017 | August 30, 2020 |
863| [1.11.0](#1.11.0) | March 16, 2017 | August 30, 2020 |
864| [1.10.2](#1.10.2) | January 27, 2017 | August 30, 2020 |
865| [1.10.1](#1.10.1) | December 22, 2016 | August 30, 2020 |
866| [1.10.0](#1.10.0) | October 03, 2016 | August 30, 2020 |
867| [1.9.0](#1.9.0) | July 07, 2016 | August 30, 2020 |
868| [1.8.0](#1.8.0) | June 14, 2016 | August 30, 2020 |
869| [1.7.0](#1.7.0) | April 26, 2016 | August 30, 2020 |
870| [1.6.0](#1.6.0) | March 29, 2016 | August 30, 2020 |
871| [1.5.6](#1.5.6) | March 08, 2016 | August 30, 2020 |
872| [1.5.5](#1.5.5) | February 02, 2016 | August 30, 2020 |
873| [1.5.4](#1.5.4) | February 01, 2016 | August 30, 2020 |
874| [1.5.3](#1.5.2) | January 26, 2016 | August 30, 2020 |
875| [1.5.2](#1.5.2) | January 22, 2016 | August 30, 2020 |
876| [1.5.1](#1.5.1) | January 4, 2016 | August 30, 2020 |
877| [1.5.0](#1.5.0) | December 31, 2015 | August 30, 2020 |
878| [1.4.0](#1.4.0) | October 06, 2015 | August 30, 2020 |
879| [1.3.0](#1.3.0) | October 06, 2015 | August 30, 2020 |
880| [1.2.2](#1.2.2) | September 10, 2015 | August 30, 2020 |
881| [1.2.1](#1.2.1) | August 15, 2015 | August 30, 2020 |
882| [1.2.0](#1.2.0) | August 05, 2015 | August 30, 2020 |
883| [1.1.0](#1.1.0) | July 09, 2015 | August 30, 2020 |
884| [1.0.3](#1.0.3) | June 04, 2015 | August 30, 2020 |
885| [1.0.2](#1.0.2) | May 23, 2015 | August 30, 2020 |
886| [1.0.1](#1.0.1) | May 15, 2015 | August 30, 2020 |
887| [1.0.0](#1.0.0) | April 08, 2015 | August 30, 2020 |