You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@deltaspike.apache.org by li...@apache.org on 2012/04/13 00:39:07 UTC

[2/2] git commit: Introducing two new interfaces for Exception Handling

Introducing two new interfaces for Exception Handling

This helps split up the user API from the SPI / internal calls.


Project: http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/commit/f21bf912
Tree: http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/tree/f21bf912
Diff: http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/diff/f21bf912

Branch: refs/heads/master
Commit: f21bf9121a00aad5cea75957cca7c59cbbc3035b
Parents: b2e7b90
Author: Jason Porter <li...@apache.org>
Authored: Thu Apr 12 13:58:22 2012 -0600
Committer: Jason Porter <li...@apache.org>
Committed: Thu Apr 12 13:58:22 2012 -0600

----------------------------------------------------------------------
 .../api/exception/control/CaughtException.java     |  170 ---------------
 .../core/api/exception/control/ExceptionEvent.java |   78 +++++++
 .../core/api/exception/control/HandlerMethod.java  |    2 +-
 .../control/IntrospectiveExceptionEvent.java       |   46 ++++
 .../impl/exception/control/ExceptionEventImpl.java |  151 +++++++++++++
 .../control/ExceptionHandlerDispatch.java          |   18 +-
 .../impl/exception/control/HandlerMethodImpl.java  |    6 +-
 .../control/OutboundParameterValueRedefiner.java   |   12 +-
 .../impl/exception/control/event/EventTest.java    |    9 +-
 .../control/flow/AbortingBreadthFirstHandler.java  |    6 +-
 .../control/flow/AbortingDepthHandler.java         |    6 +-
 .../control/flow/ExceptionHandledHandler.java      |    8 +-
 .../control/flow/ProceedCauseHandler.java          |   10 +-
 .../exception/control/flow/RethrowHandler.java     |    6 +-
 .../exception/control/flow/ThrowingNewHandler.java |    6 +-
 .../control/handler/BadInjectionPointHandler.java  |    4 +-
 .../control/handler/CalledExceptionHandler.java    |   12 +-
 .../control/handler/ExtensionExceptionHandler.java |   26 +-
 .../handler/HandlerWhichThrowsExceptions.java      |    4 +-
 .../exception/control/handler/UnMuteHandler.java   |    6 +-
 .../control/traversal/ExceptionHandlerMethods.java |   18 +-
 21 files changed, 355 insertions(+), 249 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/CaughtException.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/CaughtException.java b/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/CaughtException.java
