Review main Merged

80752[TASK] Remove DataHandler->checkStoredRecord()

Christian Kuhn CR +2 V +2 Normal +82 −114 updated 08/30/23, 08:30

Commit message

Well, that functionality is hilarious: Sometimes,
when the DataHandler updates or inserts database
rows, it calls checkStoredRecord() which fetches
the just written row to verify the row has
actually been written correctly.

* The implementation is inconsistent, DH does
  not do this for all update queries.
* The default configuration is to fetch the row,
  but to *not* check the fields, rendering the
  entire thing useless, but still have the
  additional query.
* *If* DH would actually find some collision, it
  will bury that information as entry in sys_log.
* We fiddled with this in #79438 for v8 already to
  allow suppressing overhead via TYPO3_CONF_VARS.
  These toggles are widely unknown and most likely
  used very seldom.
* Inserting invalid data a DB can not persist most
  likely raises doctrine exceptions, especially with
  many database instances being configured in "strict"
  mode nowadays.
* With our current efforts to configure database
  columns automatically by auto-creating them from
  TCA, we further reduce the risk of columns not
  being configured correctly for given data.

The patch:

* Removes (@internal) DataHandler->checkStoredRecord()
* Keeps two related DataHandler properties as b/w
  compat layer, but renders them unused.
* Removes two related TYPO3_CONF_VARS.

Review

  • Code review CR +2

    Imported before Forger kept the single votes, the next import adds them.

  • Verified V +2

    Imported before Forger kept the single votes, the next import adds them.

Issues 3

Files 6