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-ledger-connector-fabric-socketio): remove fabric-socketio connector #2645

Merged
merged 1 commit into from
Oct 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
27 changes: 0 additions & 27 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1215,33 +1215,6 @@ jobs:
- run: npm run configure
- run: yarn ts-node ./packages/cactus-plugin-ledger-connector-fabric/src/test/typescript/integration/fabric-v2-2-x/run-transaction-with-ws-ids.test.ts

cactus-plugin-ledger-connector-fabric-socketio:
continue-on-error: false
env:
FULL_BUILD_DISABLED: true
JEST_TEST_PATTERN: packages/cactus-plugin-ledger-connector-fabric-socketio/src/test/typescript/(unit|integration|benchmark)/.*/*.test.ts
JEST_TEST_RUNNER_DISABLED: false
TAPE_TEST_RUNNER_DISABLED: true
needs: build-dev
runs-on: ubuntu-20.04
steps:
- name: Use Node.js v16.14.2
uses: actions/[email protected]
with:
node-version: v16.14.2
- uses: actions/[email protected]

- id: yarn-cache
name: Restore Yarn Cache
uses: actions/[email protected]
with:
key: ${{ runner.os }}-yarn-${{ hashFiles('./yarn.lock') }}
path: ./.yarn/
restore-keys: |
${{ runner.os }}-yarn-${{ hashFiles('./yarn.lock') }}
- run: yarn --version
- run: yarn install
- run: ./tools/ci.sh
cactus-plugin-ledger-connector-go-ethereum-socketio:
continue-on-error: false
env:
Expand Down
25 changes: 8 additions & 17 deletions examples/cactus-example-discounted-asset-trade/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ Alice will use credentials and other Indy formats such as schema and definition

## Setup Overview

### fabric-socketio-validator
### fabric-connector

- Validator for fabric ledger.
- Docker networks: `fabric-all-in-one_testnet-2x`, `cactus-example-discounted-asset-trade-net`
- Started as part of discounted asset trade BLP.

### ethereum-validator

Expand Down Expand Up @@ -114,8 +114,6 @@ Alice will use credentials and other Indy formats such as schema and definition
```
cactus-example-discounted-asset-trade-ethereum-validator | listening on *:5050
...
cactus-example-discounted-asset-trade-fabric-socketio-validator | listening on *:5040
...
cactus-example-discounted-asset-trade-indy-validator | 2022-01-31 16:00:49,552 INFO success: validator entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
...
cactus-example-discounted-asset-trade-indy-validator-nginx | 2022/01/31 16:00:49 [notice] 1#1: start worker process 35
Expand Down Expand Up @@ -154,9 +152,6 @@ For development purposes, it might be useful to run the sample application outsi
1. Configure cactus and start the ledgers as described above.
1. Run `./script-dockerless-config-patch.sh` from `cactus-example-discounted-asset-trade/` directory. This will patch the configs and copy it to global location.
1. Start validators (each in separate cmd window).
1. ```bash
cd packages/cactus-plugin-ledger-connector-fabric-socketio/ && npm run start
```
1. ```bash
cd packages/cactus-plugin-ledger-connector-go-ethereum-socketio/ && npm run start
```
Expand Down Expand Up @@ -207,8 +202,6 @@ For development purposes, it might be useful to run the sample application outsi

1. Run the transaction execution:

**For docker-compose environment, run:**

```
./script-post-trade-request.sh
```
Expand All @@ -219,17 +212,10 @@ For development purposes, it might be useful to run the sample application outsi
docker run --rm -ti -v "$(pwd)/etc/cactus/":"/etc/cactus/" --net="host" register-indy-data
```

**For dockerless environment, run:**

```bash
pushd ../register-indy-data && sh ./script-build-docker.sh && popd &&
docker run --rm -ti -v/etc/cactus/:/etc/cactus/ --net="host" register-indy-data --force
```

**After sending the requests**

- The transactions are executed by order.
- When the following log appears on the BLP console, the transactions are completed.
- When the following log appears on the BLP console, the transactions are completed (you may need to scroll a bit to find it).

```
[INFO] BusinessLogicAssetTrade - ##INFO: completed asset-trade, businessLogicID: guks32pf, tradeID: *******-001
Expand Down Expand Up @@ -295,3 +281,8 @@ For development purposes, it might be useful to run the sample application outsi
./script-cleanup.sh
popd
```

#### Possible improvements
- Ethereum events are duplicated, causing trade to proceed even if previous step was not successfull.
- Handle this case properly - ignore duplciated events, move forward only if current step was completed.
- Investigate and fix duplicated events in Verifier / Ethereum connector (or use openapi ethereum connector).
Loading
Loading