Skip to content

Latest commit

 

History

History
677 lines (421 loc) · 33.2 KB

CHANGELOG.md

File metadata and controls

677 lines (421 loc) · 33.2 KB

Dynamoose Changelog


Version 2.3.0

This release adds major new support for single table design.

Please comment or contact me if you have any questions about this release.

Major New Features

  • Single Table Design Enhancements
    • Nested Schemas
    • Multiple Attribute Types
    • Combine Type
    • Multiple Schemas per Model
  • Readds populate support (similar to v1 but breaking changes between v1 and v2 populate functionality)

General

  • Adds document.toJSON() method
  • Adds Serialization support

Bug Fixes

  • Minor bug fixes for TypeScript typings

Version 2.2.1

This release fixes some minor bugs found in Dynamoose.

Please comment or contact me if you have any questions about this release.

Bug Fixes

  • Fixed an issue with creation of local secondary indexes
  • Fixed an issue where specifying attributes to retrieve wouldn't work with reserved DynamoDB keywords

Other

  • Adding icons to website for GitHub & npm links

Version 2.2.0

This release adds a few key features to improve your Dynamoose workflow.

Please comment or contact me if you have any questions about this release.

General

  • Added support for query.sort
  • Added support for only passing model name into dynamoose.model and having it retrieve the registered model that was already registered previously
  • Added support for passing original value into set attribute setting function
  • Added attributes setting to Model.get to only retrieve certain attributes

Bug Fixes

  • Fixed an issue where document.original would return a DynamoDB object and not a parsed object in certain cases

Version 2.1.3

This release fixes some minor bugs.

Please comment or contact me if you have any questions about this release.

Bug Fixes

  • Fixing issue where creating multiple indexes would fail when creating or updating table
  • Fixing issue where Model.update with single object and rangeKey would fail

Version 2.1.2

This release fixes a few minor bugs with Model.update.

Please comment or contact me if you have any questions about this release.

Bug Fixes

  • Fixed an issue where Model.update using $REMOVE wouldn't work on non defined attributes using saveUnknown
  • Fixed an issue where Model.update would throw an AWS error ExpressionAttributeValues must not be empty when using $REMOVE

Version 2.1.1

This release fixes some bugs related to TypeScript and improves the website with more accurate information.

Please comment or contact me if you have any questions about this release.

General

  • 🔍 Added search functionality to website

Bug Fixes

  • TypeScript Fixes
    • Removed esModuleInterop from tsconfig.json
    • Allowing Schema Index Throughput to be Optional

Documentation

  • Add migration section from v1 to v2 to website FAQ page
  • Fixed ES Modules Import Documentation

Version 2.1.0

This release adds beta support for TypeScript typings.

Please comment or contact me if you have any questions about this release.

Major New Features

  • Beta support for TypeScript Typings

Version 2.0.0

Version 2.0 is here!! This is a full rewrite of Dynamoose from the ground up. This means that the changelog listed below is not necessarily complete, but attempts to cover a lot of the high level items of this release. There are a lot of minor bug fixes and improvements that went into this rewrite that will not be covered, as well as potientally some breaking changes that are not included in the changelog below.

Although version 2.0 is a full rewrite, the underlying API hasn't changed very much. Things like Model.scan or Model.get have not changed seamingly at all. The foundational syntax is indentical to version 1.0. This means the majority of breaking changes won't effect most users or will require only minor tweaks.

Please comment or contact me if you have any questions or problems with this release.

General

  • Complete rewrite of the codebase!!!
    • Better conditional support with new dynamoose.Condition class
    • Same familiar API
  • Entirely new website
    • Dark mode 🌑
    • Edit links on each page to contribute changes and improve documentation
    • Improved sidebar with easier orgainzation
    • Links to navigate to next/previous pages on website
  • License has been changed to The Unlicense from MIT

