Repository: tomee Updated Branches: refs/heads/tomee-1.7.x 8107307de -> aa289db58
not using RuntimeException but OpenEJBRuntimeException when possible Project: http://git-wip-us.apache.org/repos/asf/tomee/repo Commit: http://git-wip-us.apache.org/repos/asf/tomee/commit/aa289db5 Tree: http://git-wip-us.apache.org/repos/asf/tomee/tree/aa289db5 Diff: http://git-wip-us.apache.org/repos/asf/tomee/diff/aa289db5 Branch: refs/heads/tomee-1.7.x Commit: aa289db587e8b68495609a5f49a90cc8722a6d6b Parents: 8107307 Author: Romain manni-Bucau <rmannibu...@gmail.com> Authored: Fri Mar 4 08:20:17 2016 +0100 Committer: Romain manni-Bucau <rmannibu...@gmail.com> Committed: Fri Mar 4 08:20:17 2016 +0100 ---------------------------------------------------------------------- .../java/org/apache/openejb/core/ivm/BaseEjbProxyHandler.java | 5 +++-- .../java/org/apache/openejb/core/ivm/EjbObjectProxyHandler.java | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/tomee/blob/aa289db5/container/openejb-core/src/main/java/org/apache/openejb/core/ivm/BaseEjbProxyHandler.java ---------------------------------------------------------------------- diff --git a/container/openejb-core/src/main/java/org/apache/openejb/core/ivm/BaseEjbProxyHandler.java b/container/openejb-core/src/main/java/org/apache/openejb/core/ivm/BaseEjbProxyHandler.java index 9f2d0ca..debfde7 100644 --- a/container/openejb-core/src/main/java/org/apache/openejb/core/ivm/BaseEjbProxyHandler.java +++ b/container/openejb-core/src/main/java/org/apache/openejb/core/ivm/BaseEjbProxyHandler.java @@ -21,6 +21,7 @@ import org.apache.openejb.BeanContext; import org.apache.openejb.BeanType; import org.apache.openejb.InterfaceType; import org.apache.openejb.OpenEJBException; +import org.apache.openejb.OpenEJBRuntimeException; import org.apache.openejb.ProxyInfo; import org.apache.openejb.RpcContainer; import org.apache.openejb.core.ThreadContext; @@ -286,7 +287,7 @@ public abstract class BaseEjbProxyHandler implements InvocationHandler, Serializ if (callContext == null && localClientIdentity != null) { final SecurityService securityService = SystemInstance.get().getComponent(SecurityService.class); if(null == securityService){ - throw new RuntimeException("SecurityService has not been initialized"); + throw new OpenEJBRuntimeException("SecurityService has not been initialized"); } securityService.associate(localClientIdentity); } @@ -674,7 +675,7 @@ public abstract class BaseEjbProxyHandler implements InvocationHandler, Serializ final ContainerSystem containerSystem = SystemInstance.get().getComponent(ContainerSystem.class); if(null == containerSystem){ - throw new RuntimeException("ContainerSystem has not been initialized"); + throw new OpenEJBRuntimeException("ContainerSystem has not been initialized"); } setBeanContext(containerSystem.getBeanContext(deploymentID)); http://git-wip-us.apache.org/repos/asf/tomee/blob/aa289db5/container/openejb-core/src/main/java/org/apache/openejb/core/ivm/EjbObjectProxyHandler.java ---------------------------------------------------------------------- diff --git a/container/openejb-core/src/main/java/org/apache/openejb/core/ivm/EjbObjectProxyHandler.java b/container/openejb-core/src/main/java/org/apache/openejb/core/ivm/EjbObjectProxyHandler.java index 0d8549b..fe3935d 100644 --- a/container/openejb-core/src/main/java/org/apache/openejb/core/ivm/EjbObjectProxyHandler.java +++ b/container/openejb-core/src/main/java/org/apache/openejb/core/ivm/EjbObjectProxyHandler.java @@ -253,7 +253,7 @@ public abstract class EjbObjectProxyHandler extends BaseEjbProxyHandler { final SecurityService securityService = SystemInstance.get().getComponent(SecurityService.class); if(null == securityService){ - throw new RuntimeException("SecurityService has not been initialized"); + throw new OpenEJBRuntimeException("SecurityService has not been initialized"); } Object stateTmp = securityService.currentState();