• Bug
  • Status: Resolved
  • 2 Major
  • Resolution: Won't Fix
  • Byte Code Transform,Integration Modules
  • interfaces
  • Reporter: teck
  • May 19, 2008
  • 0
  • Watchers: 1
  • February 12, 2014
  • February 12, 2014

Description

There seem to be a few places in the ehcache TIMs where reflection is used needlessly. The methods that are being called are added with instrumentation, but that doesn’t mean they need to be called reflectively. Some different things that could be done are to add an interface with the new methods (preferred), or generate the calls with instrumentation as well

CacheTC.put() – every time an element is put in the cache, a reflective call is made to associate the element with the cache

EhcacheElementAdapter.java adds reflective calls to let the cache know when the TTL or timeToIdle are adjusted on the elements themselves.

Comments

Tim Eck 2008-05-20

From Alex Miler: “We should look at this in 2.6.1. The reflection was introduced during the last refactoring by Antonio/Saro. I’m not sure that I understand why it’s needed. Tim and I have talked about it a little. We don’t have any test specific to this.”

Fiona OShea 2008-12-09

first demonstrate that this is a problem, before working on it.

Hung Huynh 2014-02-12

DSO is discontinued