Saltar navegación

[Resuelto] Very slow query

This support ticket is created hace 3 años, 4 meses. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

Este tema contiene 3 respuestas, tiene 2 mensajes.

Última actualización por Minesh hace 3 años, 3 meses.

Asistido por: Minesh.

Autor
Mensajes
#2152941
Captura de pantalla 2021-08-26 183310.jpg

Hello,

I have a problem with the page loading time.: enlace oculto
It takes almost 8 seconds to load.
Query monitor shows that I have 11 slow queries. I have installed Litespeed cache.
This page will be updated, approximately once a week.

Any suggestions on how can I improve the loading time? Thanks!

#2153471

Minesh
Supporter

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

view's load time is depend on the server resources like CPU, ram as well as hosting.

I see you are using the nested views and the amount of data you are retrieving seems causing the issue as there are hundreds of posts are listed using the nested views.

Please check the following Doc that may help you:
=> https://toolset.com/documentation/legacy-features/views-plugin/how-to-use-views-parametric-search-on-large-sites/

#2153797

I have tried to fix the problem as follows:

Force to cache the 3 nested views with the attribute cached="force":

[wpv-view name="secciones-carta" cached="force"]
--[wpv-view name="contenido-de-cada-seccion-de-la-carta" cached="force"]
----[wpv-view name="alergenos-del-plato" cached="force"]

Now the three views are cached on server and the page where I display de views load fast.

But the problem comes when I modify something using a front end form to update a post. The view does not display the changes.

What can I do to clean the cache after update any post in the view ?

Thanks

#2156105

Minesh
Supporter

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

The value for cache attribute for the view's is either On or Off as you can see with our Docs:
=> https://toolset.com/documentation/programmer-reference/views/views-shortcodes/#wpv-view

I'm not sure from where you find the value cached="force". By default view's cache attribute value is On.

Here is how you can enable-disable cache using the filter hook: wpv_filter_disable_caching
=> https://toolset.com/forums/topic/some-block-settings-are-no-longer-work-after-a-simple-page-refresh/page/2/#post-1514623