🚨 Breaking Changes 🚨

  • dynamoose.setDefaults has been renamed to dynamoose.model.defaults.set
  • dynamoose.local has been renamed to dynamoose.aws.ddb.local
  • dynamoose.setDDB has been renamed to dynamoose.aws.ddb.set
  • dynamoose.revertDDB has been renamed to dynamoose.aws.ddb.revert
  • dynamoose.AWS.config.update has been renamed to dynamoose.aws.sdk.config.update
  • dynamoose.ddb has been renamed to dynamoose.aws.ddb
  • Map attribute type has been replaced with Object
  • List attribute type has been replaced with Array
  • DynamoDB set types are now returned as JavaScript Set's instead of Array's
  • DynamoDB set types are now defined as {"type": Set, "schema": [String]} as opposed to the former [String] or {"type": [String]}. This is more explict and makes it more clear that the type is a set.
  • Trying to save a Document with a property set to null will now throw an error. If you would like to remove the property set it to dynamoose.UNDEFINED to set it to undefined without taking into account the default setting, or undefined to set it to undefined while taking into account the default setting.
  • Model update setting now includes more update actions. To use the v1 update behavior change the value of update setting to be ["ttl", "indexes"].
  • Schema default value does not pass the model instance into default functions any more.
  • Model.update
    • $LISTAPPEND has been removed, and $ADD now includes the behavior of $LISTAPPEND
    • $DELETE has been renamed to $REMOVE
    • $REMOVE (previously $DELETE) now maps to the correct underlying DynamoDB method instead of the previous behavior of mapping to $REMOVE
    • $PUT has been replaced with $SET
  • Model.getTableReq has been renamed to Model.table.create.request
  • Model.table.create.request (formerly Model.getTableReq) is now an async function
  • model.originalItem has been renamed to model.original (or Document.original)
  • Document.original formerly (model.originalItem) no longer returns the last item saved, but the item first retrieved from DynamoDB
  • The following Schema settings have been moved to Model settings:
    • expires
    • throughput
  • expires.ttl now accepts a number representing milliseconds as opposed to seconds
  • expires.defaultExpires is no longer an option (most behavior from this option can be replicated by using the new dynamoose.UNDEFINED feature)
  • expires.returnExpiredItems has been renamed to expires.items.returnExpired
  • Model.transaction.conditionCheck has been renamed to Model.transaction.condition
  • Model.transaction.condition now accepts a conditional instance instead of an object to specify the conditional you wish to run
  • In the past the saveUnknown option for attribute names would handle all nested properties. Now you must use * to indicate one level of wildcard or ** to indicate infinate levels of wildcard. So if you have an object property (address) and want to parse one level of values (no sub objects) you can use address.*, or address.** to all for infinate levels of values (including sub objects)
  • In the past non-string type properties would be implicitly coerced into strings with a call to their toString() methods when saved as String type attributes. This will now throw a TypeMismatch error. Strings should be converted before saving.
  • useNativeBooleans & useDocumentTypes have been removed from the Model settings
  • scan.count() has been removed, and scan.counts() has been renamed to scan.count().
  • The attribute types Array & Object in Dynamoose v1 don't work without a schema option in v2
  • Scan.null & Query.null have been removed. In most cases this can be replaced with .not().exists().
  • Expires TTL value is set to be a default value. In Dynamoose v1 there were cases where expires TTL wouldn't be set, in Dynamoose v2, the behavior of if the Expires TTL is set behaves the same as any default value
  • Custom methods have changed behavior:
    • schema.method is now model.methods.document
    • schema.statics is now model.methods
    • Both model.methods & model.methods have two functions that you call to add & remove methods. set & delete methods exist on both objects that you can use to add your methods. This is compared to the old system of calling the function for schema.method or setting the object for schema.statics.

Features Removed to be Readded Later

  • TypeScript Support (v2.1.0) (coming soon, see more information here)
  • Model.populate
  • Plugin Support

Bug Fixes

  • Fixed issue where objects would get stored as a string [object Object] instead of the actual object

Documentation

  • Documentation has been rewritten from the ground up to be more clear and provide more examples

Other

  • Dynamoose logo now included in internal folder
  • More automated tests which leads to more stablity for Dynamoose (100% code coverage)
  • More resources/documentation have been added regarding project structure
    • Code of Conduct (CODE_OF_CONDUCT.md)
    • Contributing Guidelines (CONTRIBUTING.md)
  • Improvements to README
    • More badges about project state
    • More information relevant to repository (branch strategy, etc)

1.11.1 (2019-09-05)

Bug Fixes

  • fixing model.transaction.conditioncheck (cc04bee), closes #539

1.11.0 (2019-08-25)

Bug Fixes

  • plugin: solve problem with rejecting during batchput:called (be01f8c)
  • plugin: solve problem with rejecting during update:called (959ba8c)

Features

  • plugin: add batchPut events (501c689)
  • plugin: add update events (78e8538)

1.10.0 (2019-06-28)

Features

  • scan: add Scan.using() for scanning sparse secondary indexes (cfb5614)

1.9.0 (2019-06-27)

Features

  • schema: change the way attributes are set by parseDynamo function (b8d1737)

1.8.5 (2019-06-25)

Bug Fixes

  • schema: fixed circular reference with JSON.stringify in Schema (3f614f0)

1.8.4 (2019-06-23)

Bug Fixes

  • change originalItem from being static (44a5b6b)

1.8.3 (2019-06-22)

Bug Fixes

  • types: add property to interface (0c05751), closes #617

1.8.2 (2019-06-22)

Bug Fixes

  • dynamoose.ts.d: Add/fix TypeScript types (e7472a7)

1.8.1 (2019-06-22)

Bug Fixes

  • types: added streamOptions to ModelOption (a85780a)

1.8.0 (2019-06-11)

Features

  • plugin: item prop for model:put put:called (5043cf3)

1.7.3 (2019-05-15)

