This is an automated email from the ASF dual-hosted git repository.

npeltier pushed a commit to branch master
in repository 
https://gitbox.apache.org/repos/asf/sling-org-apache-sling-pipes.git


The following commit(s) were added to refs/heads/master by this push:
     new 087d221  SLING-11165 rather use SecurityException
087d221 is described below

commit 087d221fa7b4b9ef9c5837cbea864c1ecbab4183
Author: Nicolas Peltier <[email protected]>
AuthorDate: Mon Mar 28 11:14:32 2022 +0200

    SLING-11165 rather use SecurityException
    
    Rejected execution seems to be bound to concurrent's Executor which might 
be misleading.
---
 src/main/java/org/apache/sling/pipes/PipeBindings.java | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/main/java/org/apache/sling/pipes/PipeBindings.java 
b/src/main/java/org/apache/sling/pipes/PipeBindings.java
index 02f76ed..1bb9343 100644
--- a/src/main/java/org/apache/sling/pipes/PipeBindings.java
+++ b/src/main/java/org/apache/sling/pipes/PipeBindings.java
@@ -37,7 +37,6 @@ import java.io.InputStreamReader;
 import java.net.URL;
 import java.util.HashMap;
 import java.util.Map;
-import java.util.concurrent.RejectedExecutionException;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
 
@@ -163,7 +162,7 @@ public class PipeBindings {
      */
     public void addScript(ResourceResolver resolver, String path) {
         if (!allowAdditionalScripts) {
-            throw new RejectedExecutionException("additional scripts are not 
allowed per configuration");
+            throw new SecurityException("additional scripts are not allowed 
per configuration");
         }
         InputStream is = null;
         try {

Reply via email to