tiki-rename_page.php times out for popular articles (optimise)

RESOLVED INVALID

Status

RESOLVED INVALID
9 years ago
8 years ago

People

(Reporter: paulc, Assigned: paulc)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: sumo_only)

Attachments

(1 attachment)

(Assignee)

Description

9 years ago
Started from bug 444510, the code in wikilib->wiki_rename_page needs to be optimised. Renaming of popular articles times out and creates inconsistencies in the db.

Most of the work to rename is being done because tiki database tables do not use numeric id's to identify objects. For this specific situation, the page name is the primary key. Thus, changing the primary key causes huge overhead.

The long term solution is to redesign the tiki database to work with numeric id's rather than strings. Cheng mentioned a bug already filed about this latter aspect but I couldn't find it.
(Assignee)

Comment 1

9 years ago
Created attachment 389000 [details] [diff] [review]
patch, v1

This is at least better practice than the current code. Constructing a new object for every row in the result could be a significant slowdown. Hopefully it helps with bug 444510.
Assignee: nobody → paul.craciunoiu
Attachment #389000 - Flags: review?(smirkingsisyphus)
Attachment #389000 - Flags: review?(laura)
(Assignee)

Updated

9 years ago
Depends on: 495544

Comment 2

9 years ago
Did you profile or benchmark this?  

All optimizations need to be done emprirically, otherwise it's just a waste of time.

Comment 3

9 years ago
Comment on attachment 389000 [details] [diff] [review]
patch, v1

This doesn't look like an optiization.  Benchmark and resubmit when you have proof.
Attachment #389000 - Flags: review?(smirkingsisyphus)
Attachment #389000 - Flags: review?(laura)
Attachment #389000 - Flags: review-
(Assignee)

Updated

9 years ago
Whiteboard: tiki_bug
It does not look like this was ever applied. I also agree with Laura's comment. Won't upstream this.
Whiteboard: tiki_bug → sumo_only
Bugs in tikiwiki, going away.
Status: NEW → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.