Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(cactus-plugin-persistence-fabric): add new persistence plugin for fabric ledger #2328

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
7bc70d2
adding fabric block persistence plugin and gui for it
barneyshyperethers Mar 3, 2023
36fa960
adding persistence fabric plugin
barneyshyperethers Mar 3, 2023
1ff0b7c
Added gui files to repository
barneyshyperethers Mar 3, 2023
0e0956a
readme and some fixes on the way
barneyshyperethers Mar 3, 2023
4c7142d
changes in readme and functions descriptions
barneyshyperethers Mar 6, 2023
28ea195
some cspell fixes
barneyshyperethers Mar 6, 2023
9384647
txcount fix
barneyshyperethers Mar 6, 2023
d6201e9
correction of factory file
barneyshyperethers Mar 6, 2023
e2e519a
add test data in sql
barneyshyperethers Mar 7, 2023
e9d728b
adding gui files, little fixes
barneyshyperethers Mar 9, 2023
2ea39c5
adding ethereum 2259 dependency
barneyshyperethers Mar 9, 2023
d3273f7
this.synchronizationGo micorfix
barneyshyperethers Mar 10, 2023
ecd5817
merging with tests for persistence fabric block
barneyshyperethers Mar 10, 2023
33b9f13
test integrations fixes
barneyshyperethers Mar 10, 2023
b558f4c
PluginPersistenceFabricBlock class export fix
barneyshyperethers Mar 10, 2023
2efcbf6
redundant test script deletion
barneyshyperethers Mar 10, 2023
f609011
remove redundant tests
barneyshyperethers Mar 13, 2023
072d954
remove Block from names
barneyshyperethers Mar 13, 2023
548f237
almost changed name of plugin halfway
barneyshyperethers Mar 13, 2023
9a385c3
rename plugin
barneyshyperethers Mar 13, 2023
df89a34
rename plugin
barneyshyperethers Mar 13, 2023
2032070
fix paths for cloning purpose
barneyshyperethers Mar 13, 2023
ced7d15
micro fixes in Continous Functional integration test for fabric persi…
barneyshyperethers Mar 14, 2023
66519c1
fix package json for cacti plugin persistence fabric
barneyshyperethers Mar 14, 2023
9c9b8e1
change names of factory class PluginFactoryPersistanceFabric
barneyshyperethers Mar 14, 2023
5308a5c
remove unused files
barneyshyperethers Mar 14, 2023
896e0c7
spelling correction
barneyshyperethers Mar 14, 2023
835d7ec
spelling correction
barneyshyperethers Mar 14, 2023
0f56e5c
refactor: deleted useless logs and fixed flag in tests
rwat17 Mar 14, 2023
ed07845
refactor: changed test files names
rwat17 Mar 14, 2023
da01cc8
feat: mocked db in progress
rwat17 Mar 14, 2023
6617595
tempBlockParse clarification
barneyshyperethers Mar 15, 2023
c429012
tempBlockParse
barneyshyperethers Mar 15, 2023
e1ab654
changing files names of test files
barneyshyperethers Mar 15, 2023
b4be13f
feat: added rest of the functions
rwat17 Mar 15, 2023
204ff92
refactor: backed up to the old persistence plugin
rwat17 Mar 16, 2023
c75c747
refactor: deleted await
rwat17 Mar 16, 2023
527c5d1
correction of functional tests in plugin persistence fabric
barneyshyperethers Mar 16, 2023
76d6643
change in return value to be checked after checking missing blocks in…
barneyshyperethers Mar 16, 2023
2c3d304
add 1 test
barneyshyperethers Mar 16, 2023
0aadd2f
remove missleading comments
barneyshyperethers Mar 16, 2023
3a72cb7
add 10 more tests now is 22 changed initialSynchronization to be elas…
barneyshyperethers Mar 16, 2023
7408a55
minor changes
barneyshyperethers Mar 16, 2023
93de92a
Merge branch 'hyperledger:main' into cacti-plugin-persistence-fabric
barneyshyperethers Mar 16, 2023
16a0f64
readme updates
barneyshyperethers Mar 16, 2023
f890e03
Merge branch 'cacti-plugin-persistence-fabric' of https://github.com/…
barneyshyperethers Mar 16, 2023
0e7438b
refactor 1 test
barneyshyperethers Mar 16, 2023
ef1ab40
Merge branch 'hyperledger:main' into cacti-plugin-persistence-fabric
barneyshyperethers Mar 17, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
309 changes: 154 additions & 155 deletions .cspell.json
Original file line number Diff line number Diff line change
@@ -1,157 +1,156 @@
{
"version": "0.1",
"language": "en",
"minWordLength": 4,
"allowCompoundWords": true,
"words": [
"adminpw",
"Albertirsa",
"ALLFORTX",
"ANYFORTX",
"APIV",
"approveformyorg",
"Authz",
"authzn",
"AWSSM",
"Besu",
"Bools",
"brioux",
"cactusf",
"cafile",
"caio",
"cccs",
"ccid",
"celo",
"cids",
"clsx",
"commenceack",
"configtx",
"Corda",
"Cordapp",
"couchdb",
"COUCHDBADDRESS",
"COUCHDBCONFIG",
"data",
"dclm",
"DHTAPI",
"DockerOde",
"ealen",
"ecparams",
"embeddable",
"Errorf",
"escc",
"execa",
"faio",
"fidm",
"flowdb",
"fsouza",
"GETHKEYCHAINPASSWORD",
"ghcr",
"gopath",
"goquorum",
"grpc",
"grpcs",
"grpcwebtext",
"guks",
"hada",
"hashicorp",
"Healthcheck",
"htlc",
"Htlc",
"HTLC",
"HyperLedger",
"ipaddress",
"ipfs",
"Iroha",
"Irohad",
"isready",
"jboss",
"JORDI",
"jsrsa",
"jsrsasign",
"Keychain",
"Keycloak",
"KEYUTIL",
"KJUR",
"Knetic",
"LEDGERBLOCKACK",
"leveldb",
"lmify",
"LOCALMSPID",
"miekg",
"mitchellh",
"MSPCONFIGPATH",
"MSPID",
"MSPIDSCOPEALLFORTX",
"MSPIDSCOPEANYFORTX",
"Mtls",
"myapp",
"mychannel",
"myroot",
"mysecretpassword",
"myvolume",
"Nerc",
"NETWORKSCOPEALLFORTX",
"NETWORKSCOPEANYFORTX",
"NODETXPOOLACK",
"notok",
"Odap",
"Oidc",
"oneofs",
"onsi",
"OpenAPI",
"openethereum",
"organisation",
"Orgs",
"parameterizable",
"Postgres",
"proto",
"protobuf",
"protoc",
"protos",
"qscc",
"recoverupdateackmessage",
"RUSTC",
"Rwset",
"sbjpubkey",
"Secp",
"shrn",
"Smonitor",
"socketio",
"SPDX",
"Splug",
"Sprintf",
"stretchr",
"supervisorctl",
"supervisord",
"svcs",
"sykesm",
"tezos",
"TEZOS",
"thream",
"tlsca",
"tlscacerts",
"txid",
"txqueue",
"Uisrs",
"undici",
"Unmarshal",
"uuidv",
"vscc",
"wasm",
"Xdai"
],
"dictionaries": [
"typescript,node,npm,go,rust"
],
"ignorePaths": [
"**/node_modules/**",
"**/build/**",
"**/src/main/typescript/generated/**",
"packages/cactus-plugin-verifier-cc/**",
"packages/cactus-cmd-socketio-server/**",
"packages/cactus-plugin-ledger-connector-sawtooth-socketio/**",
"packages/cactus-plugin-ledger-connector-go-ethereum-socketio/**",
"packages/cactus-plugin-ledger-connector-*-socketio/**"
]
"version": "0.1",
"language": "en",
"minWordLength": 4,
"allowCompoundWords": true,
"words": [
"adminpw",
"Albertirsa",
"ALLFORTX",
"ANYFORTX",
"APIV",
"approveformyorg",
"Authz",
"authzn",
"AWSSM",
"Besu",
"Bools",
"brioux",
"cactusf",
"cafile",
"caio",
"cccs",
"ccid",
"celo",
"cids",
"clsx",
"commenceack",
"configtx",
"Corda",
"Cordapp",
"couchdb",
"COUCHDBADDRESS",
"COUCHDBCONFIG",
"data",
"dclm",
"DHTAPI",
"DockerOde",
"ealen",
"ecparams",
"embeddable",
"Errorf",
"escc",
"execa",
"faio",
"fidm",
"flowdb",
"fsouza",
"GETHKEYCHAINPASSWORD",
"ghcr",
"gopath",
"goquorum",
"grpc",
"grpcs",
"grpcwebtext",
"guks",
"hada",
"hashicorp",
"Healthcheck",
"htlc",
"Htlc",
"HTLC",
"HyperLedger",
"ipaddress",
"ipfs",
"Iroha",
"Irohad",
"isready",
"jboss",
"JORDI",
"jsrsa",
"jsrsasign",
"Keychain",
"Keycloak",
"KEYUTIL",
"KJUR",
"Knetic",
"LEDGERBLOCKACK",
"leveldb",
"lmify",
"LOCALMSPID",
"miekg",
"mitchellh",
"MSPCONFIGPATH",
"MSPID",
"MSPIDSCOPEALLFORTX",
"MSPIDSCOPEANYFORTX",
"Mtls",
"myapp",
"mychannel",
"myroot",
"mysecretpassword",
"myvolume",
"Nerc",
"NETWORKSCOPEALLFORTX",
"NETWORKSCOPEANYFORTX",
"NODETXPOOLACK",
"notok",
"Odap",
"Oidc",
"oneofs",
"onsi",
"OpenAPI",
"openethereum",
"organisation",
"Orgs",
"parameterizable",
"Postgres",
"proto",
"protobuf",
"protoc",
"protos",
"qscc",
"recoverupdateackmessage",
"RUSTC",
"Rwset",
"sbjpubkey",
"Secp",
"shrn",
"Smonitor",
"socketio",
"SPDX",
"Splug",
"Sprintf",
"stretchr",
"supervisorctl",
"supervisord",
"svcs",
"sykesm",
"tezos",
"TEZOS",
"thream",
"tlsca",
"tlscacerts",
"txid",
"txqueue",
"Uisrs",
"undici",
"Unmarshal",
"uuidv",
"vscc",
"wasm",
"Xdai",
"ossp"
],
"dictionaries": ["typescript,node,npm,go,rust"],
"ignorePaths": [
"**/node_modules/**",
"**/build/**",
"**/src/main/typescript/generated/**",
"packages/cactus-plugin-verifier-cc/**",
"packages/cactus-cmd-socketio-server/**",
"packages/cactus-plugin-ledger-connector-sawtooth-socketio/**",
"packages/cactus-plugin-ledger-connector-go-ethereum-socketio/**",
"packages/cactus-plugin-ledger-connector-*-socketio/**"
]
}
61 changes: 61 additions & 0 deletions gui/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
# `@hyperledger/cactus-cmd-gui-app`

