Releases: typedb/typedb-driver-nodejs
TypeDB Client Node.js 2.18.2
NPM package: https://www.npmjs.com/package/typedb-client
Documentation: https://docs.vaticle.com/docs/client-api/nodejs
Installation
npm install typedb-client@2.18.2
New Features
Bugs Fixed
- Fix NPM deployment pipeline
Code Refactors
Other Improvements
TypeDB Client Node.js 2.18.1
NPM package: https://www.npmjs.com/package/typedb-client
Documentation: https://docs.vaticle.com/docs/client-api/nodejs
Installation
npm install typedb-client@2.18.1
New Features
-
Introduce Values to support expressions
Introduce the 'Value' type, which is returned as the result of an expression's computation. This change follows from typedb/typeql#260, which outlines the capabilities of the new expression syntax.
Values (representing any of Long, Double, Boolean, String, or DateTime) are returned as part of
ConceptMap
answers and are subtypes ofConcept
for the time being. Their main API is made of the.getValue()
method and.getValueType()
method, along with all the standard safe downcasting methods to convert aConcept
into aValue
, usingConcept.isValue()
andConcept.asValue()
.We also move the import location of
ValueType
from being nested inAttributeType
toConcept
, and we remove the -
Support generalised annotations and uniqueness
We update the Typedb Protocol and TypeQL to the latest versions, which support the uniqueness annotation and generalised
Type
APIs. These generalised APIs allow querying by a set of annotations, rather than just boolean =true|false
.For example, the API:
AttributeType.getOwners(onlyKey: boolean)
has become:AttributeType.getOwners(annotations: Annotation[])
All usages of boolean flags to indicate key-ness should be replaced by using arrays of
ThingType.Annotation.KEY
. The new@unique
annotation is available asThingType.Annotations.UNIQUE
, and is usable within all the APIs that accept array of annotations. -
Add method to Cluster client to retrieve current user
Add an API to be able retrieve the currently authenticated user.
Bugs Fixed
Code Refactors
-
Protocol versioning
We use a new protocol API to perform a "connection open". This API does server-side protocol version compatibility checks, and replaces our previous need to get all databases to check that the connection is available.
The
TypeDB.coreClient()
entry point now must beawait
ed, the same as theTypeDB.clusterClient
entry point.
Other Improvements
-
Update release notes workflow
We integrate the new release notes tooling. The release notes are now to be written by a person and committed to the repo.
-
Make unimplemented error message more friendly
TypeDB Client Node.js 2.17.0
NPM package: https://www.npmjs.com/package/typedb-client
Documentation: https://docs.vaticle.com/docs/client-api/nodejs
Installation
npm install typedb-client@2.17.0
New Features
-
Concept map JSON serialization
We implement the JSON serialization of concept maps according to typedb/typedb-behaviour#238.
Bugs Fixed
Code Refactors
-
Define password expiry in terms of seconds
We've redefined the way we expose how long until a password expires in seconds, rather than days as was done previously.
-
JSON serialization fixes
We update serialization API from
JSON()
to more canonicaltoJSONRecord()
* and update the BDD test steps to reflect the changes in typedb-behaviour (typedb/typedb-behaviour#240).* We're avoiding
toJSON()
as it is reserved by JavaScript for built-in JSON serialization. Since our JSON representation is lossy, we'd like the user to be explicit in their intent.
Other Improvements
-
Update VERSION to 2.17.0
-
Add @flyingsilverfin to CODEOWNERS
-
Fix CODEOWNERS format
TypeDB Client Node.js 2.16.1
NPM package: https://www.npmjs.com/package/typedb-client
Documentation: https://docs.vaticle.com/docs/client-api/nodejs
Installation
npm install typedb-client@2.16.1
New Features
-
Cluster password policy and user management support
Add functionality relevant to the changes made in typedb/typedb-cluster#456:
- Optional password expiry in days for each user.
- The ability for admins to set passwords of other users
- User password update, which requires old and new password
Bugs Fixed
Code Refactors
Other Improvements
-
Update @vaticle_dependencies
-
Use username/password auth for npm snapshots
-
Update VERSION to 2.16.1
TypeDB Client Node.js 2.14.2
NPM package: https://www.npmjs.com/package/typedb-client
Documentation: https://docs.vaticle.com/docs/client-api/nodejs
Installation
npm install typedb-client@2.14.2
New Features
-
Update to TypeDB 2.14 and add new RoleType methods and ThingType.getSyntax
We updated to the latest TypeDB protocol (2.14.x), added new
RoleType
methods andThingType.getSyntax
.
Bugs Fixed
-
Fix deploy-npm-snapshot CI job
Fix the deploy-npm-snapshot Grabl CI job that was failing due to Ubuntu 21.04 repositories being archived. The Ubuntu image got downgraded to 20.04 LTS. Additionally, we found out that the installation of
expect
is not necessary.
Code Refactors
-
Uncomment Vaticle Cluster CI jobs
Uncomment the Vaticle Cluster CI jobs to keep the Grabl's automation.yml file clean.
Other Improvements
-
Bump typedb-protocol to 2.14.1
-
Factory migration
We've migrated from grabl to Factory.
-
Extend license checkstyle tests and update licenses
We introduce a test that ensures that the license text is correct.
TypeDB Client Node.js 2.11.1
NPM package: https://www.npmjs.com/package/typedb-client
Documentation: https://docs.vaticle.com/docs/client-api/nodejs
Installation
npm install typedb-client@2.11.1
New Features
Bugs Fixed
-
Fix memory leak in long-running sessions
A long running session used to keep the reference to each closed transaction, continually growing in size. These references are inaccessible from outside the session object. The problem was compounded in the write transactions, when the caller did not collect the responses received after insert queries, which were held onto by the closed transaction objects.
We now dispose of the closed transaction objects and free their memory.
-
When streaming, assume network latency >=1ms
When streaming (e.g.
match
queries), we now assume the network latency is >=1ms, and have the server compensate accordingly. This sharply improves performance (up to 3x) when fetching answers from a server hosted atlocalhost
.
Code Refactors
Other Improvements
-
bump VERSION to 2.11.1
-
Bump copyright year to 2022
We update the copyright header year to 2022.
-
Update @vaticle_typedb_common
-
Update @vaticle_dependencies
TypeDB Client Node.js 2.9.0
NPM package: https://www.npmjs.com/package/typedb-client
Documentation: https://docs.vaticle.com/docs/client-api/nodejs
Installation
npm install typedb-client@2.9.0
New Features
- Define BDD test steps for extended Type Concept API
We define the functions corresponding to the BDD test steps introduced for the extended Type Concept API.
- Extend concept type API
We catch up client-nodejs with the Java client version 2.9.0, which exposes an extended set of APIs on Type
s.
We implement:
ThingType.getOwnsExplicit()
andThingType.getOwnsOverridden
AttributeType.getOwnersExplicit()
ThingType.getPlaysExplicit()
ThingType.getPlaysOverridden()
RelationType.getRelatesExplicit()
andRelationType.getRelatesOverridden()
Bugs Fixed
Code Refactors
Other Improvements
-
bump VERSION to 2.9.0
-
Update artifacts.bzl
-
Bump typedb-behaviour to test extended Type API
-
Upgrade to Bazel 5
Make the repository use Bazel 5. Bazel 4 and below only work with the deprecated Python 2, which is no longer included in some operating systems such as the latest Mac OS X.
TypeDB Client Node.js 2.8.0
NPM package: https://www.npmjs.com/package/typedb-client
Documentation: https://docs.vaticle.com/docs/client-api/nodejs
Installation
npm install typedb-client@2.8.0
New Features
Bugs Fixed
Code Refactors
- **Query iterator only throws exeption once **
Revert previous changes from #202, which made query queues and iterators throw the same error idempotently. However, this goes counter to standard usage of iterators and queues, which are not meant to behave idempotently (each item is only returned once, and if they have an error they should no longer be used).
Other Improvements
-
Bump VERSION to 2.8.0
-
Bazel Cache is disabled temporarily until SSL is fixed
TypeDB Client Node.js 2.6.2
NPM package: https://www.npmjs.com/package/typedb-client
Documentation: https://docs.vaticle.com/docs/client-api/nodejs
Installation
npm install typedb-client@2.6.2
New Features
Bugs Fixed
- Don't delete response collectors in a transaction
We no longer delete response collectors in a transaction after receiving a response to a "single" request, or receiving a "DONE" message in a stream. This fixes a possible error when loading 50+ answers in one query and then performing a second query.
Code Refactors
- Store error on transaction stream and clean up completed query state
Multiplexed query streams over the transaction stream are cleaned up when complete. We also store any exceptions received against the transaction stream (as well as query streams) in order to propagate the error to any future transaction operations, not just open query streams.
Other Improvements
- Update ResponseCollector terminology to match other clients
TypeDB Client Node.js 2.6.1
NPM package: https://www.npmjs.com/package/typedb-client
Documentation: https://docs.vaticle.com/docs/client-api/nodejs
Installation
npm install typedb-client@2.6.1
New Features
- Implement and test configurable transaction timeouts
Transactions now have a transaction timeouts, which are configurable via transaction options (typedb/typedb#6487). We implemented the new transaction option, and test them via new BDD scenarios. This also caused us to simplify and make more obvious when transaction errors occur when using an open transaction.
Bugs Fixed
Code Refactors
Other Improvements
-
Update create notes token
-
Fix deployment failure due to wrong auth token
We fixed a deployment failure that was occurring because of an incorrect auth token parameter being passed to //:deploy-npm
.
- Upgrade dependencies
We upgraded dependencies
to the latest version.
- Fix failing npm deployment
We fixed an issue in the deploy_npm
build tool causing npm deployments to fail.
- Upgrade Bazel to v4.0.0
We upgraded Bazel to v4.0.0 to align with our other projects.
-
Automation yaml npm snapshot release uses snapshot repo token
-
Update @vaticle_dependencies
-
Update deploy NPM CI jobs
-
fix automation yaml
-
temporarily disable failing cluster tests and update VERSION to 2.6.1
-
Update build jobs to use Ubuntu 21.04
-
Revert "Update build jobs to use Ubuntu 21.04"
-
Update build jobs to use Ubuntu 21.04
-
Update yarn.lock
-
Update @vaticle_dependencies and the release notes creation script