Either log or rethrow this exception
[aai/champ.git] / src / main / java / org / onap / aai / champ / event / AbstractLoggingChampGraph.java
index a0fb837..312a6e4 100644 (file)
@@ -111,9 +111,9 @@ public abstract class AbstractLoggingChampGraph implements ChampGraph {
   /** Configuration property for setting the maximum amount of time to wait for a batch of
    *  outgoing messages to fill up before sending the batch. */
   public static final String  PARAM_EVENT_STREAM_BATCH_TIMEOUT = "champ.event.stream.batch-timeout";
-  public final static Integer DEFAULT_EVENT_STREAM_BATCH_TIMEOUT_MS = 500; 
+  public static final Integer DEFAULT_EVENT_STREAM_BATCH_TIMEOUT_MS = 500; 
   
-  public final static String  PARAM_EVENT_STREAM_PUBLISHER_POOL_SIZE = "champ.event.stream.publisher-pool-size";
+  public static final String  PARAM_EVENT_STREAM_PUBLISHER_POOL_SIZE = "champ.event.stream.publisher-pool-size";
   public static final Integer DEFAULT_EVENT_STREAM_PUBLISHER_POOL_SIZE = 100;
   
   /** The event stream topic that we will publish Champ events to. */
@@ -270,7 +270,7 @@ public abstract class AbstractLoggingChampGraph implements ChampGraph {
       objectToDelete = retrieveObject(key);
       
     } catch (ChampUnmarshallingException e) {
-      logger.error("Unable to generate delete object log: " + e.getMessage());
+      logger.error("Unable to generate delete object log: " + e.getMessage(),e);
     }
     
     executeDeleteObject(key);
@@ -439,10 +439,10 @@ public abstract class AbstractLoggingChampGraph implements ChampGraph {
       publisherPool.execute(new EventPublisher(anEvent));
     
     } catch (RejectedExecutionException re) {
-      logger.error("Event could not be published to the event bus due to: " + re.getMessage());
+      logger.error("Event could not be published to the event bus due to: " + re.getMessage(),re);
       
     } catch (NullPointerException npe) {
-      logger.error("Can not publish null event to event bus.");
+      logger.error("Can not publish null event to event bus." + npe.getMessage(),npe);
     }
   }