As far as post edit history is concerned, to avoid large db's or simply lots of edits being saved, would it be worth it to add an option for max # of post edit history entries to save? Anything older gets pruned as a new edit is saved (or afterward if this slows down the save process, or via a cron, whatever)
E.g.:
Max Post Edit History Entries: 10
Shows the OP, and then the 9 most recent edits, perhaps. As it sits it appears to keep all history regardless of how many edits the user does, even if it's semi-small changes that still exceed the min character change limit, it results in a near dupe of the post in the database. Having an option for max entries would at least give SOME boundaries as to how much data is retained with individual post edits. For most users I don't think they need to know every single edit, however the most recent 10 would be more than sufficient, I could be wrong though, but at any rate it would be an option and setting it to 0 would disable it. This could be rather useless though, I bet most users won't exceed 3 edits max.
I realize users could essentially make 10 bogus edits to hide anything before that if they were so inclined. Alternately I guess they could change their post 5 (or whatever setting your minimum character count is) characters at a time to avoid the history / edit log. Who would do this and why is beyond me.
Or,
better yet...
Instead of saving entire posts, could it be possible to save only the post differences? I'm not sure how this would work on the backend or if it's even possible within reason, but essentially it would avoid near dupe posts in the db, and instead the "difference" would be its own content in its own column/row or whatever, rather than including the entire previous post in that new bit of data.
So in theory it would work similar to this mockup:
I go back and view the edit above this one (the most recent one):
The text outlined in blue is the content in the database for that new post edit. The end result are 2 rows (or whatever) with the following content:
Row 1: This is the OP.
Row 2: This is new text.
Instead of:
Row 1: This is the OP.
Row 2: This is the OP. This is new text.
If text is removed, that could also be displayed:
Row 1: This is the OP.
Row 2: OP.
End result when viewing the latest post edit: This is the
[OP
.]
Not sure if any of this is possible or how it would know what to dump in the db / where to place it in the original post (especially on large complex edits...), all of this is beyond me, I'm not a developer, these were just some quick thoughts without thinking too much about
how (sorry!). This sort of makes me curious to find out how XenCarta stores its wiki page history, probably the same way you're doing it. Details would obviously need to be worked out, just throwing this out there. I have a feeling this post is rather useless, and instead just a wall of text.
I realize there's potential issues to either of these ideas, and I'm not sure how you'd work out those intricacies but at either rate perhaps this would be a start to a better idea (I'm pretty bad with ideas) / solution, perhaps not, perhaps the best way to do it is exactly how you have it - beats me! I really don't know what the most optimized / efficient / smart way to do it would be.
At any rate the addon is great, the post edit history is very useful. I'm just worried about the overall HD/DB use especially on a larger forum. I've got the Edit Post Log grace period set to 5 mins and edit post minimum characters set to 8 in attempts to reduce the # of post edits that get kept. I just hope post edits aren't very wasteful as time goes on. It may very well be much much lower than I suspect and I'm blabbering for nothing. I'll have to keep an eye on the user log for the next couple months.
Edit: Also just a quick thing I noticed:
Is it possible for the next version use a template conditional or similar to hide
reason if there was nothing set? Rather than having it always show with N/A?
Edit2: Just a quick question, are edits made to others posts logged in the User log? or does it only log actions performed on the users content by the user creator? I edited someones post and though it appeared in the Last Edited by, it wasn't logged. Just curious.