title: Java Sequence Generation without repetition
body: <p>I have a specific requirement to generate a unique sequence number for the day. The utility should be able to generate the sequence without repeating even if there's a JVM restart.</p>
  <p>Prerequisites:</p>
  <ul>
  <li>should not use database sequence.</li>
  <li>should not store anything in filesystem.</li>
  <li>Sequence can be repeated across the day.</li>
  <li>Sequence should not get repeated within the day, even if there's a JVM restart (this is already ensured with different attribute).</li>
  <li>No of sequence per second is min requirement 99.</li>
  </ul>
  <blockquote>
  <p>Sequence format: ######## (8 digits max)</p>
  </blockquote>
  <p>Note: this will be running in different instance of nodes and hence first digits of sequence is reserved for identifying the node.</p>