You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Carsten Ziegeler (Jira)" <ji...@apache.org> on 2021/08/26 07:11:00 UTC
[jira] [Resolved] (SLING-10705) Improve exception handling and
error reporting
[ https://issues.apache.org/jira/browse/SLING-10705?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Carsten Ziegeler resolved SLING-10705.
--------------------------------------
Resolution: Fixed
Went over some exceptions and changed them to a ConverterException
With this we at least report some issues to back to the user. We can improve over time and more to it.
https://github.com/apache/sling-org-apache-sling-feature-cpconverter/commit/a3fa0c617ec09b27819968ad4d49a16e5311d6bc
> Improve exception handling and error reporting
> ----------------------------------------------
>
> Key: SLING-10705
> URL: https://issues.apache.org/jira/browse/SLING-10705
> Project: Sling
> Issue Type: Improvement
> Components: Content-Package to Feature Model Converter
> Reporter: Carsten Ziegeler
> Assignee: Carsten Ziegeler
> Priority: Major
> Fix For: Content-Package to Feature Model Converter 1.1.10
>
>
> The code is currently not distinguishing between user errors and tooling errors. For example an IllegalStateException might be thrown if an OSGi configuration is in the wrong place inside the content package as well as if there is an internal error inside the tool.
> While the first category of errors can be fixed by users fixing/adjusting their code/content packlages - the second category hints at bugs in the code.
> However both are reported exactly the same way.
> I suggest we report the first one as errors via logging while the second one throws an exception to the "outside".
> We can probably achieve this without much effort by using a special exception type for the first category.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)