This component allows viewing ledger data in Supabase or other postgreSQL compatible database. The data is fed to supabase by persistence plugins for each ledgers.

## Summary

- [`@hyperledger/cactus-cmd-gui-app`](#hyperledgercactus-cmd-gui-app)
- [Summary](#summary)
- [Remarks](#remarks)
- [Getting Started](#getting-started)
- [Prerequisites using yarn](#prerequisites-using-yarn)
- [Alternative Prerequisites using npm](#alternative-prerequisites-using-npm)
- [Usage](#usage)
- [Contributing](#contributing)
- [License](#license)
- [Acknowledgments](#acknowledgments)

## Remarks

- Plugin requires running Supabase or other database and persistence plugins in order to properly view ledger data.
- Currently, fabric and ethereum based ledgers are supported.

## Getting Started

Clone the git repository on your local machine. Follow these instructions that will get you a copy of the project up and running on your local machine for development and testing purposes.

### Prerequisites using yarn

In the root of the project, execute the command to install and build the dependencies. It will also build this GUI front-end component:

```sh
yarn run build
```
### Alternative Prerequisites using npm

In the root of the project, execute the command to install and build the dependencies. It will also build this GUI front-end component:

```sh
npm install
```

### Usage
- Run Supabase instance (see documentation for detailed instructions). For development purposes, you can use our image located in `tools/docker/supabase-all-in-one`.
- Run one or more persistence plugins:
- [Ethereum](../cactus-plugin-persistence-ethereum)
- [Fabric] (../cactus-plugin-persistence-fabric)
- Edit [Supabase configuration file](./src/supabase-client.tsx), set correct supabase API URL and service_role key.
- Execute `yarn run start` or `npm start` in this package directory.
- The running application address: http://localhost:3001/ (can be changed in [Vite configuration](./vite.config.ts))

## Contributing

We welcome contributions to Hyperledger Cactus in many forms, and there’s always plenty to do!

Please review [CONTIRBUTING.md](../../CONTRIBUTING.md) to get started.

## License

This distribution is published under the Apache License Version 2.0 found in the [LICENSE](../../LICENSE) file.

## Acknowledgments
16 changes: 16 additions & 0 deletions gui/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<link rel="shortcut icon" type="image/ico" href="/src/assets/favicon.ico" />
<title>Cacti GUI</title>
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>

<script src="/src/index.tsx" type="module"></script>
</body>
</html>
Loading