title: Persisting data on disk using Hazelcast
body: <p>I have installed HazelCast 2.5. I want to persist my records into disk. I learned that MapStore does this job. However i'm not sure how to implement MapStore.</p>
  
  <p>Code I've written so far:</p>
  
  <pre><code>public class MyMaps implements MapStore&lt;String,String&gt; {
  
      public static Map&lt;Integer, String&gt; mapCustomers = Hazelcast.getMap("customers");
  
      public static void main(String[] args) {
          {
              mapCustomers.put(1, "Ram");
              mapCustomers.put(2, "David");
              mapCustomers.put(3, "Arun");
  
          }
      }
  }
  </code></pre>
  
  <p>How do i put all these entries into disk.</p>
  
  <p>Is it necessary to have a back-end like MySQL or PostgreSQL to use this class?</p>
  
  <p>I believe the following function can be used:</p>
  
  <pre><code>public void delete(String arg0);
  public void deleteAll(String arg0);
  public void store(String arg0);
  public void storeAll(String arg0);
  </code></pre>
  
  <p>I need a sample snippet of how to implement MapStore. </p>
  
  <p>Please provide me with sample code.</p>