deleted file mode 100644
index 3abd952..0000000
--- a/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/CaughtException.java
+++ /dev/null
@@ -1,170 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-package org.apache.deltaspike.core.api.exception.control;
-
-import javax.enterprise.inject.Typed;
-
-/**
- * Payload for an exception to be handled.  This object is not immutable as small pieces of the state may be set by the
- * handler.
- *
- * @param <T> Exception type this event represents
- */
-@SuppressWarnings({ "unchecked", "CdiManagedBeanInconsistencyInspection" })
-@Typed()
-//X TODO discuss an interface to avoid internal methods in the api
-public class CaughtException<T extends Throwable>
-{
-    private final T exception;
-    private boolean unmute;
-    private ExceptionHandlingFlow flow;
-    private Throwable throwNewException;
-    private final boolean beforeTraversal;
-    private final boolean markedHandled;
-
-
-    /**
-     * Initial state constructor.
-     *
-     * @param stack           Information about the current exception and cause chain.
-     * @param beforeTraversal flag indicating the direction of the cause chain traversal
-     * @param handled         flag indicating the exception has already been handled by a previous handler
-     * @throws IllegalArgumentException if stack is null
-     */
-    public CaughtException(final ExceptionStack stack, final boolean beforeTraversal, final boolean handled)
-    {
-        if (stack == null)
-        {
-            throw new IllegalArgumentException("null is not valid for stack");
-        }
-
-        this.exception = (T) stack.getCurrent();
-        this.beforeTraversal = beforeTraversal;
-        this.markedHandled = handled;
-        this.flow = ExceptionHandlingFlow.HANDLED_AND_CONTINUE;
-    }
-
-    public T getException()
-    {
-        return this.exception;
-    }
-
-    /**
-     * Instructs the dispatcher to abort further processing of handlers.
-     */
-    public void abort()
-    {
-        this.flow = ExceptionHandlingFlow.ABORT;
-    }
-
-    /**
-     * Instructs the dispatcher to throw the original exception after handler processing.
-     */
-    public void throwOriginal()
-    {
-        this.flow = ExceptionHandlingFlow.THROW_ORIGINAL;
-    }
-
-    /**
-     * Instructs the dispatcher to terminate additional handler processing and mark the event as handled.
-     */
-    public void handled()
-    {
-        this.flow = ExceptionHandlingFlow.HANDLED;
-    }
-
-    /**
-     * Default instruction to dispatcher, continues handler processing.
-     */
-    public void handledAndContinue()
-    {
-        this.flow = ExceptionHandlingFlow.HANDLED_AND_CONTINUE;
-    }
-
-    /**
-     * Similar to {@link org.apache.deltaspike.core.api.exception.control.CaughtException#handledAndContinue()},
-     * but instructs the dispatcher to markHandled to the next element
-     * in the cause chain without processing additional handlers for this cause chain element.
-     */
-    public void skipCause()
-    {
-        this.flow = ExceptionHandlingFlow.SKIP_CAUSE;
-    }
-
-    /**
-     * Instructs the dispatcher to allow this handler to be invoked again.
-     */
-    public void unmute()
-    {
-        this.unmute = true;
-    }
-
-    /**
-     * Internal only
-     */
-    public boolean isUnmute()
-    {
-        return this.unmute;
-    }
-
-    /* Later
-    public ExceptionStack getExceptionStack() {
-    }
-    */
-
-    /**
-     * Internal only
-     */
-    public ExceptionHandlingFlow getCurrentExceptionHandlingFlow()
-    {
-        return this.flow;
-    }
-
-    public boolean isMarkedHandled()
-    {
-        return this.markedHandled;
-    }
-
-    public boolean isBeforeTraversal()
-    {
-        return beforeTraversal;
-    }
-
-    /**
-     * Rethrow the exception, but use the given exception instead of the original.
-     *
-     * @param t Exception to be thrown in place of the original.
-     */
-    public void rethrow(Throwable t)
-    {
-        this.throwNewException = t;
-        this.flow = ExceptionHandlingFlow.THROW;
-    }
-
-    /**
-     * Internal only.
-     *
-     * @return
-     */
-    public Throwable getThrowNewException()
-    {
-        return this.throwNewException;
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/ExceptionEvent.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/ExceptionEvent.java b/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/ExceptionEvent.java
new file mode 100644
index 0000000..872b1c3
--- /dev/null
+++ b/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/ExceptionEvent.java
@@ -0,0 +1,78 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.deltaspike.core.api.exception.control;
+
+/**
+ * Payload for an exception to be handled.  Implementations of this interface should not expose internals and remain
+ * immutable for this contract.
+ *
+ * @param <T> Exception type this event represents
+ */
+public interface ExceptionEvent<T extends Throwable>
+{
+    /**
+     * The exception causing this event.
+     */
+    T getException();
+
+    /**
+     * Instructs the dispatcher to abort further processing of handlers.
+     */
+    void abort();
+
+    /**
+     * Instructs the dispatcher to throw the original exception after handler processing.
+     */
+    void throwOriginal();
+
+    /**
+     * Instructs the dispatcher to terminate additional handler processing and mark the event as handled.
+     */
+    void handled();
+
+    /**
+     * Default instruction to dispatcher, continues handler processing.
+     */
+    void handledAndContinue();
+
+    /**
+     * Similar to {@link ExceptionEvent#handledAndContinue()},
+     * but instructs the dispatcher to markHandled to the next element
+     * in the cause chain without processing additional handlers for this cause chain element.
+     */
+    void skipCause();
+
+    /**
+     * Instructs the dispatcher to allow this handler to be invoked again.
+     */
+    void unmute();
+
+    /**
+     * Rethrow the exception, but use the given exception instead of the original.
+     *
+     * @param t Exception to be thrown in place of the original.
+     */
+    void rethrow(Throwable t);
+
+    /**
+     * Check to see if this exception has been handled.
+     */
+    boolean isMarkedHandled();
+}

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/HandlerMethod.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/HandlerMethod.java b/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/HandlerMethod.java
index 00fe62e..f1a574a 100644
--- a/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/HandlerMethod.java
+++ b/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/api/exception/control/HandlerMethod.java
@@ -52,7 +52,7 @@ public interface HandlerMethod<T extends Throwable>
      *
      * @param event event to pass to the handler.
      */
-    void notify(CaughtException<T> event);
+    void notify(ExceptionEvent<T> event);
 
     /**
      * Obtains the precedence of the handler.

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/spi/exception/control/IntrospectiveExceptionEvent.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/spi/exception/control/IntrospectiveExceptionEvent.java b/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/spi/exception/control/IntrospectiveExceptionEvent.java
new file mode 100644
index 0000000..e4a7c3b
--- /dev/null
+++ b/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/spi/exception/control/IntrospectiveExceptionEvent.java
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.deltaspike.core.spi.exception.control;
+
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
+import org.apache.deltaspike.core.api.exception.control.ExceptionHandlingFlow;
+
+/**
+ * Internal view into the ExceptionEvent. Methods on this interface are used by the ExceptionHandlerDispatcher.
+ */
+public interface IntrospectiveExceptionEvent<T extends Throwable> extends ExceptionEvent<T>
+{
+    /**
+     * Check to see if this event has been unmutted and therefore called again.
+     */
+    boolean isUnmute();
+
+    /**
+     * The next expected step in the exception handling flow (i.e. abort, rethrow, etc)
+     */
+    ExceptionHandlingFlow getCurrentExceptionHandlingFlow();
+
+    boolean isBeforeTraversal();
+
+    /**
+     * Returns the exception that should be thrown if the next step in the flow is THROW.
+     */
+    Throwable getThrowNewException();
+}

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/ExceptionEventImpl.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/ExceptionEventImpl.java b/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/ExceptionEventImpl.java
new file mode 100644
index 0000000..5b8a6f9
--- /dev/null
+++ b/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/ExceptionEventImpl.java
@@ -0,0 +1,151 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.deltaspike.core.impl.exception.control;
+
+import org.apache.deltaspike.core.api.exception.control.ExceptionHandlingFlow;
+import org.apache.deltaspike.core.api.exception.control.ExceptionStack;
+import org.apache.deltaspike.core.spi.exception.control.IntrospectiveExceptionEvent;
+
+import javax.enterprise.inject.Typed;
+
+/**
+ * Payload for an exception to be handled.  This object is not immutable as small pieces of the state may be set by the
+ * handler.
+ *
+ * @param <T> Exception type this event represents
+ */
+@SuppressWarnings({"unchecked", "CdiManagedBeanInconsistencyInspection"})
+@Typed()
+//X TODO discuss an interface to avoid internal methods in the api
+public class ExceptionEventImpl<T extends Throwable> implements IntrospectiveExceptionEvent<T>
+{
+    private final T exception;
+    private boolean unmute;
+    private ExceptionHandlingFlow flow;
+    private Throwable throwNewException;
+    private final boolean beforeTraversal;
+    private final boolean markedHandled;
+
+
+    /**
+     * Initial state constructor.
+     *
+     * @param stack           Information about the current exception and cause chain.
+     * @param beforeTraversal flag indicating the direction of the cause chain traversal
+     * @param handled         flag indicating the exception has already been handled by a previous handler
+     * @throws IllegalArgumentException if stack is null
+     */
+    public ExceptionEventImpl(final ExceptionStack stack, final boolean beforeTraversal, final boolean handled)
+    {
+        if (stack == null)
+        {
+            throw new IllegalArgumentException("null is not valid for stack");
+        }
+
+        this.exception = (T) stack.getCurrent();
+        this.beforeTraversal = beforeTraversal;
+        this.markedHandled = handled;
+        this.flow = ExceptionHandlingFlow.HANDLED_AND_CONTINUE;
+    }
+
+    @Override
+    public T getException()
+    {
+        return this.exception;
+    }
+
+    @Override
+    public void abort()
+    {
+        this.flow = ExceptionHandlingFlow.ABORT;
+    }
+
+    @Override
+    public void throwOriginal()
+    {
+        this.flow = ExceptionHandlingFlow.THROW_ORIGINAL;
+    }
+
+    @Override
+    public void handled()
+    {
+        this.flow = ExceptionHandlingFlow.HANDLED;
+    }
+
+    @Override
+    public void handledAndContinue()
+    {
+        this.flow = ExceptionHandlingFlow.HANDLED_AND_CONTINUE;
+    }
+
+    @Override
+    public void skipCause()
+    {
+        this.flow = ExceptionHandlingFlow.SKIP_CAUSE;
+    }
+
+    @Override
+    public void unmute()
+    {
+        this.unmute = true;
+    }
+
+    @Override
+    public boolean isUnmute()
+    {
+        return this.unmute;
+    }
+
+    /* Later
+    public ExceptionStack getExceptionStack() {
+    }
+    */
+
+    @Override
+    public ExceptionHandlingFlow getCurrentExceptionHandlingFlow()
+    {
+        return this.flow;
+    }
+
+    @Override
+    public boolean isMarkedHandled()
+    {
+        return this.markedHandled;
+    }
+
+    @Override
+    public boolean isBeforeTraversal()
+    {
+        return beforeTraversal;
+    }
+
+    @Override
+    public void rethrow(Throwable t)
+    {
+        this.throwNewException = t;
+        this.flow = ExceptionHandlingFlow.THROW;
+    }
+
+    @Override
+    public Throwable getThrowNewException()
+    {
+        return this.throwNewException;
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/ExceptionHandlerDispatch.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/ExceptionHandlerDispatch.java b/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/ExceptionHandlerDispatch.java
index dee2842..61d1b70 100644
--- a/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/ExceptionHandlerDispatch.java
+++ b/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/ExceptionHandlerDispatch.java
@@ -19,7 +19,6 @@
 
 package org.apache.deltaspike.core.impl.exception.control;
 
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
 import org.apache.deltaspike.core.api.exception.control.ExceptionStack;
 import org.apache.deltaspike.core.api.exception.control.ExceptionToCatch;
 import org.apache.deltaspike.core.api.exception.control.HandlerMethod;
@@ -52,10 +51,10 @@ public class ExceptionHandlerDispatch
      * Observes the event, finds the correct exception handler(s) and invokes them.
      *
      * @param exceptionEvent exception to be invoked
-     * @param beanManager             active bean manager
+     * @param beanManager    active bean manager
      * @throws Throwable If a handler requests the exception to be re-thrown.
      */
-    @SuppressWarnings({ "unchecked", "MethodWithMultipleLoops", "ThrowableResultOfMethodCallIgnored" })
+    @SuppressWarnings({"unchecked", "MethodWithMultipleLoops", "ThrowableResultOfMethodCallIgnored"})
     public void executeHandlers(@Observes @Any ExceptionToCatch exceptionEvent,
                                 final BeanManager beanManager) throws Throwable
     {
@@ -66,7 +65,7 @@ public class ExceptionHandlerDispatch
         Throwable throwException = null;
 
         final HandlerMethodStorage handlerMethodStorage =
-            BeanProvider.getContextualReference(HandlerMethodStorage.class);
+                BeanProvider.getContextualReference(HandlerMethodStorage.class);
 
         try
         {
@@ -78,7 +77,8 @@ public class ExceptionHandlerDispatch
 
             beanManager.fireEvent(stack); // Allow for modifying the exception stack
 
-        inbound_cause: //indentation needed by the current checkstyle rules
+            inbound_cause:
+            //indentation needed by the current checkstyle rules
             while (stack.getCurrent() != null)
             {
                 final List<HandlerMethod<?>> breadthFirstHandlerMethods = new ArrayList<HandlerMethod<?>>(
@@ -92,7 +92,7 @@ public class ExceptionHandlerDispatch
                         LOG.fine(String.format("Notifying handler %s", handler));
 
                         @SuppressWarnings("rawtypes")
-                        final CaughtException breadthFirstEvent = new CaughtException(stack, true,
+                        final ExceptionEventImpl breadthFirstEvent = new ExceptionEventImpl(stack, true,
                                 exceptionEvent.isHandled());
 
                         handler.notify(breadthFirstEvent);
@@ -127,7 +127,7 @@ public class ExceptionHandlerDispatch
                                 break;
                             default:
                                 throw new IllegalStateException(
-                                    "Unexpected enum type " + breadthFirstEvent.getCurrentExceptionHandlingFlow());
+                                        "Unexpected enum type " + breadthFirstEvent.getCurrentExceptionHandlingFlow());
                         }
                     }
                 }
@@ -149,7 +149,7 @@ public class ExceptionHandlerDispatch
                         LOG.fine(String.format("Notifying handler %s", handler));
 
                         @SuppressWarnings("rawtypes")
-                        final CaughtException depthFirstEvent = new CaughtException(stack, false,
+                        final ExceptionEventImpl depthFirstEvent = new ExceptionEventImpl(stack, false,
                                 exceptionEvent.isHandled());
                         handler.notify(depthFirstEvent);
 
@@ -183,7 +183,7 @@ public class ExceptionHandlerDispatch
                                 break;
                             default:
                                 throw new IllegalStateException(
-                                    "Unexpected enum type " + depthFirstEvent.getCurrentExceptionHandlingFlow());
+                                        "Unexpected enum type " + depthFirstEvent.getCurrentExceptionHandlingFlow());
                         }
                     }
                 }

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/HandlerMethodImpl.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/HandlerMethodImpl.java b/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/HandlerMethodImpl.java
index 06d2a1a..27e1b22 100644
--- a/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/HandlerMethodImpl.java
+++ b/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/HandlerMethodImpl.java
@@ -20,7 +20,7 @@
 package org.apache.deltaspike.core.impl.exception.control;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.HandlerMethod;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 import org.apache.deltaspike.core.api.literal.AnyLiteral;
@@ -207,7 +207,7 @@ public class HandlerMethodImpl<T extends Throwable> implements HandlerMethod<T>
      * {@inheritDoc}
      */
     @Override
-    public void notify(final CaughtException<T> event)
+    public void notify(final ExceptionEvent<T> event)
     {
         CreationalContext<?> ctx = null;
         try
@@ -266,7 +266,7 @@ public class HandlerMethodImpl<T extends Throwable> implements HandlerMethod<T>
                 if (!param.equals(this.handlerParameter))
                 {
                     this.injectionPoints.add(
-                        new ImmutableInjectionPoint(param, getBeanManager(), getBean(), false, false));
+                            new ImmutableInjectionPoint(param, getBeanManager(), getBean(), false, false));
                 }
             }
 

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/OutboundParameterValueRedefiner.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/OutboundParameterValueRedefiner.java b/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/OutboundParameterValueRedefiner.java
index 0ea20d1..0467ebb 100644
--- a/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/OutboundParameterValueRedefiner.java
+++ b/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/exception/control/OutboundParameterValueRedefiner.java
@@ -19,7 +19,7 @@
 
 package org.apache.deltaspike.core.impl.exception.control;
 
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.metadata.builder.ParameterValueRedefiner;
 import org.apache.deltaspike.core.api.provider.BeanManagerProvider;
 
@@ -27,22 +27,22 @@ import javax.enterprise.context.spi.CreationalContext;
 import javax.enterprise.inject.spi.Bean;
 
 /**
- * Redefiner allowing to inject a non contextual instance of {@link CaughtException} into the first parameter. This
+ * Redefiner allowing to inject a non contextual instance of {@link ExceptionEventImpl} into the first parameter. This
  * class is immutable.
  */
 class OutboundParameterValueRedefiner implements ParameterValueRedefiner
 {
-    private final CaughtException<?> event;
+    private final ExceptionEvent<?> event;
     private final Bean<?> declaringBean;
     private final HandlerMethodImpl<?> handlerMethod;
 
     /**
      * Sole constructor.
      *
-     * @param event   instance of CaughtException to inject.
+     * @param event         instance of ExceptionEventImpl to inject.
      * @param handlerMethod Handler method this redefiner is for
      */
-    OutboundParameterValueRedefiner(final CaughtException<?> event, final HandlerMethodImpl<?> handlerMethod)
+    OutboundParameterValueRedefiner(final ExceptionEvent<?> event, final HandlerMethodImpl<?> handlerMethod)
     {
         this.event = event;
         this.declaringBean = handlerMethod.getBean();
@@ -56,7 +56,7 @@ class OutboundParameterValueRedefiner implements ParameterValueRedefiner
     public Object redefineParameterValue(ParameterValue value)
     {
         CreationalContext<?> ctx = BeanManagerProvider.getInstance().getBeanManager()
-            .createCreationalContext(this.declaringBean);
+                .createCreationalContext(this.declaringBean);
 
         try
         {

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/event/EventTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/event/EventTest.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/event/EventTest.java
index 4031224..72e8516 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/event/EventTest.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/event/EventTest.java
@@ -20,11 +20,12 @@
 package org.apache.deltaspike.test.core.impl.exception.control.event;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.ExceptionToCatch;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 import org.apache.deltaspike.core.api.provider.BeanManagerProvider;
+import org.apache.deltaspike.core.spi.exception.control.IntrospectiveExceptionEvent;
 import org.apache.deltaspike.test.core.impl.exception.control.event.literal.EventQualifierLiteral;
 import org.apache.deltaspike.test.util.ArchiveUtils;
 import org.jboss.arquillian.container.test.api.Deployment;
@@ -84,19 +85,19 @@ public class EventTest
         this.bm.fireEvent(new ExceptionToCatch(new NullPointerException(), new EventQualifierLiteral()));
     }
 
-    public void verifyDescEvent(@BeforeHandles CaughtException<NullPointerException> event)
+    public void verifyDescEvent(@BeforeHandles IntrospectiveExceptionEvent<NullPointerException> event)
     {
         this.qualiferCalledCount++;
         assertTrue(event.isBeforeTraversal());
     }
 
-    public void verifyAscEvent(@Handles CaughtException<NullPointerException> event)
+    public void verifyAscEvent(@Handles IntrospectiveExceptionEvent<NullPointerException> event)
     {
         this.qualiferCalledCount++;
         assertFalse(event.isBeforeTraversal());
     }
 
-    public void verifyQualifierEvent(@Handles @EventQualifier CaughtException<NullPointerException> event)
+    public void verifyQualifierEvent(@Handles @EventQualifier ExceptionEvent<NullPointerException> event)
     {
         this.qualiferCalledCount++;
         assertThat(this.qualiferCalledCount, is(1));

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/AbortingBreadthFirstHandler.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/AbortingBreadthFirstHandler.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/AbortingBreadthFirstHandler.java
index 7c89458..5da3be3 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/AbortingBreadthFirstHandler.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/AbortingBreadthFirstHandler.java
@@ -20,7 +20,7 @@
 package org.apache.deltaspike.test.core.impl.exception.control.flow;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
@@ -34,13 +34,13 @@ public class AbortingBreadthFirstHandler
     private boolean abortCalled = false;
     private boolean proceedCalled = false;
 
-    public void abortHandler(@BeforeHandles CaughtException<Exception> event)
+    public void abortHandler(@BeforeHandles ExceptionEvent<Exception> event)
     {
         abortCalled = true;
         event.abort();
     }
 
-    public void proceedHandler(@Handles CaughtException<NullPointerException> event)
+    public void proceedHandler(@Handles ExceptionEvent<NullPointerException> event)
     {
         proceedCalled = true;
         event.handledAndContinue();

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/AbortingDepthHandler.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/AbortingDepthHandler.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/AbortingDepthHandler.java
index 2ed17a6..f4446b6 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/AbortingDepthHandler.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/AbortingDepthHandler.java
@@ -19,7 +19,7 @@
 
 package org.apache.deltaspike.test.core.impl.exception.control.flow;
 
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
@@ -37,13 +37,13 @@ public class AbortingDepthHandler
     {
     }
 
-    public void abortHandler(@Handles CaughtException<Exception> event)
+    public void abortHandler(@Handles ExceptionEvent<Exception> event)
     {
         abortCalled = true;
         event.abort();
     }
 
-    public void proceedHandler(@Handles CaughtException<Throwable> event)
+    public void proceedHandler(@Handles ExceptionEvent<Throwable> event)
     {
         proceedCalled = true;
         event.handledAndContinue();

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ExceptionHandledHandler.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ExceptionHandledHandler.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ExceptionHandledHandler.java
index ef548f8..7ab90fc 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ExceptionHandledHandler.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ExceptionHandledHandler.java
@@ -20,7 +20,7 @@
 package org.apache.deltaspike.test.core.impl.exception.control.flow;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
@@ -34,18 +34,18 @@ public class ExceptionHandledHandler
     private boolean iaeAscCalled = false;
     private boolean npeDescCalled = false;
 
-    public void exHandler(@Handles CaughtException<Exception> event)
+    public void exHandler(@Handles ExceptionEvent<Exception> event)
     {
         exAscCalled = true;
     }
 
-    public void npeHandler(@Handles CaughtException<IllegalArgumentException> event)
+    public void npeHandler(@Handles ExceptionEvent<IllegalArgumentException> event)
     {
         iaeAscCalled = true;
         event.handled();
     }
 
-    public void npeDescHandler(@BeforeHandles CaughtException<NullPointerException> event)
+    public void npeDescHandler(@BeforeHandles ExceptionEvent<NullPointerException> event)
     {
         npeDescCalled = true;
         event.handled();

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ProceedCauseHandler.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ProceedCauseHandler.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ProceedCauseHandler.java
index 21f968c..d5ddfd4 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ProceedCauseHandler.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ProceedCauseHandler.java
@@ -20,7 +20,7 @@
 package org.apache.deltaspike.test.core.impl.exception.control.flow;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
@@ -36,26 +36,26 @@ public class ProceedCauseHandler
     private int depthFirstNpeCalled = 0;
     private int depthFirstNpeHigherPrecedenceCalled = 0;
 
-    public void npeInboundHandler(@BeforeHandles CaughtException<NullPointerException> event)
+    public void npeInboundHandler(@BeforeHandles ExceptionEvent<NullPointerException> event)
     {
         breadthFirstNpeCalled++;
         event.skipCause();
     }
 
     public void npeLowerPrecedenceInboundHandler(
-            @BeforeHandles(ordinal = -50) CaughtException<NullPointerException> event)
+            @BeforeHandles(ordinal = -50) ExceptionEvent<NullPointerException> event)
     {
         breadthFirstNpeLowerPrecedenceCalled++;
         event.handledAndContinue();
     }
 
-    public void npeOutboundHandler(@Handles CaughtException<NullPointerException> event)
+    public void npeOutboundHandler(@Handles ExceptionEvent<NullPointerException> event)
     {
         depthFirstNpeCalled++;
         event.skipCause();
     }
 
-    public void npeHigherPrecedenceOutboundHandler(@Handles(ordinal = -10) CaughtException<NullPointerException> event)
+    public void npeHigherPrecedenceOutboundHandler(@Handles(ordinal = -10) ExceptionEvent<NullPointerException> event)
     {
         depthFirstNpeHigherPrecedenceCalled++;
         event.handledAndContinue();

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/RethrowHandler.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/RethrowHandler.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/RethrowHandler.java
index 2413c28..e38cdbd 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/RethrowHandler.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/RethrowHandler.java
@@ -20,20 +20,20 @@
 package org.apache.deltaspike.test.core.impl.exception.control.flow;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
 @ExceptionHandler
 public class RethrowHandler
 {
-    public void rethrow(@Handles CaughtException<NullPointerException> event)
+    public void rethrow(@Handles ExceptionEvent<NullPointerException> event)
     {
         event.throwOriginal();
     }
 
     public void rethrowInbound(
-            @BeforeHandles CaughtException<IllegalArgumentException> event)
+            @BeforeHandles ExceptionEvent<IllegalArgumentException> event)
     {
         event.throwOriginal();
     }

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ThrowingNewHandler.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ThrowingNewHandler.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ThrowingNewHandler.java
index 0d09f77..835afb1 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ThrowingNewHandler.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/flow/ThrowingNewHandler.java
@@ -20,20 +20,20 @@
 package org.apache.deltaspike.test.core.impl.exception.control.flow;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
 @ExceptionHandler
 public class ThrowingNewHandler
 {
-    public void rethrow(@Handles CaughtException<NullPointerException> event)
+    public void rethrow(@Handles ExceptionEvent<NullPointerException> event)
     {
         event.rethrow(new UnsupportedOperationException());
     }
 
     public void rethrowInbound(
-            @BeforeHandles CaughtException<IllegalArgumentException> event)
+            @BeforeHandles ExceptionEvent<IllegalArgumentException> event)
     {
         event.rethrow(new UnsupportedOperationException());
     }

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/BadInjectionPointHandler.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/BadInjectionPointHandler.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/BadInjectionPointHandler.java
index d6cff38..c8e9213 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/BadInjectionPointHandler.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/BadInjectionPointHandler.java
@@ -19,7 +19,7 @@
 
 package org.apache.deltaspike.test.core.impl.exception.control.handler;
 
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
@@ -29,7 +29,7 @@ import org.apache.deltaspike.core.api.exception.control.Handles;
 @ExceptionHandler
 public class BadInjectionPointHandler
 {
-    void handleException(int firstParam, @Handles CaughtException<Exception> event)
+    void handleException(int firstParam, @Handles ExceptionEvent<Exception> event)
     {
     }
 }

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/CalledExceptionHandler.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/CalledExceptionHandler.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/CalledExceptionHandler.java
index 858a787..f509ea6 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/CalledExceptionHandler.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/CalledExceptionHandler.java
@@ -20,7 +20,7 @@
 package org.apache.deltaspike.test.core.impl.exception.control.handler;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
@@ -39,19 +39,19 @@ public class CalledExceptionHandler
     private boolean beanmanagerInjected = false;
     private boolean locationDifferBeanmanagerInjected = false;
 
-    public void basicHandler(@Handles CaughtException<Exception> event)
+    public void basicHandler(@Handles ExceptionEvent<Exception> event)
     {
         outboundHandlerCalled = true;
         outboundHandlerTimesCalled++;
     }
 
-    public void basicInboundHandler(@BeforeHandles CaughtException<Exception> event)
+    public void basicInboundHandler(@BeforeHandles ExceptionEvent<Exception> event)
     {
         inboundHandlerTimesCalled++;
         event.handledAndContinue();
     }
 
-    public void extraInjections(@Handles CaughtException<IllegalArgumentException> event, BeanManager bm)
+    public void extraInjections(@Handles ExceptionEvent<IllegalArgumentException> event, BeanManager bm)
     {
         if (bm != null)
         {
@@ -59,7 +59,7 @@ public class CalledExceptionHandler
         }
     }
 
-    void protectedHandler(@Handles CaughtException<IllegalStateException> event)
+    void protectedHandler(@Handles ExceptionEvent<IllegalStateException> event)
     {
         protectedHandlerCalled = true;
 
@@ -70,7 +70,7 @@ public class CalledExceptionHandler
     }
 
     @SuppressWarnings("unused")
-    private void handlerLocationInjections(BeanManager bm, @Handles CaughtException<SQLException> event)
+    private void handlerLocationInjections(BeanManager bm, @Handles ExceptionEvent<SQLException> event)
     {
         if (bm != null)
         {

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/ExtensionExceptionHandler.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/ExtensionExceptionHandler.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/ExtensionExceptionHandler.java
index 791c66e..aa2eee8 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/ExtensionExceptionHandler.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/ExtensionExceptionHandler.java
@@ -20,7 +20,7 @@
 package org.apache.deltaspike.test.core.impl.exception.control.handler;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 import org.apache.deltaspike.test.core.impl.exception.control.extension.Account;
@@ -33,67 +33,67 @@ import java.sql.SQLException;
 @ExceptionHandler
 public class ExtensionExceptionHandler
 {
-    public void catchDescException(@BeforeHandles CaughtException<Exception> event)
+    public void catchDescException(@BeforeHandles ExceptionEvent<Exception> event)
     {
         // Nothing to do currently
     }
 
-    public void catchFrameworkDescException(@BeforeHandles(ordinal = -50) CaughtException<Exception> event)
+    public void catchFrameworkDescException(@BeforeHandles(ordinal = -50) ExceptionEvent<Exception> event)
     {
         // Nothing to do here
     }
 
-    public void catchRuntime(@Handles CaughtException<RuntimeException> event)
+    public void catchRuntime(@Handles ExceptionEvent<RuntimeException> event)
     {
         // Nothing to do currently
     }
 
     public void catchThrowableBreadthFirst(
-            @BeforeHandles(ordinal = 10) CaughtException<Throwable> event)
+            @BeforeHandles(ordinal = 10) ExceptionEvent<Throwable> event)
     {
         // Nothing to do currently
     }
 
     public void catchThrowableP20BreadthFirst(
-            @BeforeHandles(ordinal = 20) CaughtException<Throwable> event)
+            @BeforeHandles(ordinal = 20) ExceptionEvent<Throwable> event)
     {
         // Nothing to do currently
     }
 
     public void catchThrowable(
-            @Handles(ordinal = 10) CaughtException<Throwable> event)
+            @Handles(ordinal = 10) ExceptionEvent<Throwable> event)
     {
         // Nothing to do currently
     }
 
     public void catchThrowableP20(
-            @Handles(ordinal = 20) CaughtException<Throwable> event)
+            @Handles(ordinal = 20) ExceptionEvent<Throwable> event)
     {
         // Nothing to do currently
     }
 
-    public void catchIAE(@Handles CaughtException<IllegalArgumentException> event)
+    public void catchIAE(@Handles ExceptionEvent<IllegalArgumentException> event)
     {
         // Nothing to do currently
     }
 
-    public void qualifiedHandler(@Handles @CatchQualifier CaughtException<Exception> event)
+    public void qualifiedHandler(@Handles @CatchQualifier ExceptionEvent<Exception> event)
     {
         // Method to verify the qualifiers are working correctly for handlers
     }
 
-    public void arqHandler(@Handles @Arquillian CaughtException<Throwable> event)
+    public void arqHandler(@Handles @Arquillian ExceptionEvent<Throwable> event)
     {
         // Method to verify the qualifiers are working correctly for handlers
     }
 
-    public void arqTestingHandler(@Handles @Arquillian @CatchQualifier CaughtException<Throwable> event)
+    public void arqTestingHandler(@Handles @Arquillian @CatchQualifier ExceptionEvent<Throwable> event)
     {
         // Method to verify the qualifiers are working correctly for handlers
     }
 
     public void differentParamHandlerLocationHandler(Account act, BeanManager bm,
-                                                     @Handles CaughtException<SQLException> event)
+                                                     @Handles ExceptionEvent<SQLException> event)
     {
         // Nothing here, just need to make sure this handler is picked up
     }

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/HandlerWhichThrowsExceptions.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/HandlerWhichThrowsExceptions.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/HandlerWhichThrowsExceptions.java
index e616b0f..27ddde9 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/HandlerWhichThrowsExceptions.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/HandlerWhichThrowsExceptions.java
@@ -19,7 +19,7 @@
 
 package org.apache.deltaspike.test.core.impl.exception.control.handler;
 
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
@@ -29,7 +29,7 @@ import org.apache.deltaspike.core.api.exception.control.Handles;
 @ExceptionHandler
 public class HandlerWhichThrowsExceptions
 {
-    public void throwsAnException(@Handles CaughtException<Throwable> evt) throws Exception
+    public void throwsAnException(@Handles ExceptionEvent<Throwable> evt) throws Exception
     {
     }
 }

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/UnMuteHandler.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/UnMuteHandler.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/UnMuteHandler.java
index deb9faa..e377160 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/UnMuteHandler.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/handler/UnMuteHandler.java
@@ -20,7 +20,7 @@
 package org.apache.deltaspike.test.core.impl.exception.control.handler;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
@@ -33,13 +33,13 @@ public class UnMuteHandler
     private int depthFirstNumberCalled = 0;
     private int breadthFirstNumberCalled = 0;
 
-    public void unMuteHandlerAsc(@Handles CaughtException<Exception> event)
+    public void unMuteHandlerAsc(@Handles ExceptionEvent<Exception> event)
     {
         depthFirstNumberCalled++;
         event.unmute();
     }
 
-    public void unMuteHandlerDesc(@BeforeHandles CaughtException<Exception> event)
+    public void unMuteHandlerDesc(@BeforeHandles ExceptionEvent<Exception> event)
     {
         breadthFirstNumberCalled++;
         event.unmute();

http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/f21bf912/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/traversal/ExceptionHandlerMethods.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/traversal/ExceptionHandlerMethods.java b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/traversal/ExceptionHandlerMethods.java
index 50cbeaa..9163df2 100644
--- a/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/traversal/ExceptionHandlerMethods.java
+++ b/deltaspike/core/impl/src/test/java/org/apache/deltaspike/test/core/impl/exception/control/traversal/ExceptionHandlerMethods.java
@@ -20,7 +20,7 @@
 package org.apache.deltaspike.test.core.impl.exception.control.traversal;
 
 import org.apache.deltaspike.core.api.exception.control.BeforeHandles;
-import org.apache.deltaspike.core.api.exception.control.CaughtException;
+import org.apache.deltaspike.core.api.exception.control.ExceptionEvent;
 import org.apache.deltaspike.core.api.exception.control.ExceptionHandler;
 import org.apache.deltaspike.core.api.exception.control.Handles;
 
@@ -32,42 +32,42 @@ public class ExceptionHandlerMethods
 {
     private static final List<Integer> executionOrder = new ArrayList<Integer>();
 
-    public void handleException1BF(@BeforeHandles CaughtException<Exceptions.Exception1> event)
+    public void handleException1BF(@BeforeHandles ExceptionEvent<Exceptions.Exception1> event)
     {
         executionOrder.add(7);
     }
 
-    public void handleException2BF(@BeforeHandles CaughtException<Exceptions.Exception2> event)
+    public void handleException2BF(@BeforeHandles ExceptionEvent<Exceptions.Exception2> event)
     {
         executionOrder.add(5);
     }
 
-    public void handleException3DF(@Handles CaughtException<Exceptions.Exception3> event)
+    public void handleException3DF(@Handles ExceptionEvent<Exceptions.Exception3> event)
     {
         executionOrder.add(3);
     }
 
-    public void handleException3BF(@BeforeHandles CaughtException<Exceptions.Exception3> event)
+    public void handleException3BF(@BeforeHandles ExceptionEvent<Exceptions.Exception3> event)
     {
         executionOrder.add(2);
     }
 
-    public void handleException3SuperclassBF(@BeforeHandles CaughtException<Exceptions.Exception3Super> event)
+    public void handleException3SuperclassBF(@BeforeHandles ExceptionEvent<Exceptions.Exception3Super> event)
     {
         executionOrder.add(1);
     }
 
-    public void handleException3SuperclassDF(@Handles CaughtException<Exceptions.Exception3Super> event)
+    public void handleException3SuperclassDF(@Handles ExceptionEvent<Exceptions.Exception3Super> event)
     {
         executionOrder.add(4);
     }
 
-    public void handleException2DF(@Handles CaughtException<Exceptions.Exception2> event)
+    public void handleException2DF(@Handles ExceptionEvent<Exceptions.Exception2> event)
     {
         executionOrder.add(6);
     }
 
-    public void handleException1DF(@Handles CaughtException<Exceptions.Exception1> event)
+    public void handleException1DF(@Handles ExceptionEvent<Exceptions.Exception1> event)
     {
         executionOrder.add(8);
     }