UNPKG

9.36 kBMarkdownView Raw
1# Changelog
2All notable changes to this project will be documented in this file.
3
4The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
5and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
7## [Unreleased]
8
9## [4.6.0] - 2021-09-17
10
11### Changed
12
13- Moved `mongodb` to a peer dependency (and also as a dev dependency for `connect-mongo` developers). `connect-mongo` is no longer pinned to a specific version of `mongodb`. This allows end users to avoid errors due to Typescript definition changes when moving to new versions of `mongodb`. Users can use any version of `mongodb` that provides a compatible (non-breaking) interface to `mongodb ^4.1.0`. Tested on `mongodb` `4.1.0` and `4.1.1`. Should fix: [#433](https://github.com/jdesboeufs/connect-mongo/issues/433) [#434](https://github.com/jdesboeufs/connect-mongo/issues/434) [#436](https://github.com/jdesboeufs/connect-mongo/issues/436)
14
15### Fixed
16
17- Fixed "Callback was already called" when some code throws immediately after calling the set function
18
19## [4.5.0] - 2021-08-17
20
21### **BREAKING CHANGES**
22
23- Drop Node 10 support
24
25### Changed
26
27- Upgrade `mongodb` to V4 [#422] [#426]
28
29### Fixed
30
31- Move `writeConcern` away from top-level option to fix deprecation warning [#422](https://github.com/jdesboeufs/connect-mongo/issues/422)
32
33## [4.4.1] - 2021-03-23
34
35### Fixed
36
37- `store.all()` method not working with encrypted store [#410](https://github.com/jdesboeufs/connect-mongo/issues/410) [#411](https://github.com/jdesboeufs/connect-mongo/issues/411)
38- Update and unpin `mongodb` dependency due to upstream fix has been deployed [#409](https://github.com/jdesboeufs/connect-mongo/issues/409)
39
40## [4.4.0] - 2021-03-11
41
42### **BREAKING CHANGES**
43
44- Use `export =` for better cjs require without `.default`
45
46### Added
47
48- Add typescript example
49
50## [4.3.1] - 2021-03-09
51
52### Fixed
53
54- Fix incorrect assertion checking after adding `client` options
55
56## [4.3.0] - 2021-03-08
57
58### Added
59
60- Add `client` option for non-promise client
61
62## [4.2.2] - 2021-03-02
63
64### Fixed
65
66- Fix crypto parsing error by upgrading `kruptein` to `v3.0.0` and change encodeas to `base64`
67
68## [4.2.0] - 2021-02-24
69
70### Added
71
72- Added mongoose example
73- Revert `createAutoRemoveIdx` and add back `autoRemove` and `autoRemoveInterval`
74
75### Fixed
76
77- Use `matchedCount` instead of `modifiedCount` to avoid throwing exceptions when nothing to modify [#390](https://github.com/jdesboeufs/connect-mongo/issues/390)
78- Fixed `Warning: Accessing non-existent property 'MongoError' of module exports inside circular dependency` by downgrade to `mongodb@3.6.3`
79- Revert update session when touch #351
80- Fix cannot read property `lastModified` of null
81- Fix TS typing error
82
83## [4.1.0] - 2021-02-22
84
85### **BREAKING CHANGES**
86
87- Support Node.Js 10.x, 12.x and 14.x and drop older support.
88- Review method to connect to MongoDB and keep only `mongoUrl` and `clientPromise` options.
89- Remove the "Remove expired sessions compatibility mode". Now library user can choose to create auto remove index on startup or not.
90- Remove `fallbackMemory` options.
91- Rewrite the library and test case using typescript.
92
93> Checkout the complete [migration guide](MIGRATION_V4.md) for more details.
94
95## [3.2.0] - 2019-11-29
96
97### Added
98
99- Add dbName option (#343)
100
101### Fixed
102
103- Add missing `secret` option to TS definition (#342)
104
105## [3.1.2] - 2019-11-01
106
107### Fixed
108
109- Add @types/ dev dependencies for tsc. fixes #340 (#341)
110
111## [3.1.1] - 2019-10-30
112
113### Added
114
115- Add TS type definition
116
117## [3.1.0] - 2019-10-23
118
119### Added
120
121- Added `useUnifiedTopology=true` to mongo options
122
123### Changed
124
125- Refactor merge config logic
126- chore: update depns (#326)
127
128## [3.0.0] - 2019-06-17
129
130### **BREAKING CHANGES**
131
132- Drop Node.js 4 & 6 support
133- Upgrade `mongoose` to v5 and `mongodb` to v3 and drop old version support
134- Replace deprecated mongo operation
135- MongoStore need to supply client/clientPromise instead of db/dbPromise due to depns upgrade
136
137## Added
138
139- Add Node.js 10 & 12 support
140- Implement store.all function (#291)
141- Add option `writeOperationOptions` (#295)
142- Add Transparent crypto support (#314)
143
144## Changed
145
146* Change test framework from Mocha to Jest
147* Change linter from `xo` to `eslint`
148
149## [2.0.3] - 2018-12-03
150
151## Fixed
152
153- Fixed interval autoremove mode to use current date with every interval (#304, #305) (jlampise)
154
155## [2.0.2] - 2018-11-20
156
157## Fixed
158
159- Fxi #300 DeprecationWarning: collection.remove is deprecated. Use deleteOne, deleteMany, or bulkWrite instead
160- Fxi #297 DeprecationWarning: collection.update is deprecated. Use updateOne, updateMany, or bulkWrite instead
161
162## [2.0.1] - 2018-01-04
163
164## Fixed
165
166- Fixed #271 TypeError: cb is not a function (brainthinks)
167
168## [2.0.0] - 2017-10-09
169
170### **BREAKING CHANGES**
171
172* __Drop__ Node.js 0.12 and io.js support
173* __Drop__ MongoDB 2.x support
174* __Drop__ mongodb driver < 2.0.36 support
175* __Drop__ mongoose < 4.1.2 support
176
177## Changed
178
179* __Fix__ `ensureIndex` deprecation warning ([#268](https://github.com/jdesboeufs/connect-mongo/issues/268), [#269](https://github.com/jdesboeufs/connect-mongo/pulls/269), [#270](https://github.com/jdesboeufs/connect-mongo/pulls/270))
180* Improve `get()` ([#246](https://github.com/jdesboeufs/connect-mongo/pulls/246))
181* Pass session in `touch` event
182* Remove `bluebird` from dependencies
183
184<!-- Legacy changelog format -->
185
1861.3.2 / 2016-07-27
187=================
188
189* __Fix__ #228 Broken with mongodb@1.x
190
1911.3.1 / 2016-07-23
192=================
193
194* Restrict `bluebird` accepted versions to 3.x
195
1961.3.0 / 2016-07-23
197=================
198
199* __Add__ `create` and `update` events ([#215](https://github.com/jdesboeufs/connect-mongo/issues/215))
200* Extend `mongodb` compatibility to `2.x`
201
2021.2.1 / 2016-06-20
203=================
204
205* __Fix__ bluebird warning (Awk34)
206
2071.2.0 / 2016-05-13
208=================
209
210* Accept `dbPromise` as connection param
211* __Add__ `close()` method to close current connection
212
2131.1.0 / 2015-12-24
214=================
215
216* Support mongodb `2.1.x`
217
2181.0.2 / 2015-12-18
219=================
220
221* Enforce entry-points
222
2231.0.1 / 2015-12-17
224=================
225
226* __Fix__ entry-point
227
2281.0.0 (deprecated) / 2015-12-17
229==================
230
231__Breaking changes:__
232* __For older Node.js version (`< 4.0`), the module must be loaded using `require('connect-mongo/es5')`__
233* __Drop__ `hash` option (advanced)
234
235__Others changes:__
236* __Add__ `transformId` option to allow custom transformation on session id (advanced)
237* __Rewrite in ES6__ (w/ fallback)
238* Update dependencies
239* Improve compatibility
240
2410.8.2 / 2015-07-14
242==================
243
244* Bug fixes and improvements (whitef0x0, TimothyGu, behcet-li)
245
246
2470.8.1 / 2015-04-21
248==================
249
250* __Fix__ initialization when a connecting `mongodb` `2.0.x` instance is given (1999)
251
252
2530.8.0 / 2015-03-24
254==================
255
256* __Add__ `touchAfter` option to enable lazy update behavior on `touch()` method (rafaelcardoso)
257* __Add__ `fallbackMemory` option to switch to `MemoryStore` in some case.
258
259
2600.7.0 / 2015-01-24
261==================
262
263* __Add__ `touch()` method to be fully compliant with `express-session` `>= 1.10` (rafaelcardoso)
264
265
2660.6.0 / 2015-01-12
267==================
268
269* __Add__ `ttl` option
270* __Add__ `autoRemove` option
271* __Deprecate__ `defaultExpirationTime` option. Use `ttl` instead (in seconds)
272
273
2740.5.3 / 2014-12-30
275==================
276
277* Make callbacks optional
278
279
2800.5.2 / 2014-12-29
281==================
282
283* Extend compatibility to `mongodb` `2.0.x`
284
285
2860.5.1 / 2014-12-28
287==================
288
289* [bugfix] #143 Missing Sessions from DB should still make callback (brekkehj)
290
291
2920.5.0 (deprecated) / 2014-12-25
293==================
294
295* Accept full-featured [MongoDB connection strings](http://docs.mongodb.org/manual/reference/connection-string/) as `url` + [advanced options](http://mongodb.github.io/node-mongodb-native/1.4/driver-articles/mongoclient.html)
296* Re-use existing or upcoming mongoose connection
297* [DEPRECATED] `mongoose_connection` is renamed `mongooseConnection`
298* [DEPRECATED] `auto_reconnect` is renamed `autoReconnect`
299* [BREAKING] `autoReconnect` option is now `true` by default
300* [BREAKING] Insert `collection` option in `url` in not possible any more
301* [BREAKING] Replace for-testing-purpose `callback` by `connected` event
302* Add debug (use with `DEBUG=connect-mongo`)
303* Improve error management
304* Compatibility with `mongodb` `>= 1.2.0` and `< 2.0.0`
305* Fix many bugs
306
307
3080.4.2 / 2014-12-18
309==================
310
311 * Bumped mongodb version from 1.3.x to 1.4.x (B0k0)
312 * Add `sid` hash capability (ZheFeng)
313 * Add `serialize` and `unserialize` options (ksheedlo)
314
315
3160.3.3 / 2013-07-04
317==================
318
319 * Merged a change which reduces data duplication
320
321
3220.3.0 / 2013-01-20
323==================
324
325 * Merged several changes by Ken Pratt, including Write Concern support
326 * Updated to `mongodb` version 1.2
327
3280.2.0 / 2012-09-09
329==================
330
331 * Integrated pull request for `mongoose_connection` option
332 * Move to mongodb 1.0.x
333
3340.1.5 / 2010-07-07
335==================
336
337 * Made collection setup more robust to avoid race condition
338
339
3400.1.4 / 2010-06-28
341==================
342
343 * Added session expiry
344
345
3460.1.3 / 2010-06-27
347==================
348
349 * Added url support
350
351
3520.1.2 / 2010-05-18
353==================
354
355 * Added auto_reconnect option
356
357
3580.1.1 / 2010-03-18
359==================
360
361 * Fixed authentication
362
363
3640.1.0 / 2010-03-08
365==================
366
367 * Initial release