Add a function to publish all the records under the specified collection