Jody Garnett a écrit :
> Thanks Martin ... so back to the actual bug then? It seems you fixed the 
> problem at line 576:
>> assertSame(((Conversion) operation).getMethod(), ((Conversion) 
>> projection).getMethod());
> What was the fix? What did I mess up - was it hints like I suspected?

It was not hints neither ReferencingFactoryContainer. In ThreadedEpsgFactory at 
line 498-500 (revision 25972), the following code:

     if (factory instanceof FactoryUsingSQL {
         ((FactoryUsingSQL) factory).buffered = this;
     }

has not been updated for the "FactoryUsingSQL --> DirectEpsgFactory" class name 
change. Because subclasses do not create FactoryUsingSQL instance anymore (they 
create various DirectEpsgFactory subclasses that do not extend 
FactoryUsingSQL), 
the "buffered" backpointer was not set to the BufferedAuthorityFactory instance 
anymore. Consequently, the whole caching system (not only OperationMethod) was 
disabled during recursive call. Consequently the EPSG factory must have been 
much slower (probably 3 times slower) during that time.

For safety, I applied the "FactoryUsingSQL --> DirectEpsgFactory" name change 
on 
a project-wide basis yesterday. If there is some "FactoryUsingSQL" subclasses 
that are flagged as "@since 2.4", I suggest to delete them.

On BufferedAuthorityFactory, I suggest to just ignore this class for now. Right 
now ThreadedAuthorityFactory is independent, so I would suggest to just forget 
about BufferedAuthorityFactory, do the work you already planned, and revisit 
only after the work is done if there is some ThreadedAuthorityFactory piece of 
code that can be retrofitted in BufferedAuthorityFactory. Maybe it will be 
obvious from the code that we have nothing to gain from such retrofit and we 
should just deprecate BufferedAuthorityFactory and its DeferredAuthorityFactory 
subclass.

        Martin

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Geotools-devel mailing list
Geotools-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to