[hibernate-dev] instrument tasks
Steve Ebersole
steve.ebersole at jboss.com
Wed Aug 2 11:14:37 EDT 2006
So Scott has finished up HHH-1931 in regards to the cglib
instrumentation task.
The underlying issue was that the javassist and cglib versions did
slightly different things in regards to instrumenting field access.
Javassist only instrumented access to fields which are declared on the
class being transformed; cglib transformed ever field access. Both are
actually valuable approaches in different situations. For the time
being, the cglib based task was made to not instrument access to fields
declared outside the transforming class. I think the opposite approach
is valuable when the field's owner is also being instrumented. So
another capability to add here is for both of the instrument tasks to be
able to instrument access to fields which are declared outside the class
being transformed currently as long as the declaring class is also being
transformed.
Another capability that I would like to see would be to limit
instrumentation to only fields which are defined in a Hibernate mapping.
Currently the instrument tasks do not know anything about the mappings,
so the first change to allow this would be facilitate the passing or
definition of a Configuration into the tasks. The tools already have
such a task used in their ant task stacks. So we would need to decide
whether it makes more sense to move the instrument tasks over to the
tools subproject, or to consume the <configuration/> sub task from tools
into core and make use of it from the instrument tasks.
More information about the hibernate-dev
mailing list