Bug Fixes

  • model: allows string for array attribute in contains condition (f68c13a)

1.7.2 (2019-03-18)

Bug Fixes

1.7.1 (2019-03-18)

Bug Fixes

  • naming: remove extension from name (ca346d0)

1.7.0 (2019-03-18)

Features

  • ts: adding ts testing, compiling and exports (0d2ef68)
  • ts: fix ci script to also lint typescript (992c7ff)
  • ts: fixing spelling (e087570)

1.6.5 (2019-03-03)

Bug Fixes

  • comment: fix comments in pr (68d757b)
  • index: fixing styling and content (75ea512)

1.6.4 (2019-02-19)

Bug Fixes

  • stop conditions being overwritten (966d7bc)
  • lint: increase limit for Model test file (907b8a6)

1.6.3 (2019-02-18)

Bug Fixes

  • model: fixing batchDelete syntax bug (dfb448f)
  • model: fixing update and condition check syntax bug (74623bf)

1.6.2 (2019-02-13)

Bug Fixes

  • saveunknown: fixing saveunknown toDynamo for maps (873a6ed), closes #323

Version 1.5.2

This is a minor bug fix for Plugins, and also adds some other improvements for plugins and other parts of the app.

Please comment or contact me if you have any questions about this release.

General


Version 1.5.1

This is a minor release with documentation and project improvements.

Please comment or contact me if you have any questions about this release.

Documentation

Other


Version 1.5.0

This release adds support for list_append when adding elements to a list using the Model.update method.

Please comment or contact me if you have any questions about this release.

General


Version 1.4.0

This version adds some more options to the model and schema options objects.

Please comment or contact me if you have any questions about this release.

General


Version 1.3.1

Just a simple bug fix release!

Please comment or contact me if you have any questions about this release.

Bug Fixes

Documentation

Other


Version 1.3.0

Dynamoose Version 1.3.0 finishes implementation of some important features (DynamoDB transaction support, and pay per request billing mode), improves the overall stability of the project (reduces NPM package size, bug fixes, throwing more errors), along many more improvements.

Please comment or contact me if you have any questions about this release.

General

Bug Fixes

Other

Documentation


Version 1.2.0

AWS reInvent 2018 has wrapped up, and this release includes support for all of the DynamoDB goodies announced. This version also includes beta support for plugins! Plugin support has the potential to have breaking changes in the future with no warning, so please be aware of that when using the system. Please give feedback on plugins by creating issues on the Dynamoose repository.

Please comment or contact me if you have any questions about this release.

Major New Features

General

Bug Fixes

Other


Version 1.1.0

Dynamoose version 1.1.0 has a few improvements for debugging Dynamoose as well as a few new features.

Please comment or contact me if you have any questions about this release.

General


Version 1.0.1

Dynamoose version 1.0.1 comes with some minor bug fixes to solve problems with Dynamoose version 1.0.0. We are actively monitoring the GitHub Issues and will continue to work to provide bug fixes as fast as possible. Please create a GitHub Issue or contact me if you are having problems and we will work to address it as fast as possible.

Bug Fixes

Documentation


Version 1.0.0

Dynamoose version 1.0.0 is here. This is a massive release, and will also be the first official breaking update to Dynamoose. You can view the details about the release below.

This version officially removes support for Node.js versions below 8.0. Versions below 8.0 might work, but we do not make guarantees. Even if Node.js versions below 8.0 work with Dynamoose 1.0+ we might add features that break support for older Node.js versions without a SEMVER major version release.

The one major thing about the release notes below that is a bit confusing is the fact that ES6/Future Changes are in the Breaking changes section. That section is directly related to Requiring Node.js version 8.0 and higher. Therefor although the breaking change is technically the fact that Node.js versions less than 8.0 won't be supported, they are directly related, therefor they are both in the Breaking changes section. In future 1.x we might add more ES6/Future Changes, but those will not be considered breaking changes due to the fact that it will only break if you are running on a Node.js version less than version 8.0.

Please comment or contact me if you have any questions about this release.

🚨 Breaking changes 🚨

Major New Features

General

Bug Fixes

Documentation

Other


Version 0.8.7

Version 0.8.7 is here! Below is a list of the changes released in Version 0.8.7. Huge THANK YOU to everyone who submitted pull requests and issues in this release. As always keep the issues and pull requests coming, only makes this package better!!

Major New Features

General

Documentation

Testing

TypeScript Improvements


0.8.0

  • useNativeBooleans #55
  • saveUnknown #125
  • Support for multiple indexes defined on the hashkey attribute of the table
  • scan.all() #93 #140
  • scan.parallel d7f7f77
  • TTL support 92994f1
  • added schema parsing overrides #145
  • populate #137
  • Added consistent() to scan. #15 #142
  • Default function enhancements #127
  • Create required attributes on update #96
  • Add typescript typings #123
  • Added .count() for Query and Scan #101
  • Nested scans #141 #158