org.rhq.enterprise.server.rest
Class SetCallerInterceptor
java.lang.Object
org.rhq.enterprise.server.rest.SetCallerInterceptor
public class SetCallerInterceptor
- extends Object
Interceptor to set the 'caller' variable of the AbstractRestBean from the princpial
that was passed in from the WEB tier.
For this to work, classes need to
- extends AbstractRestBean
- Add this class as Interceptor like this : @Interceptors(SetCallerInterceptor.class)
- Author:
- Heiko W. Rupp
|
Method Summary |
Object |
setCaller(javax.interceptor.InvocationContext ctx)
We need to take the Principal that was passed through the web-integration,
get an RHQ Subject and set a session for it. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SetCallerInterceptor
public SetCallerInterceptor()
setCaller
public Object setCaller(javax.interceptor.InvocationContext ctx)
throws Exception
- We need to take the Principal that was passed through the web-integration,
get an RHQ Subject and set a session for it. When the call was made, we need
to invalidate the session again.
- Parameters:
ctx - InvocationContext from the EJB invocation chain
- Returns:
- result of the method call
- Throws:
Exception - from method call or if no (valid) principal was provided
Copyright © 2008-2012 Red Hat, Inc.. All Rights Reserved.