-
Notifications
You must be signed in to change notification settings - Fork 309
feat(satp-hermes): added cbdc ci #3993
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
Draft
pandaio22
wants to merge
123
commits into
hyperledger-cacti:satp-stg
Choose a base branch
from
pandaio22:satp-stg-cbdc-ci
base: satp-stg
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
feat(satp-hermes): added cbdc ci #3993
pandaio22
wants to merge
123
commits into
hyperledger-cacti:satp-stg
from
pandaio22:satp-stg-cbdc-ci
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: Rafael Belchior <[email protected]> Co-authored-by: Carlos Amaro <[email protected]>
Signed-off-by: Iulia Mihaiu <[email protected]> Signed-off-by: Rafael Belchior <[email protected]> feat(cc-tx-viz): add methods to fabric connector Signed-off-by: Iulia Mihaiu <[email protected]> fix(prometheus): metrics.ts leaks to global registry 1. Specified a `register` property of the gauges as an empty array so that it does not pollute the global namespace. This is how this is supposed to be done as per the docs of prom-client. 2. Once the change from 1) took place, the issue became that the metrics gathering code was still trying to hit up the global scope for the metrics, e.g. calling the get metrics methods directly on the promClient object instead of the registry that we create for each prmoetheus exporter object separately. So a little additional refactor ensued to fix this as well by making sure that we grab a reference of the registry object at construction time and then re-use that wherever needed instead of going through the global promClient object. 3. Added missing .startMetricsCollection calls in the plugin constructors to ensure that the prometheus exporter object gets initialized properly (this is where the registry gets created as well so without this there are crashes happening when one tries to access the metrics through the registry) Why though? The problem was that the metrics.ts file that we have for all the plugin's metrics constructs a new Metric (Gauge) object at import time which then defaults to registering the metric in the global registry of prom-client by default. The latter was causing crashes when separate versions of the same metrics.ts file are imported in a scenario were the API server imports plugins from a different directory (this issue is coming from the branch where I'm working on plugin sandboxing via the live-plugin-manager). Fixes 1202 Signed-off-by: Peter Somogyvari <[email protected]> feat(cc-tx-viz): added test for multiple prometheus metrics on fabric Signed-off-by: Iulia Mihaiu <[email protected]> feat(cc-tx-viz): add metric model Signed-off-by: Iulia Mihaiu <[email protected]> feat(cc-tx-viz): added croschainEventLog models Signed-off-by: Iulia Mihaiu <[email protected]> feat(fabric): added endpoint for list of transaction receipts Signed-off-by: Iulia Mihaiu <[email protected]> feat(test-tooling): add RabbitMQ test server feat(cc-tx-viz): add RabbitMQ support; update model feat(cc-tx-viz): add preliminary support to Fabric and Besu build(deps): upgrade axios to latest to fix CVE Details CVE-2021-3749 high severity Vulnerable versions: <= 0.21.1 Patched version: 0.21.2 axios is vulnerable to Inefficient Regular Expression Complexity Signed-off-by: Peter Somogyvari <[email protected]> feat(cc-tx-viz): add methods to fabric connector Signed-off-by: Iulia Mihaiu <[email protected]> feat(cc-tx-viz): add metric model Signed-off-by: Iulia Mihaiu <[email protected]> xfix(cc-tx-viz): error implementation of IsVisualizable feat(cc-tx-viz): add methods to fabric and besu; update models Signed-off-by: Iulia Mihaiu <[email protected]> feat(cc-tx-viz): update cross chain events log for fabric transactions Signed-off-by: Iulia Mihaiu <[email protected]> feat(cctxviz): fix fabric prometheus feat(cctxviz): fix besu prometheus feat(cctxviz): fix fabric test feat(cctxviz): update tx receipt feat(cctxviz): add test script Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): add test receipts feat(cctxviz): refactor CrossChainEventLog Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): refactor tests feat(cc-tx-viz): update model, add tests chore(cc-tx-viz): update dependencies Signed-off-by: Rafael Belchior <[email protected]> feat(cc-tx-viz): persist logs Signed-off-by: Rafael Belchior <[email protected]> test(cc-tx-viz): update test Signed-off-by: Rafael Belchior <[email protected]> feat(cc-tx-viz): update strinfify to csv Signed-off-by: Rafael Belchior <[email protected]> chore(cc-tx-viz): add csv folder Signed-off-by: Rafael Belchior <[email protected]> chore(cc-tx-viz): move csv folder Signed-off-by: Rafael Belchior <[email protected]> feat(cc-tx-viz): add test feat(cctxviz): add csv file, process mining script Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): proof of concept v1 Signed-off-by: Rafael Belchior <[email protected]> chore(cctxviz): update csv Signed-off-by: Rafael Belchior <[email protected]> docs(cctxviz): update readme Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): update tests Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): add carbon footprint Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): update tests Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): update model Signed-off-by: Rafael Belchior <[email protected]> feat(fabric-connector): update default queue Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): fabric test Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): add parameters to fabric calls Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): support besu Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): update metrics Signed-off-by: Rafael Belchior <[email protected]> test(cctxvi): update fabric and besu tests Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): besu and fabric Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): support call transactions on fabric Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): add aggregation basis Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): aggregate cctx Signed-off-by: Rafael Belchior <[email protected]> chore: update yarn and remove package.lock Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): containerize draft Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): add revenue Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): update model playbook Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): add dummy use case playbook Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): update persist test and dummy uc Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): add timer Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): workload test Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): add more timers Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): add timer to map on connectors Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): update testing framework Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): vis plot wip Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): evaluate baseline Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): update plots Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): add test files Signed-off-by: Rafael Belchior <[email protected]> feat(cctxviz): update testing framework Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): time-efficient polling receipts Signed-off-by: Rafael Belchior <[email protected]> chore(cctxviz): add test chaincode Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): update test Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): use case v1 Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): update test framework Signed-off-by: Rafael Belchior <[email protected]> build(cc-tx-visualization): added missing fabric-contract-api This will fix one compilation error. Signed-off-by: Peter Somogyvari <[email protected]> chore(deps): updated yarn.lock after rebase onto upstream/main Signed-off-by: Peter Somogyvari <[email protected]> build(cc-tx-visualization): deleted redundant test fixtures Also added the test-tooling package as a dev dependency which should fix a few of the compiler errors we were getting on account of missing dependencies. Signed-off-by: Peter Somogyvari <[email protected]> fix: resolved build errors for cctxviz branch - test-tooling package changed that needs to be reverted before commmit to main branch - added import statement for test data generation xfix(cc-tx-viz): error implementation of IsVisualizable chore: update yarn and remove package.lock Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): testing framework Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): test framework Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): update framework Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): add graphs Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): add test Signed-off-by: Rafael Belchior <[email protected]> fix(cctxviz): fix bug Signed-off-by: Rafael Belchior <[email protected]> test(cctxviz): add process conformance Signed-off-by: Rafael Belchior <[email protected]>
The plugin now utilizes RxJS instead of RabbitMQ in transaction monitoring. ReplaySubjects store and emit observed transactional data to subscribers. fix(cc-tx-visualization): rebase latest version Signed-off-by: Rafael Belchior <[email protected]> squash! - migrate a test case to Fabric v2.5.6 LTS AIO This is just a snippet of a change from the pair programming call with Bruno, it can be safely squashed, no worries. Signed-off-by: Peter Somogyvari <[email protected]> Signed-off-by: Bruno Mateus <[email protected]> feat(cc-tx-visualization): ccmodel serialization with PM4PY The plugin now creates the ccmodel for conformance checking with PM4PY. Signed-off-by: Bruno Mateus <[email protected]>
The plugin is now able to: Create a Cross-Chain Model based on monitored transactions Compare new transactions against the model and detect non-conformance Signed-off-by: Bruno Mateus <[email protected]>
Signed-off-by: eduv09 <[email protected]>
bug correction session functionalities Signed-off-by: Carlos Amaro <[email protected]> feat(satp-hermes): errors file and other fixes Signed-off-by: Carlos Amaro <[email protected]> feat(satp-hermes): fix packages versions Signed-off-by: Carlos Amaro <[email protected]>
Signed-off-by: Rafael Belchior <[email protected]>
Signed-off-by: Rafael Belchior <[email protected]>
Signed-off-by: Carlos Amaro <[email protected]>
Signed-off-by: Rafael Belchior <[email protected]>
Signed-off-by: Carlos Amaro <[email protected]> feat(satp-hermes): satp rejection Signed-off-by: Carlos Amaro <[email protected]> feat(satp-hermes): handler bug correction and errors Signed-off-by: Carlos Amaro <[email protected]> fix(satp-hermes): bridge erros and log messages Signed-off-by: Carlos Amaro <[email protected]> fix(satp-hermes): some error fixes Signed-off-by: Carlos Amaro <[email protected]> fix(satp-hermes): some fixes requested Signed-off-by: Carlos Amaro <[email protected]> Signed-off-by: Rafael Belchior <[email protected]>
Co-authored-by: eduv09 <[email protected]> Signed-off-by: Carlos Amaro <[email protected]> fix(satp-hermes): error messages in stage0 Signed-off-by: Carlos Amaro <[email protected]> feat(satp-hermes): service tests added stage0 and error handling Signed-off-by: Carlos Amaro <[email protected]> feat(satp-hermes): test e2e Signed-off-by: Carlos Amaro <[email protected]> fix(satp-hermes): fix bugs and test e2e working transfer Signed-off-by: Carlos Amaro <[email protected]> fix(stap-hermes): bugs and 2 gateway test Signed-off-by: Carlos Amaro <[email protected]>
Signed-off-by: Carlos Amaro <[email protected]>
Signed-off-by: Eduardo Vasques <[email protected]>
Signed-off-by: Carlos Amaro <[email protected]> refactor(cbdc-example): update with new satp-plugin Signed-off-by: eduv09 <[email protected]> refactor(cbdc-example): fixes Signed-off-by: Carlos Amaro <[email protected]> <
Signed-off-by: Eduardo Vasques <[email protected]> fix(satp-hermes): bug fixing Signed-off-by: Carlos Amaro <[email protected]> fix(cbdc-example): bug fixing Signed-off-by: Carlos Amaro <[email protected]> feat(cbdc): final fixes Signed-off-by: Eduardo Vasques <[email protected]> fix(cbdc-example): remove unecessary variable Signed-off-by: Carlos Amaro <[email protected]> fix(satp-hermes): remove unessary logs Signed-off-by: Carlos Amaro <[email protected]> fix(cbdc-example): docker ports Signed-off-by: Carlos Amaro <[email protected]> Signed-off-by: Rafael Belchior <[email protected]>
* Separated Transfer functionality into local blockchain transfers and cross-chain transfers * Added new table with the state of token approvals made to the bridge * Highlight cross-chain functionality with red coloring * add helper page with instructions on how to use app Signed-off-by: André Augusto <[email protected]>
* Created new Docker Image and updated README.md Signed-off-by: André Augusto <[email protected]>
Also fixing a few other bugs which were all necessary to make it work after a rebase onto upstream/main as of 2024-10-10. 1. The tsconfig.json file in the root did not contain a reference to the package at `packages/cactus-plugin-ccmodel-hephaestus` so it was being excluded from the compilation. 2. express version was not up to date with the rest of the monorepo which Signed-off-by: Peter Somogyvari <[email protected]>
Import paths were invalid possibly because the files were moved around within the directory tree and the imports never got updated. There are still imports which are invalid because of issues with the remix IDE test library being used but not declared as a dependency. I've opened a separate issue about fixing those problems here: hyperledger-cacti#3585 Signed-off-by: Peter Somogyvari <[email protected]>
Signed-off-by: Carlos Amaro <[email protected]>
* added logic for satp-bridge supporting the ethereum connector * finished the integration with bungee * changed common stringify for safeStableStringify across the package * added test for the new bridge & end-to-end tests for the new features * fabric-connector: fix bug handling empty read-write sets * bungee: strategy fabric fix bug handling empty read-write sets * bungee: hole package introduce safeStableStringify * ethereum-connector: bump web3 packages versions to fix (web3/web3.js#6798) Signed-off-by: Eduardo Vasques <[email protected]>
Signed-off-by: Bruno Mateus <[email protected]> refactor(satp-hermes): gateway container image definition with bundler Signed-off-by: Peter Somogyvari <[email protected]> refactor(satp-hermes): merge policies type guard example Signed-off-by: Peter Somogyvari <[email protected]> refactor(satp-hermes): type guards for SATP env variables Signed-off-by: Bruno Mateus <[email protected]> squash! - peter's fixes for besu connectivity use LAN IP Instead of hardcoded localhost use the LAN IP of machine so that the gateway container can access it too. Why though? Because if you tell the gateway container that it should access the besu ledger via localhost then it will try to do that through the container's own localhost, which is different from the host machine's localhost (where the besu ledger is actually running). Using the actual IP address of the host machine's primary network interface resolves the ambiguity between the two differnet localhosts. Co-authored-by: Peter Somogyvari <[email protected]> Co-authored-by: Rafael Belchior <[email protected]> Signed-off-by: Rafael Belchior <[email protected]>
implement the following endpoints: healthcheck, get status, get integrations Signed-off-by: André Augusto <[email protected]> Signed-off-by: Rafael Belchior <[email protected]>
Co-authored-by: Rafael Belchior <[email protected]> Signed-off-by: Yogesh01000100 <[email protected]>
The commit adds test classes for Besu, Ethereum and Fabric ledger setup. This provides encapsulated initialization and configuration, improving test organization and enabling easier code reuse across SATP test files. Signed-off-by: brunoffmateus <[email protected]>
Signed-off-by: Yogesh01000100 <[email protected]>
Signed-off-by: Carlos Amaro <[email protected]> fix(satp-hermes): fix tests so you can test each test individually Signed-off-by: Carlos Amaro <[email protected]>
1. Improved SATP client and server stage services with databse logging. 2. Added a new logging file to centralize and simplify log operations. 3. Integrated Knex config into the Gateway. Signed-off-by: Yogesh01000100 <[email protected]>
* changed cbdc example to use cacti api-server * added test to test the compatibility * TODO: check OAS (detailed comment in main plugin) Signed-off-by: Eduardo Vasques <[email protected]>
Signed-off-by: Rafael Belchior <[email protected]>
Add container cleanup logic before image removal in pruneDockerResources() to prevent "conflict: unable to delete image - image is being used by running container" errors in CI jobs. Changes: - Stop running containers gracefully with 30-second timeout - Force remove all containers before attempting image deletion - Add NodeJS flag --max-old-space-size=8192 to CI jobs to prevent "JavaScript heap out of memory" errors Signed-off-by: Rafael Belchior <[email protected]>
Signed-off-by: Rafael Belchior <[email protected]>
Signed-off-by: Rafael Belchior <[email protected]>
Signed-off-by: Jorge Santos <[email protected]>
…pprove-address The implementation of the SATP gateway expects a different set of parameter names - they have to be prefixed with `networkId`. Signed-off-by: Robin Huiser <[email protected]>
When running multiple functional instances of the SATP Gateway (one gateway for network 1, one gateway for network 2) you need for each instance a unique OTEL service name to keep logging, traces and metrics separated. As per the documentation here: https://opentelemetry.io/docs/specs/otel/configuration/sdk-environment-variables/#general-sdk-configuration ...I have used the standard environment variable OTEL_SERVICE_NAME to allow for this. Signed-off-by: Robin Huiser <[email protected]>
Signed-off-by: Rodolfo Carapau <[email protected]> feat(satp-hermes): added cbdc ci Signed-off-by: Rodolfo Carapau <[email protected]>
e2d943b
to
f3f1722
Compare
Blocked by failing pipeline |
b3bb285
to
a14f896
Compare
9bee4bd
to
1ae6a34
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull Request Requirements
upstream/main
branch and squashed into single commit to help maintainers review it more efficient and to avoid spaghetti git commit graphs that obfuscate which commit did exactly what change, when and, why.-s
flag when usinggit commit
command. You may refer to this link for more information.Character Limit
A Must Read for Beginners
For rebasing and squashing, here's a must read guide for beginners.