Node 20+ is now required. This is the oldest currently support LTS
version of Node.js.
Docker images are moved to Node 22, which is the current LTS release.
Signed-off-by: Mark S. Lewis <Mark.S.Lewis@outlook.com>
The latest fabric-gateway client API release (v1.7.0) includes the gRPC error
details in the GatewayExcetion stack trace so it is not necessary to
programmatically access them to demonstrate that they are present.
This change updates the asset-transfer-basic/application-gateway-java
sample to simplify the updateNonExistentAsset example method. It also:
- Updates all samples to use the latest fabric-gateway release.
- Adds equivalent Maven POM files for fabric-gateway application samples.
Signed-off-by: Mark S. Lewis <Mark.S.Lewis@outlook.com>
The repository currently uses Go 1.22 to test samples in the automated
build. This change sets the Go version in all go.mod (and go.work) files
to Go 1.22.0, and removes any Go toolchain entries.
Signed-off-by: Mark S. Lewis <Mark.S.Lewis@outlook.com>
For some signing implementations, such as ed25519, a non-default hash
implementation must be specified when creating the Gateway connection in
client applications. Rather than relying on the default hash algorithm,
it is probably good practice in general to specify an algorithm that is
compatible with your signing implementation.
This change explicitly specifies the hash algorithm to raise visibility
of the option to select the hash algorithm.
Signed-off-by: Mark S. Lewis <Mark.S.Lewis@outlook.com>
The removed samples make use of deprecated legacy client SDKs. They all
have equivalent samples implemented using the currently supported Fabric
Gateway client API, and are therefore redundant.
Signed-off-by: Mark S. Lewis <Mark.S.Lewis@outlook.com>
- Dependency updates
- ESLint flat configuration format, replacing deprecated configuration
- Minor fixes to compile and lint issues
- Consistent TypeScript formatting with .editorconfig
Signed-off-by: Mark S. Lewis <Mark.S.Lewis@outlook.com>
Allow client applications to work regardless of whether network was creating using a CA or cryptogen since they create different client certificate file names.
Signed-off-by: Mark S. Lewis <Mark.S.Lewis@outlook.com>
Ensure that all sample applications return exit code 1 upon failure
so that github actions can report the failure.
Signed-off-by: David Enyeart <enyeart@us.ibm.com>
* Update go dependencies
Update go dependencies in sample chaincodes and applications
Signed-off-by: David Enyeart <enyeart@us.ibm.com>
* Update to Go 1.19.6
Update to Go 1.19.6
Signed-off-by: David Enyeart <enyeart@us.ibm.com>
---------
Signed-off-by: David Enyeart <enyeart@us.ibm.com>
Rely on the dependencies of @hyperledger/fabric-gateway making these packages transitively available. Having explicit dependency versions in the application can cause type conflicts due to private member changes in the gRPC Client class across versions.
Also fix some missing or incorrect Node types and engines version contraints.
Signed-off-by: Mark S. Lewis <mark_lewis@uk.ibm.com>
* fixed comment consistency problem with erc20 chaincode
Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>
* added more comment consistancy fix
Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>
* added more comment consistancy fix
Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>
* added more comment consistancy fix
Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>
* added more comment consistancy fix
Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>
Signed-off-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>
Co-authored-by: Ali Shahverdi <ali@Alis-MacBook-Pro.local>
* Refactor Go files
1. replace deprecated ioutil functions (ioutil is deprecated since Go 1.16)
2. fix variable names that collide with imported package name
3. fix typos
Also update Go version specified by Go modules to ensure a Go version is used in which ioutil is deprecated and replacement functions are available in os and io packages.
Signed-off-by: Tommy TIAN <xtianae@connect.ust.hk>
Co-authored-by: Mark S. Lewis <mark_lewis@uk.ibm.com>
* Specify go 1.18 instead of go 1.19 in go.mod files
Signed-off-by: Mark S. Lewis <mark_lewis@uk.ibm.com>
Signed-off-by: Tommy TIAN <xtianae@connect.ust.hk>
Signed-off-by: Mark S. Lewis <mark_lewis@uk.ibm.com>
Co-authored-by: Tommy TIAN <xtianae@connect.ust.hk>
A recent commit added the potential buyer to an asset's state based endorsement policy.
That change was problematic because if the transfer fell through, the buyer lost control of the asset,
in that they could no longer update the asset or change the sell price or sell to somebody else.
The asset state based endorsement policy is now based on the seller only, and we document
that additional parties could be added such as a trusted third party (although no
such party exists in test network at this time).
This commit also re-adds some necessary verifications, and make other minor edits and
comments to help users understand the sample.
Signed-off-by: David Enyeart <enyeart@us.ibm.com>
Also install goimports globally to run the linting check rather than installing to each gomodule, which was causing dependency conflicts.
Signed-off-by: Mark S. Lewis <mark_lewis@uk.ibm.com>
Update all of the Node deps to 2.2.<latest>
and regenerate existing package-lock.json files
Signed-off-by: Brett Logan <brett.t.logan@ibm.com>
Co-authored-by: Brett Logan <brett.t.logan@ibm.com>
Signed-off-by: Chris Gabriel <chris_gabriel_98@yahoo.com>
Remove images from fabric-samples and move to docs.
Signed-off-by: Chris Gabriel <chris_gabriel_98@yahoo.com>
Rewrites the chaincode in idiomatic Go and cleans up
the general implementation.
A future commit should push the chaincode logic itself
into a separate package as chaincode cannot be tested
when the logic is part of the main package.
Signed-off-by: Brett Logan <brett.t.logan@ibm.com>
- Move go chaincode to chaincode-go subdirectory
- Add public description argument to CreateAsset()
Signed-off-by: Tiffany Harris <tiffany.harris@ibm.com>
- Rename marbles_transfer to a more generic and streamlined asset
- Move sample to new directory
- Remove TODO for marbles by size query
Signed-off-by: Tiffany Harris <tiffany.harris@ibm.com>