For solving the challenge of online detection of memory leaks in cloud-based infrastructure without having any internal application knowledge we introduce multiple algorithms. The main introduced algorithm is Precog (which works based on ML and uses history information) This algorithms solely use one metric i.e the system's memory utilization on which the application is deployed for the detection of a memory leak. In this work, there are 5 algorithms introduced