A demonstration of Apache Ignite 3 Java API using the Chinook database model.
This project demonstrates how to use Apache Ignite 3's Java API with POJO-based table mapping. It implements the Chinook database, a sample database schema for a digital media store (similar to iTunes), to showcase various Ignite 3 features including:
- Annotation-based table mapping
- Distribution zones and storage profiles
- Data co-location for optimized joins
- CRUD operations with POJOs
- SQL query execution
- Transaction management
- Bulk data loading from SQL files
- Java 17 or higher
- Apache Maven 3.6 or higher
- Docker and Docker Compose (for running Ignite nodes)
- Start the Ignite cluster
docker-compose up -d
- Initialize the cluster
docker run --rm -it --network=host -e LANG=C.UTF-8 -e LC_ALL=C.UTF-8 apacheignite/ignite:3.0.0 cli
connect http://localhost:10300
cluster init --name=ignite3 --metastorage-group=node1,node2,node3
exit
- Choose a setup method:
# Create the database schema
mvn compile exec:java@create-tables
# Load sample data
mvn compile exec:java@load-data
# Load both schema and data from SQL file
mvn compile exec:java@bulk-load
- Run the main application
mvn compile exec:java@run-main
For detailed documentation, see the docs directory:
- Quick Start Guide - High-level overview of Ignite 3 concepts and architecture
- Getting Started - Detailed setup instructions
- Data Model - Chinook database schema explanation
- POJO Mapping - How POJOs are mapped to Ignite tables
- Distribution Zones - Understanding data distribution
- Storage Profiles - Storage engine options and configuration
- Annotations - Reference for Ignite 3 annotations
- Developer Guide - Comprehensive Java API tutorial with practical examples
- Examples - Code examples and patterns
- Factory Classes - Factory pattern implementations for better code organization
- Bulk Loading - Loading data from SQL files