added method for storemetadata