Notifications
Clear all

[Solved] Likes/ Reactions Slowing Down Load Time

64 Posts
2 Users
19 Reactions
2,030 Views
Posts: 1212
Topic starter
(@percysgrowroom)
Noble Member
Joined: 6 years ago

Hi everyone, I have a problem with likes and reactions on my site. 

My site is usually very fast, but after installing 2.0 there has been some issues, most of which have already been fixed thanks to the help of a few guys here, but there seems to be an issue with the likes and reactions. 

My site will be loading fine, with between 0.3 and 0.5 load time per page. But, when my users like posts, it causes slow queries where each like/ reaction causes an extra 0.6 load time on the page. The more likes there are, the longer it takes to load. 

How can i fix this? I have optimised databases, deactivated the mycred and mycred integration plug ins, but the problem doesn't go away. How can i stop the likes/reactions from slowing down my site? Any suggestions?

These problems are only there if you're logged into the site too, so it wont be possible to see it as a normal visitor. Let me know if there is any info you need from me to help diagnose the cause. 

Thanks in advance for any help!

 

63 Replies
Robert
Posts: 10591
Admin
(@robert)
Support Team
Joined: 9 years ago

Reactions also cached. I don't think the reactions can cause the problem.

In any case, we can try to delete old reactions and leave only the reactions made during the last months. If it's ok then I can provide an SQL to delete the old ones.

Posts: 1212
Topic starter
(@percysgrowroom)
Noble Member
Joined: 6 years ago
Posted by: @robert

Reactions also cached. I don't think the reactions can cause the problem.

This is the problem mate, according to my query checker, the extra load time is 95% down to the likes/reactions. 

Posted by: @robert

In any case, we can try to delete old reactions

I don't know about this mate.... The likes all add up to points for my users and some of my older posts have over 50 likes on them. Removing old likes on posts pretty much makes the whole thing redundant and I might as well remove the whole feature if this is the only solution. 

Is there another way to sort this other than the nuclear option of deleting all the older likes on posts? I dont like the idea of long time users on my site going from 1000 likes receive to 500, if you know what i mean. This isn't really a good option

5 Replies
Robert
Admin
(@robert)
Joined: 9 years ago

Support Team
Posts: 10591

@percysgrowroom,

Ok, then you have to wait for a few days. We're going to update the reaction cache functions very soon.

(@percysgrowroom)
Joined: 6 years ago

Noble Member
Posts: 1212

@robert here is a pic showing you the times:

Robert
Admin
(@robert)
Joined: 9 years ago

Support Team
Posts: 10591

@percysgrowroom,

BTW, how many rows do you have in the wp_wpforo_reactions table?

(@percysgrowroom)
Joined: 6 years ago

Noble Member
Posts: 1212

@robert I am just looking now but cant find where it tells me the total amount

if i show 500 lines per page... i have over 4k pages, so a lot of lines mate 

208MiB in size, my second largest under my cred tables

Robert
Admin
(@robert)
Joined: 9 years ago

Support Team
Posts: 10591

@percysgrowroom,

Posts: 1212
Topic starter
(@percysgrowroom)
Noble Member
Joined: 6 years ago

2,025,201.... 2 million mate... I think the official term is a s**t load.... 

4 Replies
Robert
Admin
(@robert)
Joined: 9 years ago

Support Team
Posts: 10591

@percysgrowroom,

o*g 😲, this requires a special solution. We've never tested wpForo with 2 m likes. Likes are not posts, they don't have all the cashing and boosting functions like posts and topics. You can have 10 m posts without any issue, but if you have more than 1 m likes then it may cause speed issues. Ok, we'll try to optimize wpForo for such cases and update the forum in a few days.

(@percysgrowroom)
Joined: 6 years ago

Noble Member
Posts: 1212

@robert Thanks mate. I don't know for sure, but may the best solution would be to make the table end now, and leave it as it is and start a new one where new likes go to, and the old likes stay as they are in an old, stable table? I don't know if that's possible, but that would work i should think 🙂

Robert
Admin
(@robert)
Joined: 9 years ago

Support Team
Posts: 10591

@percysgrowroom,

Please do not do that because the ID incrementing will be reset, and the new IDs will conflict with old IDs.

(@percysgrowroom)
Joined: 6 years ago

Noble Member
Posts: 1212

@robert No mate it was just a suggestion for you guys, I dont do anything with my databases unless I am told to, and even then is scary as s**t lol. 

I will wit for a couple of days and see how things are with the cache upgradeww in the next version. I hope youll can figure something out 

Posts: 1212
Topic starter
(@percysgrowroom)
Noble Member
Joined: 6 years ago

@robert Gotta say though, the new 2.0 is very nice! So much fresher and it has some awesome features man. I really like it, and so do the users of my site. I hope we can get these issues fixed because I don't want to go back to 1.0 lol 

Great work from you and the team, an awesome update! 

Page 1 / 4