Adds correct logging for stat/retrieve