I spoke with Tony today and he pointed me in a different direction and I think he is on to something.
I checked the cache folder and it is empty in all of my installs of OpenEMR. How do I get the program to use the cache folder for the calendar?
Sherwin
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Since is seems that only the Calendar is slow, I'm wondering if you might have added a very large 'recurring' schedule. Like spanning many years. Not sure if that would cause it to be slow, but it might be another possibility
-Tony
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
all of my clients do block out of time. They have blocks of time that are recurring schedules such as lunch and other blocks of time that do not want patients scheduled for. Instead of just remembering, they create blocked timezones on the calendar.
Sherwin
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Sherwin,
interface\main\calendar\modules\PostCalendar\pnincludes\Smarty\Smarty.class.php
has a lot of setting for caching/compiling of smarty templates. However, given that my system (with very little data) returns the calendar in 62 milliseconds without smarty caching enabled, suggests to me that your problem won't be solved by tweaking caching settings.
You've most likely got a query running amok, or maybe too many "recurring events"
Profiling with xdebug will show you exactly how much time each piece of code is taking to execute when generating the calendar and is likely to be more productive than all of this "guessing" at the problem.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Yehster, I ran xdebug and posted the results some time back. I just ran it again using the profiling and this line here takes the longest to load. It take 2.09s to load. I have over 6000 entries in my calendar table.
Last Modified Thu Jan 05 2012 22:05:27 GMT-0500 (Eastern Standard Time)
Last Fetched Thu Jan 05 2012 22:05:27 GMT-0500 (Eastern Standard Time)
Expires Wed Dec 31 1969 19:00:00 GMT-0500 (Eastern Daylight Time)
Data Size 53846
Fetch Count 14
Device disk
This next line take 983ms to load which is the second longest time to load.
Last Modified Thu Jan 05 2012 21:58:25 GMT-0500 (Eastern Standard Time)
Last Fetched Thu Jan 05 2012 21:58:25 GMT-0500 (Eastern Standard Time)
Expires Wed Dec 31 1969 19:00:00 GMT-0500 (Eastern Daylight Time)
Data Size 36897
Fetch Count 2
Device disk
Why is the expire date in the past? I seem to have more questions than answers.
Thanks for your help all
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
How do I recomplie smarty after changing the settings? The default settings in the system is not use cache. I turned it on but it is still not caching. The other default is to compile everytime. I set that to false. But is still compiling everytime. So, how do I get the system to accept the new setting?
Sherwin
openmedpractice.com
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
This has been a great discussion!
I spoke with Tony today and he pointed me in a different direction and I think he is on to something.
I checked the cache folder and it is empty in all of my installs of OpenEMR. How do I get the program to use the cache folder for the calendar?
Sherwin
Since is seems that only the Calendar is slow, I'm wondering if you might have added a very large 'recurring' schedule. Like spanning many years. Not sure if that would cause it to be slow, but it might be another possibility
-Tony
Tony,
all of my clients do block out of time. They have blocks of time that are recurring schedules such as lunch and other blocks of time that do not want patients scheduled for. Instead of just remembering, they create blocked timezones on the calendar.
Sherwin
But shouldn't the program be creating a cache of the calendar?
Sherwin
Sherwin,
interface\main\calendar\modules\PostCalendar\pnincludes\Smarty\Smarty.class.php
has a lot of setting for caching/compiling of smarty templates. However, given that my system (with very little data) returns the calendar in 62 milliseconds without smarty caching enabled, suggests to me that your problem won't be solved by tweaking caching settings.
You've most likely got a query running amok, or maybe too many "recurring events"
Profiling with xdebug will show you exactly how much time each piece of code is taking to execute when generating the calendar and is likely to be more productive than all of this "guessing" at the problem.
Yehster, I ran xdebug and posted the results some time back. I just ran it again using the profiling and this line here takes the longest to load. It take 2.09s to load. I have over 6000 entries in my calendar table.
https://www.openmedpractice.com/East/interface/main/calendar/index.php?module=PostCalendar&func=view&viewtype=day&framewidth=930
Under the cache tab it has this:
Last Modified Thu Jan 05 2012 22:05:27 GMT-0500 (Eastern Standard Time)
Last Fetched Thu Jan 05 2012 22:05:27 GMT-0500 (Eastern Standard Time)
Expires Wed Dec 31 1969 19:00:00 GMT-0500 (Eastern Daylight Time)
Data Size 53846
Fetch Count 14
Device disk
This next line take 983ms to load which is the second longest time to load.
https://www.openmedpractice.com/East/library/textformat.js
Under the cache tab it list this information
Last Modified Thu Jan 05 2012 21:58:25 GMT-0500 (Eastern Standard Time)
Last Fetched Thu Jan 05 2012 21:58:25 GMT-0500 (Eastern Standard Time)
Expires Wed Dec 31 1969 19:00:00 GMT-0500 (Eastern Daylight Time)
Data Size 36897
Fetch Count 2
Device disk
Why is the expire date in the past? I seem to have more questions than answers.
Thanks for your help all
That is firebug data not xdebug data.
Hello!
How do I recomplie smarty after changing the settings? The default settings in the system is not use cache. I turned it on but it is still not caching. The other default is to compile everytime. I set that to false. But is still compiling everytime. So, how do I get the system to accept the new setting?
Sherwin
openmedpractice.com