jimurl / gnfac-d6-d8

0 stars 0 forks source link

Caching of weather data #65

Closed jimurl closed 6 years ago

jimurl commented 6 years ago

... Happens on regional conditions pages and also on the weather station tables pages themselves. Oddly, slightly different non-current values on each (! ). i.e., it doesn't always have the most recent weather data from SNOTEL or from rpt files.

Doug, can you confirm you are seeing this also?

solution 1: prevent drupal from caching these tables.

solution 2: write up a cron - hoover data routine to fetch the data every half hour or so. Could also be useful if we have a map weather stations, could have a popup with most recent data from each station that way. Could also therefore rewrite the google maps js each time as well.

jimurl commented 6 years ago

this appears to be resolved with adding to the gnfac_theme_preprocess_block this: $vars['derivative_plugin_id'] == '7da ... aab'

Which applies only to SNOTEL blocks. but the other data types appear to be page - generated, and not cached ( yet )