Ticket #640 (closed Defect: fixed)

Opened 11 years ago

Last modified 11 years ago

Core: removing an association definition programmatically corrupts the DB

Reported by: jri Owned by: jri
Priority: Blocker Milestone: Release 4.3
Component: DeepaMehta Standard Distribution Version: 4.2
Keywords: Cc: dgf, Malte, JuergeN
Complexity: 3 Area:
Module: deepamehta-core

Description

The Core API's Type.removeAssocDef() method removes the Association Definition in memory but not in the DB. The sequence however is rebuild in the DB. Result is a corrupt DB. Launching the Webclient after a subsequent server restart let the server crash with:

java.lang.RuntimeException: DB inconsistency: type "org.deepamehta.wikidata.search_entity" has 6 association definitions but in sequence are 5

Note: before the server restart everything works fine as the type definitions in memory are OK.

Thanks to Malte for revealing that error along with his Wikidata plugin!
Thanks to JuergeN for tracking down the error!

See also #615.

Change History

comment:1 Changed 11 years ago by jri

  • Status changed from new to accepted

comment:2 Changed 11 years ago by Jörg Richter

Core fix: delete assoc def programatically (#640).

The Core API's Type.removeAssocDef() method properly removes the Association Definition from memory and DB.

As a consequence the Wikidata plugin does not cause an "DB inconsistency" exception anymore.
(However the latest version of the Wikidata plugin works around that error meanwhile.)

See #640.

comment:3 Changed 11 years ago by jri

  • Status changed from accepted to closed
  • Resolution set to fixed
Note: See TracTickets for help on using tickets.