Hello,
I’ve read every thread about this topic but there is no answer that solves my issue.
My site is very well optimized, it fully loads in 2.2 seconds: https://imgur.com/lobFPdt
As soon as I add the 5 most popular posts, the site is ruined completely: https://imgur.com/lUIgn9b
The settings are OK, I’ve selected “last 24 hours” as suggested in another thread: https://imgur.com/MVDpfXL
As soon as I get rid of that single module of popular news, the site ranks perfect again.
The site gets just 30 or 40 news a day, so it shouldn’t be a query that consumes that amount of resources. We use a dedicated server and Cloudflare and no, it’s not a resources issue.
How can I solve this?
Thanks
Hello!
Some starting points to improve your website page speed are here:
– https://www.xtechkr.com/optimize-newspaper-theme/
– https://forum.tagdiv.com/how-to-make-the-site-faster/
– https://forum.tagdiv.com/topic/score-100100-pagespeed-with-newspaper-wordpress-theme/
– https://www.infophilic.com/get-almost-100-pagespeed-newspaper-theme/
– https://developers.google.com/speed/docs/insights/v5/about
– https://www.youtube.com/watch?v=tnkVapqhIHc
Please check the tutorials from those platforms gt metrix and Google Pagespeed Insights and I’m sure you can increase the page speed.
Please note that page speed is not covered by the support team: https://forum.tagdiv.com/newspaper-theme-support/
Thank you for understanding!
Hello,
You haven’t read my request. If so, there is no way you can answer that.
So, again:
My site is PERFECTLY optimized. Means: don’t share links on how to optimize my site, I don’t need them.
Once I activate a feature of your theme, the site performs extremely badly. Means: I’m not asking about page speed, I’m reporting an issue with that feature.
Can anyone help, please?
Thanks
Hi fferrero,
I believe that I understand what the problem could be.
You said that your website publish between 30- and 40 posts on day, that means you have many posts on your website and when the popular filter is used, this will not search only for the last posts posted in the last 24h it will search in all posts that you have published and after that will display the most popular of them in the last 24h. Due to this process, the display time of the results will increase in proportion to the number of posts in the database.
Unfortunately, there is no solution for this. There have been users who have used database caching, this has improved performance, but not much.
Thank you for your understanding!
Same for us. When traffic spikes on our site – usually we get spikes of a couple of hundred visitors per second – it kills the site with 503 errors – all because the most popular filter setting is generating piles of db requests.
This feature should have some settings to it that reduce the load on the db server – notably it should cache the result and refresh it every minute – which would mean a single db INNER JOIN per minutes, instead of hundreds. That seems like it would be the best solution…
Processing even one of these queries per second will kill mySQL and burn up CPU – this is lazy work here.
Yes, I didn’t reply because I felt that they don’t want to help.
I mean, the template is called “Newspaper” but you can’t post several posts a day because some features won’t work. Or once the site is 2 years old, due to the number of posts, some features won’t work.
That’s not advertised and it should be. Newspaper works only for small sites, not real newspapers.
-
This reply was modified 3 years by
fferrero.
Hi,
Anther suggestion would be to try and clean and repair the database, make a backup before attempting it, here are some guides
– https://www.wpbeginner.com/plugins/how-to-clean-up-your-wordpress-database-for-improved-performance/
– https://secure.wphackedhelp.com/blog/fix-corrupted-repair-wordpress-database/
Also, try one of the latest PHP version (8-8.1), php v7.4 is good but is not as as like php v8, I have seen theme users using either one of them successfully, on their websites.
Thank you!
The database is not in need of repair – the problem is purely one of a lack of caching – and a lack of forethought by the dev team.
Every single page request is generating a db request because the db won’t rely on the previous returned value in the db cache because it changes after every new pageview. Might not seem like a big deal, but when you get spikes of hundreds of visitors per second, even with a beefed up server, it slows mySQL, and the apache processes stack up waiting for a mySQL response.
It’s not rocket science. If the returned values for the block were set to only refresh every nth minutes, then it wouldn’t generate piles of complex queries – indeed, the query cannot be efficient, because it is checking pageviews across all posts for a given time-frame, which is not indexed – so even our tiny new site, which does 80k+ pageviews/day and has about 2k posts dies despite having an 8-core machine with 32gb of ram running with memcached on litespeed on PHP8.
Turning that filter off dropped average usage to consistently under 5% cpu usage, instead of 200% with 503 errors.
FFS- I can share the queries that are the cause – this isn’t some shot in the dark or loose assertion – the server was killed by this feature and traffic suffered, and we know because we checked, and could see the join queries that were responsible for the snowballing server load.
Here is an example of the queries that cause the problem:
| 147619 | [hostname]_wp_swlbr | localhost:33558 | [hostname]_v2 | Query | 6 | executing | SELECT SQL_CALC_FOUND_ROWS NOS3G_posts.ID
FROM NOS3G_posts INNER JOIN NOS3G_postmeta ON ( NOS |
| 147620 | [hostname]_wp_swlbr | localhost:33560 | [hostname]_v2 | Query | 1 | executing | SELECT SQL_CALC_FOUND_ROWS NOS3G_posts.ID
FROM NOS3G_posts INNER JOIN NOS3G_postmeta ON ( NOS |
| 147621 | [hostname]_wp_swlbr | localhost:33564 | [hostname]_v2 | Query | 12 | executing | SELECT SQL_CALC_FOUND_ROWS NOS3G_posts.ID
FROM NOS3G_posts INNER JOIN NOS3G_postmeta ON ( NOS |
| 147623 | [hostname]_wp_swlbr | localhost:33572 | [hostname]_v2 | Query | 9 | executing | SELECT SQL_CALC_FOUND_ROWS NOS3G_posts.ID
FROM NOS3G_posts INNER JOIN NOS3G_postmeta ON ( NOS |
| 147626 | [hostname]_wp_swlbr | localhost:33592 | [hostname]_v2 | Sleep | 0 | | NULL |
| 147631 | [hostname]_wp_swlbr | localhost:33636 | [hostname]_v2 | Query | 5 | executing | SELECT SQL_CALC_FOUND_ROWS NOS3G_posts.ID
FROM NOS3G_posts INNER JOIN NOS3G_postmeta ON ( NOS |
Smae issue here too. Is there any news about it?
Also, is the theme tested for PHP v8? Is it a safe change?
Thank you
Hi,
There will be a new theme update released in the following weeks. It is a relatively big update containing new features, demos, also some fixed and improvements/optimization.
As for PHP8 the theme is compatible with it. There are plenty of theme users using PHP8 with the theme for a while now. In case you encounter a problem please let us know, but there should be no problems
Thank you!
Hello @fferrero!
We will try to improve this theme more and more to optimize these aspects as well in every update and add new features. We will try our best to bring you the best solutions in the future and will take into consideration your queries.
Thank you so much for understanding!
Hi Team,
We are going through similar issue.
We have followed the above steps and we have done all the activities, disabling, deleting and installing plugin and cleared the cache and issue still persist. This is serious issue and coming from Theme only. We need solution on this.
Our Hosting provider says.. Can you please help us on this… This is causing issue as below SQL queries from theme are taking so many resources.
_—————
Your SQL queries are still a problem at the server level, we have told you this several times.
Here are some examples:
| 10426 | qyjm9184_prod | localhost | qyjm9184_tct | Query | 0 | Sending data | SELECT DISTINCT tct_posts.* FROM tct_posts LEFT JOIN tct_term_relationships AS ppma_tr ON ppma_tr. | 0.000 |
| 10427 | qyjm9184_prod | localhost | qyjm9184_tct | Query | 1 | Sending data | SELECT DISTINCT tct_posts.* FROM tct_posts LEFT JOIN tct_term_relationships AS ppma_tr ON ppma_tr. | 0.000 |
| 10428 | qyjm9184_prod | localhost | qyjm9184_tct | Query | 0 | Sending data | SELECT DISTINCT tct_posts.* FROM tct_posts LEFT JOIN tct_term_relationships AS ppma_tr ON ppma_tr. | 0.000 |
The system has disabled the SQL user to protect the integrity of the server.
You will have to correct everything at your level before reactivating the SQL user.
If you reactivate it without having corrected it. We will suspend our hosting service.
—–
Website is https://www.transcontinentaltimes.com/
Greetings, I am using your template in a high traffic portal (500,000 unique visits) and I am having the same problems to loading the page.
the provider tells me: I did noticed that when I load the site.
Apparently, I am seeing that the site is using the NewsPaper theme alongside the td_composer plugin which is known for generating expensive database queries. We have a few customers who have this issue with the theme.
We have looked at this issue numerous times and there is nothing that we can do specifically from our end to help. It is something the theme developer will need to address.
I recently had similar issues and found a solution to the problem.
Flex box elements using AJAX to pull in posts were causing major issues with database queries.
I changed to the post loop for the main content area, and removed any blocks using ajax from the footer.
All performance stats on the site dropped by 50% pretty much right away.
Aug 24th – 10am-11am
Response time: 1.36s
CPU Utilization: 97%
Memory Usage: 13GB
Aug 31st – 10am-11am
Response time: .592s
CPU Utilization: 46%
Memory Usage: 7.5GB
Our site has about 100,000 posts and around 500,000 unique visitors per month.
For anyone else having these issues:
Don’t use any blocks / elements with ajax to pull in post data unless you absolutely have to.