Patent ID: 8886615

Claim:
A method for optimizing a web service by adaptively using compression, comprising: receiving, via a processor, a request for a data file; determining, by the processor, whether the data file should be compressed based upon a previous request for the data file, wherein the determining comprises: accessing a database to find a record of the previous request associated with the data file; when the record of the previous request is found, then determining whether a processing time in compressing the data file is less than a transfer time of the data file; and determining whether the compression yield meets a predefined criterion of time savings, wherein it is determined that the data file should be compressed when the processing time is less than the transfer time of the data file and the compression yield is determined to meet the predefined criterion of time savings; compressing, by the processor, the data file when it is determined that the data file should be compressed; and sending, by the processor, the data file in a compressed format.