title: How does IMAP know which emails to fetch
body: <p>I am using Apache Camel to monitor a email inbox. I have been trying to find out how only newly received emails since the previous poll are returned. Somehow this process will only return emails which were received between the previous poll.</p>
  <p>Example: the poll time is set to 60 seconds. If I send one email to the inbox within this time frame one email gets handled by the route. If I send two emails in the following 60 seconds only two emails get handled by the route and not three, it ignores the first email that was handled in the previous poll. I would like to know how this happens?</p>
  <p>I am not viewing the mailbox or marking any emails as read.</p>
  <pre><code>&lt;camel:camelContext id=&quot;webService&quot;&gt;
      &lt;camel:route id=&quot;monitor&quot;&gt;
          &lt;camel:from uri=&quot;imap://pulp.test.uk?username=tester&amp;amp;password=testing&amp;amp;unseen=true&amp;amp;consumer.delay=60000&quot; /&gt;
          &lt;camel:process ref=&quot;storeProcessor&quot; /&gt;
      &lt;/camel:route&gt;  
  &lt;/camel:camelContext&gt;
  </code></pre>