title: Java Fast Data Storage & Retrieval
body: <p>I need to store records into a persistant storage and retrieve it on demand. The requirement is as follows:</p>
  
  <ol>
  <li>Extremely fast retrieval and insertion</li>
  <li>Each record will have a unique key. This key will be used to retrieve the record</li>
  <li>The data stored should be persistent i.e. should be available upon JVM restart</li>
  <li>A separate process would move stale records to RDBMS once a day</li>
  </ol>
  
  <p>What do you guys think? I cannot use standard database because of latency issues. Memory databases like HSQLDB/ H2 have performace contraints. Moreover the records are simple string objects and do not qualify for SQL. I am thinking of some kind of flat file based solution. Any ideas? Any open source project? I am sure, there must be someone who has solved this problem before.</p>