package org.springframework.cloud.endpoint.event;

import java.util.Set;
import java.util.concurrent.atomic.AtomicBoolean;

import org.springframework.boot.context.event.ApplicationReadyEvent;
import org.springframework.cloud.context.refresh.ContextRefresher;
import org.springframework.context.event.EventListener;

import lombok.extern.apachecommons.CommonsLog;

/**
 * Calls {@link RefreshEventListener#refresh} when a {@link RefreshEvent} is received.
 * Only responds to {@link RefreshEvent} after receiving an {@link ApplicationReadyEvent} as the RefreshEvent's might come to early in the application lifecycle.
 * @author Spencer Gibb
 */
@CommonsLog
public class RefreshEventListener {
	private ContextRefresher refresh;
	private AtomicBoolean ready = new AtomicBoolean(false);

	public RefreshEventListener(ContextRefresher refresh) {
		this.refresh = refresh;
	}

	@EventListener
	public void handle(ApplicationReadyEvent event) {
		this.ready.compareAndSet(false, true);
	}

	@EventListener
	public void handle(RefreshEvent event) {
		if (this.ready.get()) { // don't handle events before app is ready
			log.debug("Event received " + event.getEventDesc());
			Set<String> keys = this.refresh.refresh();
			log.info("Refresh keys changed: " + keys);
		}
	}
}

@@ -117,16 +117,101 @@
 olean;%0A%0A
+import org.apache.commons.logging.Log;%0Aimport org.apache.commons.logging.LogFactory;%0A
 import o
@@ -271,16 +271,16 @@
 yEvent;%0A
-
 import o
@@ -399,56 +399,8 @@
 r;%0A%0A
-import lombok.extern.apachecommons.CommonsLog;%0A%0A
 /**%0A
@@ -680,20 +680,8 @@
  */%0A
-@CommonsLog%0A
 publ
@@ -712,16 +712,89 @@
 tener %7B%0A
+%09private static Log log = LogFactory.getLog(RefreshEventListener.class);%0A
 %09private

Replace lombok logger