Showing posts with label caching. Show all posts
Showing posts with label caching. Show all posts

Sunday, June 10, 2012

Set HTTP Caching Expiration, Recommended by Google PageSpeed


I ran tests on my website using Google's PageSpeed and it recommends that I "Leverage browser caching" and provided the following resource:

Tuesday, June 5, 2012

Monday, June 4, 2012

Why isn"t my javascript & css caching?


It's appears ONLY javascript and css are not caching ... but images are caching.

Dispelling the UIImage imageNamed: FUD


I see a lot of people saying imageNamed is bad but equal numbers of people saying the performance is good - especially when rendering UITableView s. See this SO question for example or this article on iPhoneDeveloperTips.com

Wednesday, May 16, 2012

What is a bytecode cache and how can I use one in PHP?


I searched on the Web and came to know that PHP code can be compiled to have performance boost. But how to do it? Can I compile both procedural and object oriented PHP code?

How are SoftReferences collected by JVMs in practice?


I have two separate caches running in a JVM (one controlled by a third party library) each using soft references. I would prefer for the JVM to clear out my controlled cache before the one controlled by the library. The SoftReference javadoc states:

Wednesday, May 9, 2012

Why all my files are not cached with apc op code?


I'm using APC (3.1.9) and Zend Framework,
however, only a bunch of file are being cached
(something like 10 / 400).

Do you have any ideas? I'm using the factory options
on a debian installation.


EDIT: It looks like the only file which are opcached are
 the one I manually call with  
require '';
however the ones which are loaded by
my autoloader are not.
Any ideas?

 
 
 
Runtime Settings




apc.cache_by_default    1

apc.canonicalize    1

apc.coredump_unmap  0

apc.enable_cli  0

apc.enabled 1

apc.file_md5    0

apc.file_update_protection  2

apc.filters 

apc.gc_ttl  3600

apc.include_once_override   0

apc.lazy_classes    0

apc.lazy_functions  0

apc.max_file_size   1M

apc.mmap_file_mask  

apc.num_files_hint  1000

apc.preload_path    

apc.report_autofilter   1

apc.rfc1867 0

apc.rfc1867_freq    0

apc.rfc1867_name    APC_UPLOAD_PROGRESS

apc.rfc1867_prefix  upload_

apc.rfc1867_ttl 3600

apc.serializer  default

apc.shm_segments    1

apc.shm_size    32M

apc.slam_defense    1

apc.stat    1

apc.stat_ctime  0

apc.ttl 0

apc.use_request_time    1

apc.user_entries_hint   4096

apc.user_ttl    0

apc.write_lock  1





here is apc.php screenshots
apc.php

The files that are getting opcached
php code

And the index.php (ZF) where I require files and register autoloader within Zend_Loader_Autoloader.


opcached files

Source: Tips4all

Sunday, April 22, 2012

Best Practice when Caching files in Android


I currently have my app caching image files in the cache sub-directory for the application. The images are used in a ListView and stored in a HashMap of SoftReferences to Bitmaps .

Sunday, April 8, 2012

Android take screen shot programatically


First off i am writing a root app so root permissions are no issue. I've searched and searched and found a lot of code that never worked for me here is what i've pieced together so far and sorta works. When i say sorta i mean it makes an image on my /sdcard/test.png however the file is 0 bytes and obviously can't be viewed.

Friday, February 24, 2012

Iphone runs ONLY from cache even when online


I am having a bit of trouble. I am making a mobile version of our website, and want to cache some of the more important pages, not just for use offline, but for added speed in some cases.