Changed getMetaData to use PPI and updated tests

@pon @bsiddiqui @leore