Skip to content

Commit

Permalink
Release 2.4.0
Browse files Browse the repository at this point in the history
Updated version numbers & the compatibility.md table

Signed-off-by: Matthew B White <[email protected]>
  • Loading branch information
mbwhite authored and jt-nti committed Nov 26, 2021
1 parent c4fe3c1 commit 5a4d075
Show file tree
Hide file tree
Showing 26 changed files with 215 additions and 199 deletions.
9 changes: 5 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
## 2.4.0
Fri Nov 26 08:07:34 GMT 2021

Release 2.4.0

## v2.4.0-beta
Wed 18 Aug 2021 12:11:16 BST

* [d98e77b](https://github.com/hyperledger/fabric-chaincode-node/commit/d98e77b) updated documentation for getStateByPartialCompositeKey, getStateByPartialCompositeKeyWithPagination and getPrivateDataByPartialCompositeKey
* [c982390](https://github.com/hyperledger/fabric-chaincode-node/commit/c982390) Disable server tests
* [556f32a](https://github.com/hyperledger/fabric-chaincode-node/commit/556f32a) Metadata generate updated [FABCN-447](https://jira.hyperledger.org/browse/FABCN-447) (#276)
* [2bd68fd](https://github.com/hyperledger/fabric-chaincode-node/commit/2bd68fd) Shebang issue fixed [FABCN-438](https://jira.hyperledger.org/browse/FABCN-438) (#271)
* [1d43015](https://github.com/hyperledger/fabric-chaincode-node/commit/1d43015) Pipeline publishing fixed (#273)
Expand All @@ -19,9 +23,6 @@ Wed 18 Aug 2021 12:11:16 BST
* [52d8638](https://github.com/hyperledger/fabric-chaincode-node/commit/52d8638) Move azure variable to env variable
* [b1991a6](https://github.com/hyperledger/fabric-chaincode-node/commit/b1991a6) Add in the missing dependency, adjust find command" (#256)
* [b1bb93c](https://github.com/hyperledger/fabric-chaincode-node/commit/b1bb93c) Remove incorrect condition placement
* [7565306](https://github.com/hyperledger/fabric-chaincode-node/commit/7565306) replicate template
* [3ed241d](https://github.com/hyperledger/fabric-chaincode-node/commit/3ed241d) Use templates
* [5e0c543](https://github.com/hyperledger/fabric-chaincode-node/commit/5e0c543) Simplify Naming
* [54c27e7](https://github.com/hyperledger/fabric-chaincode-node/commit/54c27e7) Move to use NPM directly
* [4510e67](https://github.com/hyperledger/fabric-chaincode-node/commit/4510e67) Adjust NPM repo URL
* [2017002](https://github.com/hyperledger/fabric-chaincode-node/commit/2017002) Provide Nightly publishing of drivers
Expand Down
19 changes: 11 additions & 8 deletions COMPATIBILITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,13 @@ Github is used for code base management, issues should reported in the [FABCN](h

This table shows the summary of the compatibility of the Node modules at versions 1.4 and 2.x, together with the Nodejs runtime they require and the Fabric Peer versions they can communicate with.

| | Peer Connectivity v1.4 | NodeJS | Peer Connectivity v2.x |
| ----------------------- | ---------------------- | ------ | ---------------------- |
| Node modules **v1.4.5** | Yes | 8 | Yes |
| Node modules **v2.x.x** | Yes | 12 | Yes |
| | Peer Connectivity v1.4 | NodeJS | Peer Connectivity v2.x |
| ------------------------------ | ---------------------- | ------ | ---------------------- |
| Node modules **v1.4.5** | Yes | 8 | Yes |
| Node modules **v2.2.x/v2.3.x** | Yes | 12 | Yes |
| Node modules **v2.4.x** | Yes | 16 | Yes |

By default a Fabric Peer v1.4 will create a Nodejs v8 runtime, and a Fabric Peer v2.x will create a Nodejs 12 runtime. Whilst this is the default, the docker image used to host the chaincode and contracts can be altered. Set the environment variable `CORE_CHAINCODE_NODE_RUNTIME` on the peer to the name of the docker image.
By default a Fabric Peer v1.4 will create a Nodejs v8 runtime, and a Fabric Peer v2.2/2.3 will create a Nodejs 12 runtime. The Fabric v2.4 will create a Nodejs 16 runtime. Whilst these are defaults, the docker image used to host the chaincode and contracts can be altered. Set the environment variable `CORE_CHAINCODE_NODE_RUNTIME` on the peer to the name of the docker image.

For example `CORE_CHAINCODE_NODE_RUNTIME=hyperledger/fabric-nodeenv:2.1` will allow the use of the latest Node 12 runtime to be used within a Peer v1.4.

Expand All @@ -22,7 +23,7 @@ Note that the `fabric-contract-api` & `fabric-shim` node modules must be at v1.4

## Compatibility

The key elements are : 
The key elements are :

- the version of the Fabric Contract Node modules used
- the version of the Nodejs runtime used to run the code
Expand All @@ -36,15 +37,17 @@ Node modules that are produced are `fabric-contract-api`, `fabric-shim`, `fabric

### Supported Runtimes

v2.x Node modules are supported running in Nodejs 12.16.1, with the x86_64 architecture.
v2.4 Node modules are supported running in Nodejs 16.4.0, with the x86_64 architecture.

v2.2/2.3 Node modules are supported running in Nodejs 12.16.1, with the x86_64 architecture.

v1.4.x Node modules are supported running Nodejs 8.16.1 with the x86_64 architecture.

Architecture Support: all docker images, runtimes, tools are tested under x86_64 ONLY

### Default Peer Runtime selection

When using Fabric 2.x, the default docker image that is used to run the Node chaincode is node:12.16.1-alpine 
When using Fabric 2.2/2.3x the default docker image that is used to run the Node chaincode is node:12.16.1-alpine. With Fabric 2.4 the default docker image is node:16.4.0-alpine

*Note:* With the default docker image used by Fabric 2.x, the packaged code will be installed with npm. If a `package-lock.json` or a `npm-shrinkwrap.json` file is present, `npm ci --only=production` will be used. Otherwise `npm install --production` will be used. 

Expand Down
8 changes: 4 additions & 4 deletions apis/fabric-contract-api/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "fabric-contract-api",
"version": "2.4.0-beta",
"tag": "beta",
"version": "2.4.0",
"tag": "release",
"description": "A node.js implementation of Hyperledger Fabric chaincode shim, to allow endorsing peers and user-provided chaincodes to communicate with each other",
"main": "index.js",
"repository": {
Expand Down Expand Up @@ -46,7 +46,7 @@
"lines": 100
},
"dependencies": {
"fabric-shim-api": "2.4.0-beta",
"fabric-shim-api": "2.4.0",
"class-transformer": "^0.4.0",
"fast-safe-stringify": "^2.1.1",
"get-params": "^0.1.2",
Expand All @@ -56,7 +56,7 @@
"devDependencies": {
"ajv": "^6.12.2",
"ajv-cli": "^3.2.1",
"ajv-formats":"2.1.1",
"ajv-formats": "2.1.1",
"chai": "^4.3.4",
"chai-as-promised": "^7.1.1",
"chai-things": "^0.2.0",
Expand Down
6 changes: 3 additions & 3 deletions apis/fabric-shim-api/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "fabric-shim-api",
"version": "2.4.0-beta",
"tag": "beta",
"version": "2.4.0",
"tag": "release",
"description": "A node.js API of Hyperledger Fabric chaincode shim, to allow endorsing peers and user-provided chaincodes to communicate with each other",
"main": "index.js",
"repository": {
Expand All @@ -26,4 +26,4 @@
"devDependencies": {
"@types/long": "^4.0.1"
}
}
}
4 changes: 2 additions & 2 deletions docker/fabric-nodeenv/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "fabric-nodeenv",
"version": "2.4.0-beta",
"version": "2.4.0",
"description": "",
"main": "docker.js",
"scripts": {
Expand All @@ -11,6 +11,6 @@
"license": "Apache-2.0",
"dependencies": {
"git-rev-sync": "3.0.1",
"toolchain": "1.0.0"
"toolchain": "2.4.0"
}
}
6 changes: 3 additions & 3 deletions docs/package.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{
"name": "fabric-shim-docs",
"version": "2.4.0-beta",
"version": "2.4.0",
"description": "",
"private": true,
"scripts": {
"build": "npm run docs",
"docs": "rimraf ./gen && jsdoc -c ./_jsdoc.json"
},
"dependencies": {
"fabric-ledger": "2.4.0-beta"
"fabric-ledger": "2.4.0"
},
"devDependencies": {
"ink-docstrap": "^1.3.2",
Expand All @@ -18,4 +18,4 @@
"keywords": [],
"author": "",
"license": "Apache-2.0"
}
}
4 changes: 2 additions & 2 deletions libraries/fabric-ledger/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "fabric-ledger",
"version": "2.4.0-beta",
"version": "2.4.0",
"tag": "unstable",
"description": "A node.js implementation of Hyperledger Fabric ledger api, to allow access to ledger data from smart contracts",
"main": "lib/index.js",
Expand Down Expand Up @@ -49,7 +49,7 @@
"lines": 100
},
"dependencies": {
"fabric-contract-api": "2.4.0-beta",
"fabric-contract-api": "2.4.0",
"winston": "^3.3.3"
},
"devDependencies": {
Expand Down
114 changes: 57 additions & 57 deletions libraries/fabric-shim-crypto/package.json
Original file line number Diff line number Diff line change
@@ -1,60 +1,60 @@
{
"name": "fabric-shim-crypto",
"version": "2.4.0-beta",
"tag": "beta",
"description": "A node.js implementation of encryption library for Hyperledger Fabric chaincode shim",
"main": "index.js",
"repository": {
"type": "git",
"url": "https://github.com/hyperledger/fabric-chaincode-node"
},
"scripts": {
"test": "nyc mocha --recursive 'test/**/*.js' --reporter spec-junit-splitter-mocha-reporter",
"lint":"eslint ./lib/",
"build": "npm run lint && npm test"
},
"keywords": [
"fabric-shim",
"fabric-shim-crypto",
"Hyperledger Fabric",
"Fabric Shim"
"name": "fabric-shim-crypto",
"version": "2.4.0",
"tag": "release",
"description": "A node.js implementation of encryption library for Hyperledger Fabric chaincode shim",
"main": "index.js",
"repository": {
"type": "git",
"url": "https://github.com/hyperledger/fabric-chaincode-node"
},
"scripts": {
"test": "nyc mocha --recursive 'test/**/*.js' --reporter spec-junit-splitter-mocha-reporter",
"lint": "eslint ./lib/",
"build": "npm run lint && npm test"
},
"keywords": [
"fabric-shim",
"fabric-shim-crypto",
"Hyperledger Fabric",
"Fabric Shim"
],
"engines": {
"node": "^16.4.0",
"npm": "^8.0.0"
},
"license": "Apache-2.0",
"dependencies": {
"elliptic": "^6.5.4",
"jsrsasign": "^10.4.1"
},
"devDependencies": {
"mocha": "9.1.3",
"eslint": "^6.6.0",
"nyc": "15.1.0",
"typescript": "4.4.4",
"chai": "^4.3.4",
"chai-as-promised": "^7.1.1",
"rewire": "5.0.0",
"sinon": "11.1.2",
"chai-things": "^0.2.0",
"spec-junit-splitter-mocha-reporter": "1.0.1"
},
"nyc": {
"exclude": [
"coverage/**",
"test/**"
],
"engines": {
"node": "^16.4.0",
"npm": "^8.0.0"
},
"license": "Apache-2.0",
"dependencies": {
"elliptic": "^6.5.4",
"jsrsasign": "^10.4.1"
},
"devDependencies": {
"mocha": "9.1.3",
"eslint": "^6.6.0",
"nyc": "15.1.0",
"typescript": "4.4.4",
"chai": "^4.3.4",
"chai-as-promised": "^7.1.1",
"rewire": "5.0.0",
"sinon": "11.1.2",
"chai-things": "^0.2.0",
"spec-junit-splitter-mocha-reporter": "1.0.1"
},
"nyc": {
"exclude": [
"coverage/**",
"test/**"
],
"reporter": [
"text-summary",
"cobertura",
"html"
],
"all": true,
"check-coverage": true,
"statements": 100,
"branches": 100,
"functions": 100,
"lines": 100
}
"reporter": [
"text-summary",
"cobertura",
"html"
],
"all": true,
"check-coverage": true,
"statements": 100,
"branches": 100,
"functions": 100,
"lines": 100
}
}
8 changes: 4 additions & 4 deletions libraries/fabric-shim/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "fabric-shim",
"version": "2.4.0-beta",
"tag": "beta",
"version": "2.4.0",
"tag": "release",
"description": "A node.js implementation of Hyperledger Fabric chaincode shim, to allow endorsing peers and user-provided chaincodes to communicate with each other",
"main": "index.js",
"bin": {
Expand Down Expand Up @@ -59,8 +59,8 @@
"@grpc/proto-loader": "^0.6.6",
"@types/node": "^16.11.1",
"ajv": "^6.12.2",
"fabric-contract-api": "2.4.0-beta",
"fabric-shim-api": "2.4.0-beta",
"fabric-contract-api": "2.4.0",
"fabric-shim-api": "2.4.0",
"fs-extra": "^10.0.0",
"reflect-metadata": "^0.1.13",
"winston": "^3.3.3",
Expand Down
12 changes: 12 additions & 0 deletions release_notes/v2.4.0.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
v2.4.0
------

Release Notes
-------------
This v2.4.0 Release is a bug fix release of the main branch.

Note that version of Node.js is updated to 16.4.0. See the COMPATIBILITY.md file in the main branch for information.

Change Log
----------
https://github.com/hyperledger/fabric-chaincode-node/blob/release-2.x/CHANGELOG.md#v2.4.0-beta
6 changes: 3 additions & 3 deletions test/chaincodes/annotations/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@
"typings": "dist/index.d.ts",
"engine-strict": true,
"engineStrict": true,
"version": "1.0.0",
"version": "2.4.0",
"author": "",
"license": "APACHE-2.0",
"dependencies": {
"@types/node": "^16.11.4",
"fabric-contract-api": "2.4.0-beta",
"fabric-shim": "2.4.0-beta",
"fabric-contract-api": "2.4.0",
"fabric-shim": "2.4.0",
"ts-node": "^3.3.0",
"tslint": "^5.6.0",
"typescript": "^4.0.2"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@
}
},
"info": {
"version": "1.0.0",
"version": "2.4.0",
"title": "ts_chaincode"
},
"components": {
Expand Down
38 changes: 19 additions & 19 deletions test/chaincodes/clientidentity/package.json
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
{
"name": "chaincode",
"description": "Chaincode testing ClientIdentity functionality",
"engines": {
"node": "^12.16.1",
"npm": "^6.4.1"
},
"scripts": {
"start": "fabric-chaincode-node start"
},
"main": "index.js",
"engine-strict": true,
"engineStrict": true,
"version": "1.0.0",
"author": "",
"license": "Apache-2.0",
"dependencies": {
"fabric-shim": "2.4.0-beta",
"fabric-contract-api": "2.4.0-beta"
}
"name": "chaincode",
"description": "Chaincode testing ClientIdentity functionality",
"engines": {
"node": "^12.16.1",
"npm": "^6.4.1"
},
"scripts": {
"start": "fabric-chaincode-node start"
},
"main": "index.js",
"engine-strict": true,
"engineStrict": true,
"version": "2.4.0",
"author": "",
"license": "Apache-2.0",
"dependencies": {
"fabric-shim": "2.4.0",
"fabric-contract-api": "2.4.0"
}
}
Loading

0 comments on commit 5a4d075

Please sign in to comment.