Welcome to the Awesome Accord repository! This guide provides resources and examples for implementing ACID transactions in Apache Cassandra. Learn how to leverage distributed transactions for building reliable applications.
- Quick Start with Docker: Single-node deployment for immediate testing
- Lab Environment: Multi-node cluster setup for development
- Use Cases & Examples: Production-ready implementations
- Learning Resources: Documentation and best practices
Accord is in active development and still a feature branch in the Apasche Cassandra® Repo. You will find bug. What we ask is that you help with a contribution of a bug report.
You can use the Github discussions bug report forum for this or use the Planet Cassandra Discord channel for accord listed below. A bug report should have the folowing:
- The data model used
- Actions to reproduce the bug
- Full stack trace from system.log
If you have suggestions about syntax or improving the overall developer expirience, we want to hear about that to! Add it as a suggestion or feature request using Github discussions or let us know in the Planet Cassandra Discord.
Now, on to the fun!
docker pull pmcfadin/cassandra-accord
docker run -d --name cassandra-accord -p 9042:9042 pmcfadin/cassandra-accord
brew tap rustyrazorblade/rustyrazorblade
brew install easy-cass-lab
- Banking Transactions: Account transfers with ACID guarantees
- Inventory Management: Race-free inventory tracking
- User Management: Multi-table atomic operations
- Provide feedback and bug reports in the repository forum
- Join our Discord Community for discussions and support
- Review our Contributor Guide
- Submit issues and improvements through GitHub
/
├── docker/ # Docker configuration and setup
├── easy-cass-lab/ # Multi-node testing environment
├── examples/ # Implementation examples
│ ├── banking/ # Financial transaction examples
│ ├── inventory/ # Stock management examples
│ └── user-mgmt/ # User operations examples
└── docs/ # Guides and documentation
Our documentation includes:
- Comprehensive setup instructions
- Transaction patterns and implementations
- Performance optimization guides
- Troubleshooting and best practices
- Choose your deployment option:
- Follow the Quick Start Guide
- Explore example implementations
- Connect with our Discord community
- Feedback! Github Discussions
BEGIN TRANSACTION
LET fromBalance = (SELECT account_balance
FROM ks.accounts
WHERE account_holder='alice');
IF fromBalance.account_balance >= 20 THEN
UPDATE ks.accounts
SET account_balance -= 20
WHERE account_holder='alice';
UPDATE ks.accounts
SET account_balance += 20
WHERE account_holder='bob';
END IF
COMMIT TRANSACTION;
Apache License 2.0