JPPF Issue Tracker
star_faded.png
Please log in to bookmark issues
enhancement_small.png
CLOSED  Enhancement JPPF-586  -  Cache of class/resource definitions in the client
Posted Apr 08, 2019 - updated Apr 13, 2019
action_vote_minus_faded.png
0
Votes
action_vote_plus_faded.png
icon_info.png This issue has been closed with status "Closed" and resolution "RESOLVED".
Issue details
  • Type of issue
    Enhancement
  • Status
     
    Closed
  • Assigned to
     lolo4j
  • Type of bug
    Not triaged
  • Likelihood
    Not triaged
  • Effect
    Not triaged
  • Posted by
     lolo4j
  • Owned by
    Not owned by anyone
  • Category
    Performance
  • Resolution
    RESOLVED
  • Priority
    Normal
  • Targetted for
    icon_milestones.png JPPF 6.2
Issue description
When a job is dispatched to multiple nodes in parallel, this can result in the same class loading request being issued to the same client in parallel or in sequence. This would happen when identical requests are forwarded to the same client, before the first response is received by the server, and therefore before in can be added to the server-side cache. It could be worthwhile, from a perfromance perspective, to use a cache of class definitions, such that identical requests (same client-side class loader and same resource path) only result in a single lookup in the classpath.

To this effect, we propose to implement a cache in the client, as follows:
  • an identity hash map whose keys are class loaders
  • the values are hash maps where the key is a path in the classpath and the value is the byte[] for the resource located at that path. These could be implemented as SoftReferenceValueMaps to avoid out of memory conditions due to the cache