Uploaded image for project: 'Runtime'
  1. Runtime
  2. RUNTIME-254

Remove multiple logging of exceptions in AbstractThreadSafeComponentExtensionPoint

      When there is something wrong with the initialization or configuration of extensions of a MultipleExtensionPoint we get multiple exceptions logged.
      Each exception shows the same kind of message, just with a different stack trace.

      So i proposed the following patch, for improving logs readability:

      Index: main/kernel/src/org/ametys/runtime/plugin/component/AbstractThreadSafeComponentExtensionPoint.java
      ===================================================================
      --- main/kernel/src/org/ametys/runtime/plugin/component/AbstractThreadSafeComponentExtensionPoint.java	(revision 504)
      +++ main/kernel/src/org/ametys/runtime/plugin/component/AbstractThreadSafeComponentExtensionPoint.java	(working copy)
      @@ -122,9 +122,7 @@
               
               if (className == null)
               {
      -            String errorMessage = "In plugin '" + pluginName + "' id '" + pluginId + "', extension '" + id + "' does not defines any class";
      -            getLogger().error(errorMessage);
      -            throw new ConfigurationException(errorMessage, configuration);
      +            throw new ConfigurationException("In plugin '" + pluginName + "' id '" + pluginId + "', extension '" + id + "' does not defines any class", configuration);
               }
               
               Class<T> extensionClass;
      @@ -135,9 +133,7 @@
               }
               catch (ClassNotFoundException ex)
               {
      -            String errorMessage = "Unable to instanciate class '" + className + "' for plugin '" + pluginName + "' / '" + pluginId + "'";
      -            getLogger().error(errorMessage);
      -            throw new ConfigurationException(errorMessage, configuration, ex);
      +            throw new ConfigurationException("Unable to instanciate class '" + className + "' for plugin '" + pluginName + "' / '" + pluginId + "'", configuration, ex);
               }
               
               try
      

          [RUNTIME-254] Remove multiple logging of exceptions in AbstractThreadSafeComponentExtensionPoint

          Cédric Damioli made changes -
          Workflow Original: jira [ 11206 ] New: Ametys [ 12896 ]
          Julien Couret (Inactive) made changes -
          Project Import New: Thu May 28 17:04:11 UTC 2009 [ 1243530251015 ]
          Sébastien Launay (Inactive) made changes -
          Status Original: Resolved [ 5 ] New: Closed [ 6 ]
          Sébastien Launay (Inactive) made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]

          Fixed in revision 519.

          Sébastien Launay (Inactive) added a comment - Fixed in revision 519.
          Sébastien Launay (Inactive) created issue -

            yabon Sébastien Launay (Inactive)
            yabon Sébastien Launay (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: