Ticket #290 (closed defect: fixed)

Opened 4 years ago

Last modified 8 months ago

doDelete() needs to invalidate instance cache

Reported by: hans Owned by: hans
Priority: normal Milestone: 1.3
Component: Generator Version: devel
Severity: normal Keywords:
Cc:

Description

When objects are deleted from the database, we need to remove them from the instance cache / identity map.

A doDelete() call with a single object need only invalidate that single entry from the cache. A doDelete() call with Criteria is probably better off either invalidating the entire set or performing a query and invalidating each match individually (that sounds like a horrible idea).

Change History

Changed 4 years ago by hans

In changeset:424, the behavior of retrieveByPK() was changed so that the database is always consulted when fetching content. This fixes this issue; however, there is still a danger in the instance map growing without bound, so we may still want to remove single instances from the map when we know they have been removed from the database.

Changed 4 years ago by hans

  • status changed from new to closed
  • resolution set to fixed

Closing this. Comment on flushing cache added to ticket:280.

Changed 8 months ago by francois

  • milestone changed from 2.0 to 1.3

also fixed in 1.3

Note: See TracTickets for help on using tickets.