#publish method, Added configuration and logger