we've been discussing this long time ago, and now some users are finally
bugging me that they want to run OTDT and AJDT in the same eclipse
instance. At a first look both weaving mechanisms (built using the same
adaptor hooks) actually play well together, with minor hickups only,
but after restarting eclipse the class file cache kills the OTDT :)
(Not expecting to see already woven classes we'll add our stuff for
a second time => boom).
Question is: what would be needed to integrate a second weaver with
the caching infrastructure?
At a first glance I thought I could just check if the class bytes being
loaded already contain our stuff, and if so just skip weaving.
However, I don't know how to check cache validity. It seems there is
no explicit cache invalidation, but rather the cache will just grow
with new directories with new hash-names, right? (No cleanup, ever?)
From that it seems I would have to integrate with the mechanism
for computing fingerprints, but the actual computation of the finger
print is burried inside o.e.e.weaving.aspectj, and this doesn't seem to
be open to add more elements to the finger print.
I saw some activity to migrate the weaving service to the new standard
API. Has it been decided yet, how the caching service will fit into that
picture? Will it have to be redesigned, too?
How about an additional service like
String getFingerprintAddon(Bundle base)
Then I could register an implementation of the service that encodes
all OT/Equinox bundles that weave into the given base bundle,
I could even add the weaver version into that string,
and the caching service would collect all answers from all these
services for computing the total finger print. What do you think?
Should I file a bug or do you have a better idea?
equinox-dev mailing list