diff --git a/src/main/java/com/redhat/devtools/intellij/lsp4mp4ij/psi/core/project/AbstractConfigSource.java b/src/main/java/com/redhat/devtools/intellij/lsp4mp4ij/psi/core/project/AbstractConfigSource.java index 47955a7ce..ec02aafbe 100644 --- a/src/main/java/com/redhat/devtools/intellij/lsp4mp4ij/psi/core/project/AbstractConfigSource.java +++ b/src/main/java/com/redhat/devtools/intellij/lsp4mp4ij/psi/core/project/AbstractConfigSource.java @@ -176,13 +176,13 @@ protected final T getConfig() { try (InputStream input = configFile.getInputStream()) { config = loadConfig(input); lastModified = configFile.getModificationStamp(); - } catch (IOException e) { + } catch (Exception e) { reset(); - LOGGER.error("Error while loading properties from '" + configFile + "'.", e); + LOGGER.warn("Error while loading properties from '" + configFile + "'.", e); } } } catch (RuntimeException e1) { - LOGGER.error("Error while getting last modified time for '" + configFile + "'.", e1); + LOGGER.warn("Error while getting last modified time for '" + configFile + "'.", e1); } return config; } @@ -194,9 +194,9 @@ public void reload(PsiFile file) { try (InputStream input = IOUtils.toInputStream(content, Charset.defaultCharset())) { config = loadConfig(input); lastModified = System.currentTimeMillis(); - } catch (IOException e) { + } catch (Exception e) { reset(); - LOGGER.error("Error while loading properties from '" + sourceConfigFile + "'.", e); + LOGGER.warn("Error while loading properties from '" + sourceConfigFile + "'.", e); } } @@ -207,7 +207,7 @@ public Integer getPropertyAsInt(String key) { try { return Integer.parseInt(property.trim()); } catch (NumberFormatException e) { - LOGGER.error("Error while converting '" + property.trim() + "' as Integer for key '" + key + "'", e); + LOGGER.warn("Error while converting '" + property.trim() + "' as Integer for key '" + key + "'", e); return null; } }