[geotk] Using metadata.sql

William Temperley willtemperley at gmail.com
Fri Apr 6 04:10:15 EDT 2012


On 6 April 2012 01:46, Martin Desruisseaux
<martin.desruisseaux at geomatys.fr> wrote:
> Hello William
>
> I committed a fix and tested that it worked with your metadata (35 tables
> created). If you are using Maven, the fix is available on version
> 3.x-SNAPSHOT.
>
> Now, when a new metadata is inserted in the database, MetadataWriter will
> initially set the foreigner key constraint to the child table instead than
> the parent table. Then, every time a new metadata is inserted, the writer
> verifies the foreigner key constraints. If a conflict is found, the
> foreigner key is automatically dropped (I forgot to log a warning when such
> even happen - I will do that tomorrow).
>
> Of course verifying the foreigner key constraints on insertion has a cost,
> but this is hopefully not major. Anyway, this hack would completely
> disappear if PostgreSQL supports index inheritance in a future version.
>
> Please let me know if you meet other issue,
>
>    Martin
>
> P.S.: By the way, the metadata file that you provided looks very nice. Do
> you allow us to add it in the Geotk JUnit test suite?
>

Fix verified, thanks for doing this so fast!

I don't have the copyright on that XML file -- I copied it from here:
https://wiki.ceh.ac.uk/display/cehigh/Examples+in+XML+-+Dataset

Best regards,

Will Temperley


More information about the Geotoolkit mailing list