Merge "Optimize the areas where its creating extra memory"
[aai/aai-common.git] / aai-schema-ingest / src / main / java / org / onap / aai / nodes / NodeIngestor.java
index 82991f0..2428a6d 100644 (file)
@@ -71,16 +71,14 @@ public class NodeIngestor {
 
     private CaseFormatStore caseFormatStore;
     //TODO : See if you can get rid of InputStream resets
-     /**
+
+    /**
      * Instantiates the NodeIngestor bean.
-     *
-     * @param  - ConfigTranslator autowired in by Spring framework which
-     * contains the configuration information needed to ingest the desired files.
+     * @param translatorSet
      */
 
      @Autowired
     public NodeIngestor(Set<Translator> translatorSet) {
-        LOGGER.debug("Local Schema files will be fetched");
         this.translators = translatorSet;
         this.caseFormatStore = new CaseFormatStore();
     }
@@ -94,8 +92,8 @@ public class NodeIngestor {
                 translateAll(translator);
 
             } catch (Exception e) {
-                LOGGER.info("Error while Processing the translator" + e.getMessage());
-                continue;
+                LOGGER.error("Error while Processing the translator" + e.getMessage());
+                throw new ExceptionInInitializerError("NodeIngestor could not ingest schema");
             }
         }
         if (versionContextMap.isEmpty() || schemaPerVersion.isEmpty() || typesPerVersion.isEmpty()) {