Get Cache With Cactivedataprovider

I was able to store the auery using “CActiveDataProvider” in cache, but it seem like it’s not get from the cache, what i am doing wrong?

My config is:


 'cache'=>array(

    			'class'=>'CFileCache',

    		),

Controller:


$dependecy = new CDbCacheDependency('SELECT MAX(id) FROM {{table}}');

 

		$dataProvider = new CActiveDataProvider(Model::model()->cache(3600, $dependecy, 2), array ( 

		    'criteria' => array ( 

		        'order'=>'date DESC',

		    ),

		    'pagination' => array ( 

		       	 	//'pageSize' => '5',

		    ),

		));