ignite-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ray Liu (rayliu)" <ray...@cisco.com>
Subject Ignite cluster with persistent store enabled did not load from wal after restarting.
Date Fri, 15 Sep 2017 08:49:35 GMT
Hi All,

I’m using Ignite version 2.1.
I opened persistent sotre by adding these configuration in the xml file according to https://apacheignite.readme.io/docs/distributed-persistent-store

  <property name="persistentStoreConfiguration">
    <bean class="org.apache.ignite.configuration.PersistentStoreConfiguration"/>

Here’s the code I used to ingest data to ignite.

public class IgniteTest {
    public static void main(String[] args) throws Exception {

        try (Ignite ignite = Ignition.start("example-ignite.xml")) {

            CacheConfiguration<Integer, Person> personCacheCfg = new CacheConfiguration<>("person");

            personCacheCfg.setIndexedTypes(Integer.class, Person.class);

            IgniteCache<Integer, Person> personCache = ignite.getOrCreateCache(personCacheCfg);

            Person p1 = new Person(1, "John", "Doe", 2000);
            Person p2 = new Person(1, "Jane", "Doe", 1000);
            Person p3 = new Person(2, "John", "Smith", 1000);
            Person p4 = new Person(2, "Jane", "Smith", 2000);

            personCache.put(p1.getId(), p1);
            personCache.put(p2.getId(), p2);
            personCache.put(p3.getId(), p3);
            personCache.put(p4.getId(), p4);
     public static class Person implements Serializable {
        private static int PERSON_ID = 0;

        @QuerySqlField(index = true)
        private Integer id;

        @QuerySqlField(index = true)
        private Integer orgId;

        private String firstName;

        private String lastName;

        @QuerySqlField(index = true)
        private double salary;

        Person(Integer orgId, String firstName, String lastName, double salary) {
            id = PERSON_ID++;

            this.orgId = orgId;
            this.firstName = firstName;
            this.lastName = lastName;
            this.salary = salary;

        public Integer getOrganizationId() {
            return orgId;

        public String getFirstName() {
            return firstName;

        public String getLastName() {
            return lastName;

        public double getSalary() {

            return salary;

        public Integer getId() {
            return id;


And I can see the wal log files generated under /$IgniteHome/work/db folder.
After restarting the cluster, the “person” cache should be re-created automatically, right?
But it didn’t.
Here’s some debug log may help locate the problem

[2017-09-15T16:34:13,090][INFO ][main][CacheObjectBinaryProcessorImpl] Resolved directory
for serialized binary metadata:  /apache-ignite-fabric-2.1.0-bin/work/binary_meta/0_0_0_0_0_0_0_1_10_140_48_140_127_0_0_1_2001_420_589a_1250_516a_c5d4_fe7d_863c_47500
[2017-09-15T16:34:13,225][DEBUG][main][GridCacheMvccManager] Cache manager started.
[2017-09-15T16:34:13,225][DEBUG][main][GridCacheVersionManager] Cache manager started.
[2017-09-15T16:34:13,243][DEBUG][main][IgniteTxManager] Cache manager started.
[2017-09-15T16:34:13,243][INFO ][main][FilePageStoreManager] Resolved page store work directory:
[2017-09-15T16:34:13,243][DEBUG][main][FilePageStoreManager] Cache manager started.
[2017-09-15T16:34:13,243][INFO ][main][FileWriteAheadLogManager] Resolved write ahead log
work directory: /apache-ignite-fabric-2.1.0-bin/work/db/wal/0_0_0_0_0_0_0_1_10_140_48_140_127_0_0_1_2001_420_589a_1250_516a_c5d4_fe7d_863c_47500
[2017-09-15T16:34:13,244][INFO ][main][FileWriteAheadLogManager] Resolved write ahead log
archive directory: //apache-ignite-fabric-2.1.0-bin/work/db/wal/archive/0_0_0_0_0_0_0_1_10_140_48_140_127_0_0_1_2001_420_589a_1250_516a_c5d4_fe7d_863c_47500
[2017-09-15T16:34:13,253][DEBUG][main][FileWriteAheadLogManager] Cache manager started.
View raw message