Free Support Forum - groupdocs.com

Clear Cache created by conversion


#1

Hi,

When used conversionConfig.setUseCache(true); after setting the cache directory path, How do we clear the cache files corresponding to this particular conversion after conversion is complete?


#2

@Tirumala_Reddy,

Let me guide you about setUseCache property.
This property is used to define, either the cache should be used or not. API doesn’t provide any facility to clear or remove cached files. However, you can write your own code to delete files from such a directory.
In other words if you set this property to false. API will not process cached files for a particular document (a document that is already cached).


#3

If i set setUseCache(false); conversion still works right ? What do you mean by “API will not process cached files for a particular document” ? it wouldnt even cache if i set to false right ?

Any performance impact if set useCache as false ?


#4

@Tirumala_Reddy,

Yes, conversion will work either way.
Let me elaborate the difference. If you convert a document with setUseCache(true) that document will be cached (stored in cache folder). Next time when you process same document, it will not take that much time.

This is how cache works. Its helpful if you convert same document again (if document conversion at first attempt takes 1 minute it will take far less time in next attempt).

Yes. Data will not be cached if you set it false.


#5

Thank you. That helps.


#6

@Tirumala_Reddy,

You’re welcome.