- Java
-
A transaction is performed by calling
.submitTx
on anICruxIngestAPI
with aTransaction
object.The
Transaction
object can be created by either usingTransaction.Builder
directly or using aConsumer
.If using the
Consumer
approach, we recommend importingcrux.api.tx.Transaction.buildTx
statically for brevity.link:example$test/crux/docs/examples/transactions/TransactionsTest.java[role=include] link:example$test/crux/docs/examples/transactions/TransactionsTest.java[role=include] link:example$test/crux/docs/examples/transactions/TransactionsTest.java[role=include] // To run the transaction: link:example$test/crux/docs/examples/transactions/TransactionsTest.java[role=include] // To run a transaction directly: link:example$test/crux/docs/examples/transactions/TransactionsTest.java[role=include]
- Clojure
-
A transaction is performed by calling
crux.db/submit-tx
on a node with a list of transaction operations.(crux/submit-tx node [ ;; Operations ])