Apache Ignite Tools Documentation

The Apache Ignite Tools Developer Hub

Welcome to the Apache Ignite Tools developer hub. You'll find comprehensive guides and documentation to help you start working with Apache Ignite Tools as quickly as possible, as well as support if you get stuck. Let's jump right in!

Get Started    

Automatic RDBMS Integration

Overview

Ignite Web Console allows to configure all the cluster properties and import schema from a database for integrating with persistence stores. Ignite Web Console will connect to the specified database and generate all the required OR-mapping configuration (XML and pure Java) and Java domain model POJOs.

Ignite also ships with org.apache.ignite.cache.store.jdbc.CacheJdbcPojoStore, which is out-of-the-box JDBC implementation of the IgniteCacheStore interface, and automatically handles all the write-through and read-through logic.

Screencasts

You can watch the following videos to see how to automatically import schema metadata from an RDBMS, start an Ignite cluster and load data from the database, and use Ignite web console to run SQL queries on distributed data stored across the cluster:

How It Works

Ignite Web Agent, a special Java application should be started near your RDBMS. This application collects the database schema metadata and sends it to the Ignite Web Console.

Database Schema Import

Open the Ignite Web Console instance hosted by GridGain in a web browser and sign in or build and deploy your own instance of Ignite Web Console.

Web Console Hosting and Logo

For the simplicity of this guide, an already deployed instance of Ignite Web Console is used. The instance is hosted on GridGain infrastructure and GridGain embeds its logo as a part of the console interface. You'll see the logo on the screenshots below. Note that you're free to deploy Ignite Web Console on an alternative infrastructure and use other logo.

1. Configure Ignite Clusters

Create a cluster on the Clusters screen.

2. Configure Domain Model

Go to the Model screen and click on the Import from database button.

If the Ignite Web Agent is not already started, the Web Console will display a dialog box prompting you to download the Web Agent and start it. The Web agent should be started on the computer that has access to the RDBMS from which the schema will be imported.

After the Web Agent is started and connected to the Web server, you will see a step-by-step wizard to import the schema from the database. Note that you may need to copy the JDBC driver for your database to the jdbc-drivers folder of the Ignite Web Agent.

  1. Configure connection to the database.
  1. Select schemas to load the tables from.
  1. Select tables to import as domain model and configure mapping those tables to caches. By default, each table will be imported to a separate partitioned cache.
  1. Specify various import options and select the cluster that should be associated with the generated caches.

3. Download the Project

After importing the schema, you can go to the Summary screen and download the project that contains the following:

  • Spring XML configurations for cluster and caches.
  • Java code for cluster and caches configuration.
  • Java code for Server and Client nodes startup.
  • Java code for data preloading from an underlying RDBMS.
  • Java code for POJOs.
  • pom.xml with project description.

Data Preloading

The project generated by Ignite Web Console contains a variety of ready-to-use artifacts as described above.

The following needs to be done if you want to preload data from the underlying RDBMS quickly:

  • Locate secret.properties file in the project downloaded from the Web Console, and set the JDBC driver related parameters like JDBC URL, name and password to the values you used at the schema importing stage with Ignite Web Console.
  • Start a server node using either ServerNodeSpringStartup or ServerNodeCodeStartup file.
  • Initiate data preloading from the database into Ignite caches using LoadCaches startup file.

To learn more about the project's structure and existing artifacts, refer to project's README file that contains a thorough explanation of the content.