Caching/job tracking framework
<p>I'm trying to solve the following problem:</p>

<ul>
<li>I have some expensive work to do which I then cache the result of</li>
<li>The work is keyed by a string</li>
<li>Many requests may arrive simultaneously for the same key</li>
<li>I'd like to avoid doing the work more than once per key</li>
<li>I'd like to add callbacks against the key which will be invoked when the work is completed; not all of these are known when the work is first submitted.</li>
</ul>

<p>This feels like a problem which ought to have been solved already; does anybody know of a Java framework or library which covers it?</p>