[KARAF-2498] Change log level to DEBUG for blocked resources git-svn-id: https://svn.apache.org/repos/asf/karaf/cellar/branches/cellar-2.3.x@1528931 13f79535-47bb-0310-9956-ffa450edef68
Project: http://git-wip-us.apache.org/repos/asf/karaf-cellar/repo Commit: http://git-wip-us.apache.org/repos/asf/karaf-cellar/commit/27bd59c4 Tree: http://git-wip-us.apache.org/repos/asf/karaf-cellar/tree/27bd59c4 Diff: http://git-wip-us.apache.org/repos/asf/karaf-cellar/diff/27bd59c4 Branch: refs/heads/cellar-2.3.x Commit: 27bd59c49847836be459c22cd1e848a64e391296 Parents: dcd671e Author: jbonofre <jbonofre@13f79535-47bb-0310-9956-ffa450edef68> Authored: Thu Oct 3 16:47:09 2013 +0000 Committer: jbonofre <jbonofre@13f79535-47bb-0310-9956-ffa450edef68> Committed: Thu Oct 3 16:47:09 2013 +0000 ---------------------------------------------------------------------- .../karaf/cellar/bundle/BundleEventHandler.java | 6 ++-- .../karaf/cellar/bundle/BundleSynchronizer.java | 10 +++--- .../cellar/bundle/LocalBundleListener.java | 6 ++-- .../config/ConfigurationEventHandler.java | 4 +-- .../config/ConfigurationSynchronizer.java | 8 ++--- .../config/LocalConfigurationListener.java | 4 +-- .../karaf/cellar/core/command/Command.java | 6 ++-- .../core/control/ManageGroupCommandHandler.java | 1 - .../control/ManageHandlersCommandHandler.java | 5 +-- .../cellar/core/discovery/DiscoveryTask.java | 2 -- .../cellar/core/event/EventDispatchTask.java | 34 ++++++++++---------- .../karaf/cellar/dosgi/EndpointDescription.java | 2 -- .../cellar/dosgi/RemoteServiceCallHandler.java | 6 ++-- .../karaf/cellar/event/ClusterEventHandler.java | 4 +-- .../apache/karaf/cellar/event/EventSupport.java | 4 +-- .../karaf/cellar/event/LocalEventListener.java | 5 ++- .../cellar/features/FeaturesEventHandler.java | 4 +-- .../karaf/cellar/features/FeaturesSupport.java | 4 +-- .../cellar/features/FeaturesSynchronizer.java | 4 +-- .../cellar/features/LocalFeaturesListener.java | 6 ++-- .../cellar/features/RepositoryEventHandler.java | 2 +- .../cellar/hazelcast/HazelcastGroupManager.java | 2 +- .../karaf/cellar/hazelcast/QueueConsumer.java | 2 +- .../karaf/cellar/hazelcast/QueueProducer.java | 2 +- .../karaf/cellar/hazelcast/TopicConsumer.java | 2 +- .../karaf/cellar/hazelcast/TopicProducer.java | 2 +- .../factory/HazelcastConfigurationManager.java | 2 +- .../hazelcast/merge/CellarMergePolicy.java | 2 +- .../karaf/cellar/obr/ObrBundleEventHandler.java | 4 +-- .../karaf/cellar/obr/ObrUrlEventHandler.java | 4 +-- .../karaf/cellar/obr/ObrUrlSynchronizer.java | 4 +-- 31 files changed, 72 insertions(+), 81 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/bundle/src/main/java/org/apache/karaf/cellar/bundle/BundleEventHandler.java ---------------------------------------------------------------------- diff --git a/bundle/src/main/java/org/apache/karaf/cellar/bundle/BundleEventHandler.java b/bundle/src/main/java/org/apache/karaf/cellar/bundle/BundleEventHandler.java index 2cbf983..1f2ae28 100644 --- a/bundle/src/main/java/org/apache/karaf/cellar/bundle/BundleEventHandler.java +++ b/bundle/src/main/java/org/apache/karaf/cellar/bundle/BundleEventHandler.java @@ -48,13 +48,13 @@ public class BundleEventHandler extends BundleSupport implements EventHandler<Cl public void handle(ClusterBundleEvent event) { // check if the handler switch is ON if (this.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR BUNDLE: {} switch is OFF, cluster event is not handled", SWITCH_ID); + LOGGER.debug("CELLAR BUNDLE: {} switch is OFF, cluster event is not handled", SWITCH_ID); return; } // check if the node is local if (!groupManager.isLocalGroup(event.getSourceGroup().getName())) { - LOGGER.info("CELLAR BUNDLE: node is not part of the event cluster group"); + LOGGER.debug("CELLAR BUNDLE: node is not part of the event cluster group"); return; } @@ -65,7 +65,7 @@ public class BundleEventHandler extends BundleSupport implements EventHandler<Cl List<Feature> matchingFeatures = retrieveFeature(event.getLocation()); for (Feature feature : matchingFeatures) { if (!isAllowed(event.getSourceGroup(), "features", feature.getName(), EventType.INBOUND)) { - LOGGER.warn("CELLAR BUNDLE: bundle {} is contained in the feature {} marked as BLOCKED INBOUND in cluster group {}", event.getLocation(), feature.getName(), event.getSourceGroup().getName()); + LOGGER.debug("CELLAR BUNDLE: bundle {} is contained in the feature {} marked as BLOCKED INBOUND in cluster group {}", event.getLocation(), feature.getName(), event.getSourceGroup().getName()); return; } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/bundle/src/main/java/org/apache/karaf/cellar/bundle/BundleSynchronizer.java ---------------------------------------------------------------------- diff --git a/bundle/src/main/java/org/apache/karaf/cellar/bundle/BundleSynchronizer.java b/bundle/src/main/java/org/apache/karaf/cellar/bundle/BundleSynchronizer.java index e2ffbff..4413f54 100644 --- a/bundle/src/main/java/org/apache/karaf/cellar/bundle/BundleSynchronizer.java +++ b/bundle/src/main/java/org/apache/karaf/cellar/bundle/BundleSynchronizer.java @@ -50,7 +50,7 @@ public class BundleSynchronizer extends BundleSupport implements Synchronizer { if (isSyncEnabled(group)) { pull(group); push(group); - } else LOGGER.warn("CELLAR BUNDLE: sync is disabled for cluster group {}", group.getName()); + } else LOGGER.debug("CELLAR BUNDLE: sync is disabled for cluster group {}", group.getName()); } } } @@ -95,7 +95,7 @@ public class BundleSynchronizer extends BundleSupport implements Synchronizer { } catch (BundleException e) { LOGGER.error("CELLAR BUNDLE: failed to pull bundle {}", id, e); } - } else LOGGER.warn("CELLAR BUNDLE: bundle {} is marked BLOCKED INBOUND for cluster group {}", bundleLocation, groupName); + } else LOGGER.debug("CELLAR BUNDLE: bundle {} is marked BLOCKED INBOUND for cluster group {}", bundleLocation, groupName); } } } @@ -115,7 +115,7 @@ public class BundleSynchronizer extends BundleSupport implements Synchronizer { // check if the producer is ON if (eventProducer.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR BUNDLE: cluster event producer is OFF"); + LOGGER.debug("CELLAR BUNDLE: cluster event producer is OFF"); return; } @@ -180,7 +180,7 @@ public class BundleSynchronizer extends BundleSupport implements Synchronizer { eventProducer.produce(event); } - } else LOGGER.warn("CELLAR BUNDLE: bundle {} is marked as BLOCKED OUTBOUND for cluster group {}", bundleLocation, groupName); + } else LOGGER.debug("CELLAR BUNDLE: bundle {} is marked as BLOCKED OUTBOUND for cluster group {}", bundleLocation, groupName); } } finally { Thread.currentThread().setContextClassLoader(originalClassLoader); @@ -208,7 +208,7 @@ public class BundleSynchronizer extends BundleSupport implements Synchronizer { result = Boolean.parseBoolean(propertyValue); } } catch (IOException e) { - LOGGER.error("CELLAR BUNDLE: failed to check if sync is enabled", e); + LOGGER.warn("CELLAR BUNDLE: failed to check if sync is enabled", e); } return result; } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/bundle/src/main/java/org/apache/karaf/cellar/bundle/LocalBundleListener.java ---------------------------------------------------------------------- diff --git a/bundle/src/main/java/org/apache/karaf/cellar/bundle/LocalBundleListener.java b/bundle/src/main/java/org/apache/karaf/cellar/bundle/LocalBundleListener.java index b8d6ace..9f8df0b 100644 --- a/bundle/src/main/java/org/apache/karaf/cellar/bundle/LocalBundleListener.java +++ b/bundle/src/main/java/org/apache/karaf/cellar/bundle/LocalBundleListener.java @@ -58,7 +58,7 @@ public class LocalBundleListener extends BundleSupport implements SynchronousBun // check if the producer is ON if (eventProducer.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR BUNDLE: cluster event producer is OFF"); + LOGGER.debug("CELLAR BUNDLE: cluster event producer is OFF"); return; } @@ -109,7 +109,7 @@ public class LocalBundleListener extends BundleSupport implements SynchronousBun List<Feature> matchingFeatures = retrieveFeature(bundleLocation); for (Feature feature : matchingFeatures) { if (!isAllowed(group, "features", feature.getName(), EventType.OUTBOUND)) { - LOGGER.warn("CELLAR BUNDLE: bundle {} is contained in feature {} marked BLOCKED OUTBOUND for cluster group {}", bundleLocation, feature.getName(), group.getName()); + LOGGER.debug("CELLAR BUNDLE: bundle {} is contained in feature {} marked BLOCKED OUTBOUND for cluster group {}", bundleLocation, feature.getName(), group.getName()); return; } } @@ -124,7 +124,7 @@ public class LocalBundleListener extends BundleSupport implements SynchronousBun Thread.currentThread().setContextClassLoader(originalClassLoader); } - } else LOGGER.warn("CELLAR BUNDLE: bundle {} is marked BLOCKED OUTBOUND for cluster group {}", bundleLocation, group.getName()); + } else LOGGER.debug("CELLAR BUNDLE: bundle {} is marked BLOCKED OUTBOUND for cluster group {}", bundleLocation, group.getName()); } } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/config/src/main/java/org/apache/karaf/cellar/config/ConfigurationEventHandler.java ---------------------------------------------------------------------- diff --git a/config/src/main/java/org/apache/karaf/cellar/config/ConfigurationEventHandler.java b/config/src/main/java/org/apache/karaf/cellar/config/ConfigurationEventHandler.java index 55cc09f..f1357f5 100644 --- a/config/src/main/java/org/apache/karaf/cellar/config/ConfigurationEventHandler.java +++ b/config/src/main/java/org/apache/karaf/cellar/config/ConfigurationEventHandler.java @@ -45,7 +45,7 @@ public class ConfigurationEventHandler extends ConfigurationSupport implements E // check if the handler is ON if (this.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR CONFIG: {} switch is OFF, cluster event not handled", SWITCH_ID); + LOGGER.debug("CELLAR CONFIG: {} switch is OFF, cluster event not handled", SWITCH_ID); return; } @@ -90,7 +90,7 @@ public class ConfigurationEventHandler extends ConfigurationSupport implements E } catch (IOException ex) { LOGGER.error("CELLAR CONFIG: failed to update local configuration", ex); } - } else LOGGER.warn("CELLAR CONFIG: configuration with PID {} is marked BLOCKED INBOUND for cluster group {}", pid, groupName); + } else LOGGER.debug("CELLAR CONFIG: configuration with PID {} is marked BLOCKED INBOUND for cluster group {}", pid, groupName); } public void init() { http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/config/src/main/java/org/apache/karaf/cellar/config/ConfigurationSynchronizer.java ---------------------------------------------------------------------- diff --git a/config/src/main/java/org/apache/karaf/cellar/config/ConfigurationSynchronizer.java b/config/src/main/java/org/apache/karaf/cellar/config/ConfigurationSynchronizer.java index 41d0a46..c1804fa 100644 --- a/config/src/main/java/org/apache/karaf/cellar/config/ConfigurationSynchronizer.java +++ b/config/src/main/java/org/apache/karaf/cellar/config/ConfigurationSynchronizer.java @@ -51,7 +51,7 @@ public class ConfigurationSynchronizer extends ConfigurationSupport implements S if (isSyncEnabled(group)) { pull(group); push(group); - } else LOGGER.warn("CELLAR CONFIG: sync is disabled for cluster group {}", group.getName()); + } else LOGGER.debug("CELLAR CONFIG: sync is disabled for cluster group {}", group.getName()); } } } @@ -95,7 +95,7 @@ public class ConfigurationSynchronizer extends ConfigurationSupport implements S LOGGER.error("CELLAR CONFIG: failed to update local configuration", ex); } } - LOGGER.warn("CELLAR CONFIG: configuration with PID {} is marked BLOCKED INBOUND for cluster group {}", clusterPID, groupName); + LOGGER.debug("CELLAR CONFIG: configuration with PID {} is marked BLOCKED INBOUND for cluster group {}", clusterPID, groupName); } } finally { Thread.currentThread().setContextClassLoader(originalClassLoader); @@ -112,7 +112,7 @@ public class ConfigurationSynchronizer extends ConfigurationSupport implements S // check if the producer is ON if (eventProducer.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR CONFIG: cluster event producer is OFF"); + LOGGER.debug("CELLAR CONFIG: cluster event producer is OFF"); return; } @@ -138,7 +138,7 @@ public class ConfigurationSynchronizer extends ConfigurationSupport implements S event.setSourceGroup(group); eventProducer.produce(event); } else - LOGGER.warn("CELLAR CONFIG: configuration with PID {} is marked BLOCKED OUTBOUND for cluster group {}", pid, groupName); + LOGGER.debug("CELLAR CONFIG: configuration with PID {} is marked BLOCKED OUTBOUND for cluster group {}", pid, groupName); } } catch (IOException ex) { LOGGER.error("CELLAR CONFIG: failed to update configuration (IO error)", ex); http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/config/src/main/java/org/apache/karaf/cellar/config/LocalConfigurationListener.java ---------------------------------------------------------------------- diff --git a/config/src/main/java/org/apache/karaf/cellar/config/LocalConfigurationListener.java b/config/src/main/java/org/apache/karaf/cellar/config/LocalConfigurationListener.java index 01a6cab..bd1dab6 100644 --- a/config/src/main/java/org/apache/karaf/cellar/config/LocalConfigurationListener.java +++ b/config/src/main/java/org/apache/karaf/cellar/config/LocalConfigurationListener.java @@ -49,7 +49,7 @@ public class LocalConfigurationListener extends ConfigurationSupport implements // check if the producer is ON if (eventProducer.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR CONFIG: cluster event producer is OFF"); + LOGGER.debug("CELLAR CONFIG: cluster event producer is OFF"); return; } @@ -103,7 +103,7 @@ public class LocalConfigurationListener extends ConfigurationSupport implements } catch (Exception e) { LOGGER.error("CELLAR CONFIG: failed to update configuration with PID {} to the cluster group {}", pid, group.getName(), e); } - } else LOGGER.warn("CELLAR CONFIG: configuration with PID {} is marked BLOCKED OUTBOUND for cluster group {}", pid, group.getName()); + } else LOGGER.debug("CELLAR CONFIG: configuration with PID {} is marked BLOCKED OUTBOUND for cluster group {}", pid, group.getName()); } } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/core/src/main/java/org/apache/karaf/cellar/core/command/Command.java ---------------------------------------------------------------------- diff --git a/core/src/main/java/org/apache/karaf/cellar/core/command/Command.java b/core/src/main/java/org/apache/karaf/cellar/core/command/Command.java index f3a77a5..2cc1938 100644 --- a/core/src/main/java/org/apache/karaf/cellar/core/command/Command.java +++ b/core/src/main/java/org/apache/karaf/cellar/core/command/Command.java @@ -29,7 +29,7 @@ import java.util.concurrent.TimeUnit; */ public class Command<R extends Result> extends Event { - protected static final Logger logger = LoggerFactory.getLogger(Command.class); + protected static final Logger LOGGER = LoggerFactory.getLogger(Command.class); protected long timeout = 10000; protected final BlockingQueue<Map<Node, R>> resultQueue = new LinkedBlockingQueue<Map<Node, R>>(); @@ -57,7 +57,7 @@ public class Command<R extends Result> extends Event { try { resultQueue.put(nodeResults); } catch (InterruptedException e) { - logger.error("Error adding result to result queue", e); + LOGGER.error("Error adding result to result queue", e); } } @@ -76,7 +76,7 @@ public class Command<R extends Result> extends Event { try { resultQueue.put(nodeResults); } catch (InterruptedException e) { - logger.error("Error adding result to result queue", e); + LOGGER.error("Error adding result to result queue", e); } } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/core/src/main/java/org/apache/karaf/cellar/core/control/ManageGroupCommandHandler.java ---------------------------------------------------------------------- diff --git a/core/src/main/java/org/apache/karaf/cellar/core/control/ManageGroupCommandHandler.java b/core/src/main/java/org/apache/karaf/cellar/core/control/ManageGroupCommandHandler.java index 0c6efbe..42801b9 100644 --- a/core/src/main/java/org/apache/karaf/cellar/core/control/ManageGroupCommandHandler.java +++ b/core/src/main/java/org/apache/karaf/cellar/core/control/ManageGroupCommandHandler.java @@ -36,7 +36,6 @@ public class ManageGroupCommandHandler extends CommandHandler<ManageGroupCommand ManageGroupAction action = command.getAction(); String targetGroupName = command.getGroupName(); - Node node = clusterManager.getNode(); if (ManageGroupAction.JOIN.equals(action)) { joinGroup(targetGroupName); http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/core/src/main/java/org/apache/karaf/cellar/core/control/ManageHandlersCommandHandler.java ---------------------------------------------------------------------- diff --git a/core/src/main/java/org/apache/karaf/cellar/core/control/ManageHandlersCommandHandler.java b/core/src/main/java/org/apache/karaf/cellar/core/control/ManageHandlersCommandHandler.java index 82d9702..bf4662e 100644 --- a/core/src/main/java/org/apache/karaf/cellar/core/control/ManageHandlersCommandHandler.java +++ b/core/src/main/java/org/apache/karaf/cellar/core/control/ManageHandlersCommandHandler.java @@ -14,7 +14,6 @@ package org.apache.karaf.cellar.core.control; import org.apache.karaf.cellar.core.Configurations; -import org.apache.karaf.cellar.core.Consumer; import org.apache.karaf.cellar.core.command.CommandHandler; import org.apache.karaf.cellar.core.event.EventHandler; import org.osgi.framework.BundleContext; @@ -38,8 +37,6 @@ public class ManageHandlersCommandHandler extends CommandHandler<ManageHandlersC private final Switch commandSwitch = new BasicSwitch(SWITCH_ID); - private Consumer consumer; - /** * Execute the cluster manage handlers command event and get the result. * @@ -109,7 +106,7 @@ public class ManageHandlersCommandHandler extends CommandHandler<ManageHandlersC } } } catch (Exception e) { - LOGGER.warn("Can't persist the handler " + handler + " status", e); + LOGGER.warn("Can't persist the handler {} status", handler, e); } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/core/src/main/java/org/apache/karaf/cellar/core/discovery/DiscoveryTask.java ---------------------------------------------------------------------- diff --git a/core/src/main/java/org/apache/karaf/cellar/core/discovery/DiscoveryTask.java b/core/src/main/java/org/apache/karaf/cellar/core/discovery/DiscoveryTask.java index c25ac3e..d327d5e 100644 --- a/core/src/main/java/org/apache/karaf/cellar/core/discovery/DiscoveryTask.java +++ b/core/src/main/java/org/apache/karaf/cellar/core/discovery/DiscoveryTask.java @@ -14,10 +14,8 @@ package org.apache.karaf.cellar.core.discovery; import java.io.IOException; -import java.util.Collections; import java.util.Dictionary; import java.util.Hashtable; -import java.util.Iterator; import java.util.LinkedHashSet; import java.util.List; import java.util.Set; http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/core/src/main/java/org/apache/karaf/cellar/core/event/EventDispatchTask.java ---------------------------------------------------------------------- diff --git a/core/src/main/java/org/apache/karaf/cellar/core/event/EventDispatchTask.java b/core/src/main/java/org/apache/karaf/cellar/core/event/EventDispatchTask.java index 79344bc..e94996c 100644 --- a/core/src/main/java/org/apache/karaf/cellar/core/event/EventDispatchTask.java +++ b/core/src/main/java/org/apache/karaf/cellar/core/event/EventDispatchTask.java @@ -49,26 +49,26 @@ public class EventDispatchTask<E extends Event> implements Runnable { @Override public void run() { try { - boolean dispatched = false; + boolean dispatched = false; - for (long delay = 0; delay < timeout && !dispatched; delay += interval) { - EventHandler handler = handlerRegistry.getHandler(event); - if (handler != null) { - handler.handle(event); - dispatched = true; - } else { - try { - Thread.sleep(interval); - } catch (InterruptedException e) { - LOGGER.warn("Interrupted while waiting for event handler", e); + for (long delay = 0; delay < timeout && !dispatched; delay += interval) { + EventHandler handler = handlerRegistry.getHandler(event); + if (handler != null) { + handler.handle(event); + dispatched = true; + } else { + try { + Thread.sleep(interval); + } catch (InterruptedException e) { + LOGGER.warn("Interrupted while waiting for event handler", e); + } } } - } - if (!dispatched) { - LOGGER.warn("Failed to retrieve handler for event {}", event.getClass()); - } - }catch(Exception ex) { - LOGGER.error("Error while dispatching task",ex); + if (!dispatched) { + LOGGER.warn("Failed to retrieve handler for event {}", event.getClass()); + } + } catch (Exception ex) { + LOGGER.error("Error while dispatching task", ex); } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/dosgi/src/main/java/org/apache/karaf/cellar/dosgi/EndpointDescription.java ---------------------------------------------------------------------- diff --git a/dosgi/src/main/java/org/apache/karaf/cellar/dosgi/EndpointDescription.java b/dosgi/src/main/java/org/apache/karaf/cellar/dosgi/EndpointDescription.java index 83f6128..193b182 100644 --- a/dosgi/src/main/java/org/apache/karaf/cellar/dosgi/EndpointDescription.java +++ b/dosgi/src/main/java/org/apache/karaf/cellar/dosgi/EndpointDescription.java @@ -19,7 +19,6 @@ import org.osgi.framework.Filter; import org.osgi.framework.FrameworkUtil; import org.osgi.framework.InvalidSyntaxException; -import java.io.Serializable; import java.util.Dictionary; import java.util.HashMap; import java.util.LinkedHashSet; @@ -32,7 +31,6 @@ import java.util.Set; */ public class EndpointDescription implements MultiNode { - //Id is {package}-{version}. private final String id; private final Set<Node> nodes = new LinkedHashSet<Node>(); private final Map<String, Object> properties = new HashMap<String, Object>(); http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/dosgi/src/main/java/org/apache/karaf/cellar/dosgi/RemoteServiceCallHandler.java ---------------------------------------------------------------------- diff --git a/dosgi/src/main/java/org/apache/karaf/cellar/dosgi/RemoteServiceCallHandler.java b/dosgi/src/main/java/org/apache/karaf/cellar/dosgi/RemoteServiceCallHandler.java index 99b9b99..d675b67 100644 --- a/dosgi/src/main/java/org/apache/karaf/cellar/dosgi/RemoteServiceCallHandler.java +++ b/dosgi/src/main/java/org/apache/karaf/cellar/dosgi/RemoteServiceCallHandler.java @@ -36,10 +36,10 @@ import java.lang.reflect.Method; */ public class RemoteServiceCallHandler extends CellarSupport implements EventHandler<RemoteServiceCall> { - public static final String SWITCH_ID = "org.apache.karaf.cellar.dosgi.switch"; - private static final transient Logger LOGGER = LoggerFactory.getLogger(RemoteServiceCallHandler.class); + public static final String SWITCH_ID = "org.apache.karaf.cellar.dosgi.switch"; + private final Switch dosgiSwitch = new BasicSwitch(SWITCH_ID); private BundleContext bundleContext; @@ -51,7 +51,7 @@ public class RemoteServiceCallHandler extends CellarSupport implements EventHand // check if the handler switch is ON if (this.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR DOSGI: {} switch is OFF, cluster event is not handled", SWITCH_ID); + LOGGER.debug("CELLAR DOSGI: {} switch is OFF, cluster event is not handled", SWITCH_ID); return; } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/event/src/main/java/org/apache/karaf/cellar/event/ClusterEventHandler.java ---------------------------------------------------------------------- diff --git a/event/src/main/java/org/apache/karaf/cellar/event/ClusterEventHandler.java b/event/src/main/java/org/apache/karaf/cellar/event/ClusterEventHandler.java index 4352962..9808bf8 100644 --- a/event/src/main/java/org/apache/karaf/cellar/event/ClusterEventHandler.java +++ b/event/src/main/java/org/apache/karaf/cellar/event/ClusterEventHandler.java @@ -41,7 +41,7 @@ public class ClusterEventHandler extends EventSupport implements EventHandler<Cl // check if the handler is ON if (this.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR EVENT: {} is OFF, cluster event not handled", SWITCH_ID); + LOGGER.debug("CELLAR EVENT: {} is OFF, cluster event not handled", SWITCH_ID); return; } @@ -58,7 +58,7 @@ public class ClusterEventHandler extends EventSupport implements EventHandler<Cl properties.put(Constants.EVENT_SOURCE_GROUP_KEY, event.getSourceGroup()); properties.put(Constants.EVENT_SOURCE_NODE_KEY, event.getSourceNode()); postEvent(event.getTopicName(), properties); - } else LOGGER.warn("CELLAR EVENT: event {} is marked as BLOCKED INBOUND", event.getTopicName()); + } else LOGGER.debug("CELLAR EVENT: event {} is marked as BLOCKED INBOUND", event.getTopicName()); } catch (Exception e) { LOGGER.error("CELLAR EVENT: failed to handle event", e); } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/event/src/main/java/org/apache/karaf/cellar/event/EventSupport.java ---------------------------------------------------------------------- diff --git a/event/src/main/java/org/apache/karaf/cellar/event/EventSupport.java b/event/src/main/java/org/apache/karaf/cellar/event/EventSupport.java index 819186d..eba8763 100644 --- a/event/src/main/java/org/apache/karaf/cellar/event/EventSupport.java +++ b/event/src/main/java/org/apache/karaf/cellar/event/EventSupport.java @@ -79,7 +79,7 @@ public class EventSupport extends CellarSupport { */ public void postEvent(String topicName, Map<String, Serializable> properties) { if (topicName == null) { - LOGGER.error("CELLAR EVENT: failed to post event"); + LOGGER.warn("CELLAR EVENT: failed to post event"); return; } @@ -95,7 +95,7 @@ public class EventSupport extends CellarSupport { */ public void sendEvent(String topicName, Map<String, Serializable> properties) { if (topicName == null) { - LOGGER.error("CELLAR EVENT: failed to send event"); + LOGGER.warn("CELLAR EVENT: failed to send event"); return; } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/event/src/main/java/org/apache/karaf/cellar/event/LocalEventListener.java ---------------------------------------------------------------------- diff --git a/event/src/main/java/org/apache/karaf/cellar/event/LocalEventListener.java b/event/src/main/java/org/apache/karaf/cellar/event/LocalEventListener.java index 432e960..feb1ae4 100644 --- a/event/src/main/java/org/apache/karaf/cellar/event/LocalEventListener.java +++ b/event/src/main/java/org/apache/karaf/cellar/event/LocalEventListener.java @@ -23,7 +23,6 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; import java.io.Serializable; -import java.util.HashMap; import java.util.Map; import java.util.Set; @@ -42,7 +41,7 @@ public class LocalEventListener extends EventSupport implements EventHandler { // check if the producer is ON if (eventProducer.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR EVENT: cluster event producer is OFF"); + LOGGER.debug("CELLAR EVENT: cluster event producer is OFF"); return; } @@ -73,7 +72,7 @@ public class LocalEventListener extends EventSupport implements EventHandler { ClusterEvent clusterEvent = new ClusterEvent(topicName, properties); clusterEvent.setSourceGroup(group); eventProducer.produce(clusterEvent); - } else LOGGER.warn("CELLAR EVENT: event {} is marked as BLOCKED OUTBOUND", topicName); + } else LOGGER.debug("CELLAR EVENT: event {} is marked as BLOCKED OUTBOUND", topicName); } } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/features/src/main/java/org/apache/karaf/cellar/features/FeaturesEventHandler.java ---------------------------------------------------------------------- diff --git a/features/src/main/java/org/apache/karaf/cellar/features/FeaturesEventHandler.java b/features/src/main/java/org/apache/karaf/cellar/features/FeaturesEventHandler.java index 59dab41..684ed26 100644 --- a/features/src/main/java/org/apache/karaf/cellar/features/FeaturesEventHandler.java +++ b/features/src/main/java/org/apache/karaf/cellar/features/FeaturesEventHandler.java @@ -58,7 +58,7 @@ public class FeaturesEventHandler extends FeaturesSupport implements EventHandle // check if the handler switch is ON if (this.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR FEATURES: {} switch is OFF, cluster event is not handled", SWITCH_ID); + LOGGER.debug("CELLAR FEATURES: {} switch is OFF, cluster event is not handled", SWITCH_ID); return; } @@ -103,7 +103,7 @@ public class FeaturesEventHandler extends FeaturesSupport implements EventHandle } catch (Exception e) { LOGGER.error("CELLAR FEATURES: failed to handle event", e); } - } else LOGGER.warn("CELLAR FEATURES: feature {} is marked BLOCKED INBOUND for cluster group {}", name, event.getSourceGroup().getName()); + } else LOGGER.debug("CELLAR FEATURES: feature {} is marked BLOCKED INBOUND for cluster group {}", name, event.getSourceGroup().getName()); } @Override http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/features/src/main/java/org/apache/karaf/cellar/features/FeaturesSupport.java ---------------------------------------------------------------------- diff --git a/features/src/main/java/org/apache/karaf/cellar/features/FeaturesSupport.java b/features/src/main/java/org/apache/karaf/cellar/features/FeaturesSupport.java index 7e78585..02733e8 100644 --- a/features/src/main/java/org/apache/karaf/cellar/features/FeaturesSupport.java +++ b/features/src/main/java/org/apache/karaf/cellar/features/FeaturesSupport.java @@ -98,7 +98,7 @@ public class FeaturesSupport extends CellarSupport { Boolean installed = featuresService.isInstalled(feature); clusterFeatures.put(info, installed); } - } else LOGGER.warn("CELLAR FEATURES: feature {} is marked BLOCKED OUTBOUND for cluster group {}", feature.getName(), groupName); + } else LOGGER.debug("CELLAR FEATURES: feature {} is marked BLOCKED OUTBOUND for cluster group {}", feature.getName(), groupName); } else LOGGER.warn("CELLAR FEATURES: feature is null"); } @@ -120,7 +120,7 @@ public class FeaturesSupport extends CellarSupport { FeatureInfo info = new FeatureInfo(feature.getName(), feature.getVersion()); clusterFeatures.put(info, force); } - } else LOGGER.warn("CELLAR FEATURES: feature {} is marked BLOCKED OUTBOUND for cluster group {}", feature.getName(), groupName); + } else LOGGER.debug("CELLAR FEATURES: feature {} is marked BLOCKED OUTBOUND for cluster group {}", feature.getName(), groupName); } else LOGGER.warn("CELLAR FEATURES: feature is null"); } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/features/src/main/java/org/apache/karaf/cellar/features/FeaturesSynchronizer.java ---------------------------------------------------------------------- diff --git a/features/src/main/java/org/apache/karaf/cellar/features/FeaturesSynchronizer.java b/features/src/main/java/org/apache/karaf/cellar/features/FeaturesSynchronizer.java index 3be2ead..a459be1 100644 --- a/features/src/main/java/org/apache/karaf/cellar/features/FeaturesSynchronizer.java +++ b/features/src/main/java/org/apache/karaf/cellar/features/FeaturesSynchronizer.java @@ -47,7 +47,7 @@ public class FeaturesSynchronizer extends FeaturesSupport implements Synchronize if (isSyncEnabled(group)) { pull(group); push(group); - } else LOGGER.warn("CELLAR FEATURES: sync is disabled for cluster group {}", group.getName()); + } else LOGGER.debug("CELLAR FEATURES: sync is disabled for cluster group {}", group.getName()); } } } @@ -141,7 +141,7 @@ public class FeaturesSynchronizer extends FeaturesSupport implements Synchronize public void push(Group group) { if (group != null) { String groupName = group.getName(); - LOGGER.info("CELLAR FEATURES: pushing features repositories and features in cluster group {}.",groupName); + LOGGER.debug("CELLAR FEATURES: pushing features repositories and features in cluster group {}.",groupName); clusterManager.getList(Constants.FEATURES + Configurations.SEPARATOR + groupName); ClassLoader originalClassLoader = Thread.currentThread().getContextClassLoader(); http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/features/src/main/java/org/apache/karaf/cellar/features/LocalFeaturesListener.java ---------------------------------------------------------------------- diff --git a/features/src/main/java/org/apache/karaf/cellar/features/LocalFeaturesListener.java b/features/src/main/java/org/apache/karaf/cellar/features/LocalFeaturesListener.java index a6c2fd1..b589d61 100644 --- a/features/src/main/java/org/apache/karaf/cellar/features/LocalFeaturesListener.java +++ b/features/src/main/java/org/apache/karaf/cellar/features/LocalFeaturesListener.java @@ -56,7 +56,7 @@ public class LocalFeaturesListener extends FeaturesSupport implements org.apache // check if the producer is ON if (eventProducer.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR FEATURES: cluster event producer is OFF"); + LOGGER.debug("CELLAR FEATURES: cluster event producer is OFF"); return; } @@ -84,7 +84,7 @@ public class LocalFeaturesListener extends FeaturesSupport implements org.apache ClusterFeaturesEvent featureEvent = new ClusterFeaturesEvent(name, version, type); featureEvent.setSourceGroup(group); eventProducer.produce(featureEvent); - } else LOGGER.warn("CELLAR FEATURES: feature {} is marked BLOCKED OUTBOUND for cluster group {}", name, group.getName()); + } else LOGGER.debug("CELLAR FEATURES: feature {} is marked BLOCKED OUTBOUND for cluster group {}", name, group.getName()); } } } @@ -100,7 +100,7 @@ public class LocalFeaturesListener extends FeaturesSupport implements org.apache // check if the producer is ON if (eventProducer.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR FEATURES: cluster event producer is OFF"); + LOGGER.debug("CELLAR FEATURES: cluster event producer is OFF"); return; } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/features/src/main/java/org/apache/karaf/cellar/features/RepositoryEventHandler.java ---------------------------------------------------------------------- diff --git a/features/src/main/java/org/apache/karaf/cellar/features/RepositoryEventHandler.java b/features/src/main/java/org/apache/karaf/cellar/features/RepositoryEventHandler.java index faa4343..a63670b 100644 --- a/features/src/main/java/org/apache/karaf/cellar/features/RepositoryEventHandler.java +++ b/features/src/main/java/org/apache/karaf/cellar/features/RepositoryEventHandler.java @@ -54,7 +54,7 @@ public class RepositoryEventHandler extends FeaturesSupport implements EventHand // check if the handler is ON if (eventSwitch.getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR FEATURES: {} switch is OFF, cluster event is not handled", SWITCH_ID); + LOGGER.debug("CELLAR FEATURES: {} switch is OFF, cluster event is not handled", SWITCH_ID); return; } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/HazelcastGroupManager.java ---------------------------------------------------------------------- diff --git a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/HazelcastGroupManager.java b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/HazelcastGroupManager.java index ebcfd99..e937ff6 100644 --- a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/HazelcastGroupManager.java +++ b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/HazelcastGroupManager.java @@ -339,7 +339,7 @@ public class HazelcastGroupManager implements GroupManager, EntryListener, Confi String groupName = group.getName(); createGroup(groupName); - LOGGER.info("CELLAR HAZELCAST: registering cluster group {}", groupName); + LOGGER.debug("CELLAR HAZELCAST: registering cluster group {}", groupName); Properties serviceProperties = new Properties(); serviceProperties.put("type", "group"); serviceProperties.put("name", groupName); http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/QueueConsumer.java ---------------------------------------------------------------------- diff --git a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/QueueConsumer.java b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/QueueConsumer.java index 920f802..36fd67e 100644 --- a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/QueueConsumer.java +++ b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/QueueConsumer.java @@ -118,7 +118,7 @@ public class QueueConsumer<E extends Event> implements EventConsumer<E>, ItemLis dispatcher.dispatch(event); } else { if (eventSwitch.getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR HAZELCAST: {} switch if OFF, event is not consumed", SWITCH_ID); + LOGGER.debug("CELLAR HAZELCAST: {} switch if OFF, event is not consumed", SWITCH_ID); } } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/QueueProducer.java ---------------------------------------------------------------------- diff --git a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/QueueProducer.java b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/QueueProducer.java index c99b9dd..ad332c8 100644 --- a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/QueueProducer.java +++ b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/QueueProducer.java @@ -84,7 +84,7 @@ public class QueueProducer<E extends Event> implements EventProducer<E> { } } else { if (eventSwitch.getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR HAZELCAST: {} switch is OFF, don't produce the event", SWITCH_ID); + LOGGER.debug("CELLAR HAZELCAST: {} switch is OFF, don't produce the event", SWITCH_ID); } } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/TopicConsumer.java ---------------------------------------------------------------------- diff --git a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/TopicConsumer.java b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/TopicConsumer.java index 028c586..40d09b6 100644 --- a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/TopicConsumer.java +++ b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/TopicConsumer.java @@ -72,7 +72,7 @@ public class TopicConsumer<E extends Event> implements EventConsumer<E>, Message dispatcher.dispatch(event); } else { if (eventSwitch.getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR HAZELCAST: {} switch if OFF, event is not consumed", SWITCH_ID); + LOGGER.debug("CELLAR HAZELCAST: {} switch if OFF, event is not consumed", SWITCH_ID); } } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/TopicProducer.java ---------------------------------------------------------------------- diff --git a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/TopicProducer.java b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/TopicProducer.java index b1f6039..bd8d551 100644 --- a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/TopicProducer.java +++ b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/TopicProducer.java @@ -66,7 +66,7 @@ public class TopicProducer<E extends Event> implements EventProducer<E> { topic.publish(event); } else { if (eventSwitch.getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR HAZELCAST: {} switch is OFF, don't produce the event", SWITCH_ID); + LOGGER.debug("CELLAR HAZELCAST: {} switch is OFF, don't produce the event", SWITCH_ID); } } } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/factory/HazelcastConfigurationManager.java ---------------------------------------------------------------------- diff --git a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/factory/HazelcastConfigurationManager.java b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/factory/HazelcastConfigurationManager.java index 6c34d0f..43722da 100644 --- a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/factory/HazelcastConfigurationManager.java +++ b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/factory/HazelcastConfigurationManager.java @@ -59,7 +59,7 @@ public class HazelcastConfigurationManager { if (properties.containsKey(Discovery.DISCOVERED_MEMBERS_PROPERTY_NAME)) { Set<String> newDiscoveredMemberSet = CellarUtils.createSetFromString((String) properties.get(Discovery.DISCOVERED_MEMBERS_PROPERTY_NAME)); if (!CellarUtils.collectionEquals(discoveredMemberSet, newDiscoveredMemberSet)) { - LOGGER.info("CELLAR HAZELCAST: Hazelcast discoveredMemberSet has been changed from {} to {}", discoveredMemberSet, newDiscoveredMemberSet); + LOGGER.debug("CELLAR HAZELCAST: Hazelcast discoveredMemberSet has been changed from {} to {}", discoveredMemberSet, newDiscoveredMemberSet); discoveredMemberSet = newDiscoveredMemberSet; updated = Boolean.TRUE; } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/merge/CellarMergePolicy.java ---------------------------------------------------------------------- diff --git a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/merge/CellarMergePolicy.java b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/merge/CellarMergePolicy.java index 1822b33..2c0af02 100644 --- a/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/merge/CellarMergePolicy.java +++ b/hazelcast/src/main/java/org/apache/karaf/cellar/hazelcast/merge/CellarMergePolicy.java @@ -43,7 +43,7 @@ public class CellarMergePolicy implements MergePolicy { */ @Override public Object merge(String mapName, MapEntry mergingEntry, MapEntry existingEntry) { - LOGGER.info("CELLAR HAZELCAST: merge policy triggered merging entry {}, existing entry {}",mergingEntry,existingEntry); + LOGGER.debug("CELLAR HAZELCAST: merge policy triggered merging entry {}, existing entry {}",mergingEntry,existingEntry); Object mergingDataValue = mergingEntry != null ? mergingEntry.getValue() : null; Object existingDataValue = existingEntry != null ? existingEntry.getValue() : null; http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/obr/src/main/java/org/apache/karaf/cellar/obr/ObrBundleEventHandler.java ---------------------------------------------------------------------- diff --git a/obr/src/main/java/org/apache/karaf/cellar/obr/ObrBundleEventHandler.java b/obr/src/main/java/org/apache/karaf/cellar/obr/ObrBundleEventHandler.java index 34e69f3..3bfbcb7 100644 --- a/obr/src/main/java/org/apache/karaf/cellar/obr/ObrBundleEventHandler.java +++ b/obr/src/main/java/org/apache/karaf/cellar/obr/ObrBundleEventHandler.java @@ -114,7 +114,7 @@ public class ObrBundleEventHandler extends ObrSupport implements EventHandler<Cl // check if the handler is ON if (this.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR OBR: {} switch is OFF", SWITCH_ID); + LOGGER.debug("CELLAR OBR: {} switch is OFF", SWITCH_ID); return; } @@ -152,7 +152,7 @@ public class ObrBundleEventHandler extends ObrSupport implements EventHandler<Cl } } else LOGGER.warn("CELLAR OBR: could not resolve targets"); } - } else LOGGER.warn("CELLAR OBR: bundle {} is marked BLOCKED INBOUND for cluster group {}", bundleId, event.getSourceGroup().getName()); + } else LOGGER.debug("CELLAR OBR: bundle {} is marked BLOCKED INBOUND for cluster group {}", bundleId, event.getSourceGroup().getName()); } catch (Exception e) { LOGGER.error("CELLAR OBR: failed to handle bundle event {}", bundleId, e); } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/obr/src/main/java/org/apache/karaf/cellar/obr/ObrUrlEventHandler.java ---------------------------------------------------------------------- diff --git a/obr/src/main/java/org/apache/karaf/cellar/obr/ObrUrlEventHandler.java b/obr/src/main/java/org/apache/karaf/cellar/obr/ObrUrlEventHandler.java index 1cb9947..c66c114 100644 --- a/obr/src/main/java/org/apache/karaf/cellar/obr/ObrUrlEventHandler.java +++ b/obr/src/main/java/org/apache/karaf/cellar/obr/ObrUrlEventHandler.java @@ -54,7 +54,7 @@ public class ObrUrlEventHandler extends ObrSupport implements EventHandler<Clust // check if the handler is ON if (this.getSwitch().getStatus().equals(SwitchStatus.OFF)) { - LOGGER.warn("CELLAR OBR: {} switch is OFF", SWITCH_ID); + LOGGER.debug("CELLAR OBR: {} switch is OFF", SWITCH_ID); return; } @@ -80,7 +80,7 @@ public class ObrUrlEventHandler extends ObrSupport implements EventHandler<Clust LOGGER.warn("CELLAR OBR: the repository URL hasn't been removed from the OBR service"); } } - } else LOGGER.warn("CELLAR OBR: repository URL {} is marked BLOCKED INBOUND for cluster group {}", url, groupName); + } else LOGGER.debug("CELLAR OBR: repository URL {} is marked BLOCKED INBOUND for cluster group {}", url, groupName); } catch (Exception e) { LOGGER.error("CELLAR OBR: failed to register URL {}", url, e); } http://git-wip-us.apache.org/repos/asf/karaf-cellar/blob/27bd59c4/obr/src/main/java/org/apache/karaf/cellar/obr/ObrUrlSynchronizer.java ---------------------------------------------------------------------- diff --git a/obr/src/main/java/org/apache/karaf/cellar/obr/ObrUrlSynchronizer.java b/obr/src/main/java/org/apache/karaf/cellar/obr/ObrUrlSynchronizer.java index bbc2467..7d9cf64 100644 --- a/obr/src/main/java/org/apache/karaf/cellar/obr/ObrUrlSynchronizer.java +++ b/obr/src/main/java/org/apache/karaf/cellar/obr/ObrUrlSynchronizer.java @@ -43,7 +43,7 @@ public class ObrUrlSynchronizer extends ObrSupport implements Synchronizer { if (isSyncEnabled(group)) { pull(group); push(group); - } else LOGGER.warn("CELLAR OBR: sync is disabled for group {}", group.getName()); + } else LOGGER.debug("CELLAR OBR: sync is disabled for group {}", group.getName()); } } } @@ -109,7 +109,7 @@ public class ObrUrlSynchronizer extends ObrSupport implements Synchronizer { // TODO fire event to the other nodes ? } } else { - LOGGER.warn("CELLAR OBR: URL " + repository.getURI().toString() + " is blocked outbound"); + LOGGER.debug("CELLAR OBR: URL {} is BLOCKED OUTBOUND for cluster group {}", repository.getURI().toString(), groupName); } } } finally {
