Creating TVU classes
Apart from verification and deserialization, you may also want to perform other tasks on your transactions using the Transaction Validator Utility (TVU). To do that, you can provide your own class and run its logic on every transaction. The following is an example of a pluggable project that logs transactions. You can use this project to test the utility and as a starting point for any project that needs to be pluggable in the TVU.
To run the project from the command-line:
- Navigate to the enterprise base directory.
- Create a JAR file under
samples/log-transaction/build/libs
:- If you are using Unix, run
./gradlew tools:transaction-validator:samples:logtransaction:build
. - If you are using Windows, run
gradlew tools:transaction-validator:samples:logtransaction:build
.
- If you are using Unix, run
- Place the JAR in the node’s drivers directory (
<node-base>/drivers
). - Run the TVU using the
-c
CLI option specifying full class name, for example,-c net.corda.tvu.LogTransaction
.
Was this page helpful?
Thanks for your feedback!
Chat with us
Chat with us on our #docs channel on slack. You can also join a lot of other slack channels there and have access to 1-on-1 communication with members of the R3 team and the online community.
Propose documentation improvements directly
Help us to improve the docs by contributing directly. It's simple - just fork this repository and raise a PR of your own - R3's Technical Writers will review it and apply the relevant suggestions.
We're sorry this page wasn't helpful. Let us know how we can make it better!
Chat with us
Chat with us on our #docs channel on slack. You can also join a lot of other slack channels there and have access to 1-on-1 communication with members of the R3 team and the online community.
Create an issue
Create a new GitHub issue in this repository - submit technical feedback, draw attention to a potential documentation bug, or share ideas for improvement and general feedback.
Propose documentation improvements directly
Help us to improve the docs by contributing directly. It's simple - just fork this repository and raise a PR of your own - R3's Technical Writers will review it and apply the relevant suggestions.