Task #46616

Evaluate usage of INSERT DELAYED INTO for DatabaseWriter

Added by Steffen Müller almost 9 years ago. Updated over 8 years ago.

Status:
Rejected
Priority:
Should have
Assignee:
-
Category:
Logging API
Start date:
2013-03-23
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
6.2


Related issues

Related to Logging Project - Bug #28481: sys_log insertions should not take processing timeRejected2011-07-26

Actions
#1

Updated by Steffen Müller almost 9 years ago

I'd suggest to first profile the gain with INSERT DELAY INTO using some typical actions in TYPO3 (create/update record in BE, show list module in BE, frontend with standard content elements, frontend with plugins).

If there's a significant gain, we should introduce this query type to the DB API.
Finaly adapt this in the DatabaseWriter.

#2

Updated by Steffen Müller almost 9 years ago

  • Status changed from New to Needs Feedback

Anyone willing to do some profiling?

#3

Updated by Steffen Müller almost 9 years ago

http://dev.mysql.com/doc/refman/5.5/en/insert-delayed.html says: "Note that INSERT DELAYED is slower than a normal INSERT if the table is not otherwise in use."

What does that mean for sys_log table? The only queries done on that table are INSERTS triggered by log events and SELECTS triggered when someone views the BE log. Does that mean we even slow down logging with INSERT DELAYED INTO?

#4

Updated by Steffen Müller almost 9 years ago

Finally "INSERT DELAYED works only with MyISAM, MEMORY, ARCHIVE, and BLACKHOLE tables."

No InnoDB support. This should also be compared to regular INSERTS on InnoDB

#5

Updated by Georg Großberger over 8 years ago

And DELAYED has been deprecated. Using it is not recommended.

They are pushed into a separate thread to speed up on the client side. Slower means (AFAIK), that this threads needs to wait until other inserts pushed through the same connection are done. So in the worst case, it is inserted once the PHP execution stops and the connection is closed.

#6

Updated by Steffen Müller over 8 years ago

  • Status changed from Needs Feedback to Rejected
  • TYPO3 Version set to 6.2

Also available in: Atom PDF