CodeIgniter Forums
Issue when using cache - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5)
+--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24)
+--- Thread: Issue when using cache (/showthread.php?tid=67763)



Issue when using cache - magikboo23 - 04-06-2017

I am using Last Codeigniter 3.1.3 and i have a issue with cache

I am using cache like this:


PHP Code:
$key "_sys_categories_";
        $how_much 3600;
        $categories = array();
        if ( !$categories $this->cache->file->get$key ) ) {
            $categories $this->category->read_all( array('status' => 1) );
            $this->cache->file->save$key$categories$how_much );
        

I receive this Warning:

[2017-04-05 00:00:04][E/codeigniter][URI=/apis/get/csv] Severity: Warning --> file_get_contents(application/cache/_sys_categories_): failed to open stream: No such file or directory /system/libraries/Cache/drivers/Cache_file.php 275

How to handle it?

In another place and for another cache i receive also this Warning

Severity: Warning --> file_get_contents(application/cache/_sys_properties_searchable_): failed to open stream: Stale file handle /system/libraries/Cache/drivers/Cache_file.php 275

Can you help me ?