Cast values as an int to ensure that null values are not set.
Added cache settings to enable/disable the page cache overall and also set the time for which a page is cached.