You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by GitBox <gi...@apache.org> on 2021/11/18 11:49:01 UTC

[GitHub] [sling-org-apache-sling-feature-cpconverter] anchela commented on a change in pull request #121: Wrap the exceptions of onFile an provide a path to the output

anchela commented on a change in pull request #121:
URL: https://github.com/apache/sling-org-apache-sling-feature-cpconverter/pull/121#discussion_r752164726



##########
File path: src/main/java/org/apache/sling/feature/cpconverter/ContentPackage2FeatureModelConverter.java
##########
@@ -496,7 +496,13 @@ private void process(@NotNull String entryPath, @NotNull Archive archive, @Nulla
 
     @Override
     protected void onFile(@NotNull String entryPath, @NotNull Archive archive, @NotNull Entry entry) throws IOException, ConverterException {
-        process(entryPath, archive, entry);
+        try {
+            process(entryPath, archive, entry);
+        }catch (ConverterException ex){
+            throw new ConverterException("ConverterException occured on path " + entryPath + " with message: " + ex.getMessage(), ex);
+        }catch(IOException ex){

Review comment:
       same here: please stick to the formatting the project which is whitespace between } and catch and between ) and {

##########
File path: src/main/java/org/apache/sling/feature/cpconverter/ContentPackage2FeatureModelConverter.java
##########
@@ -496,7 +496,13 @@ private void process(@NotNull String entryPath, @NotNull Archive archive, @Nulla
 
     @Override
     protected void onFile(@NotNull String entryPath, @NotNull Archive archive, @NotNull Entry entry) throws IOException, ConverterException {
-        process(entryPath, archive, entry);
+        try {
+            process(entryPath, archive, entry);
+        }catch (ConverterException ex){

Review comment:
       formatting: please add a whitespace between } and catch and between ) and { 




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@sling.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org