use of org.simbasecurity.core.chain.Command in project simba-os by cegeka.
the class AuthenticationFilterServiceImpl method processRequest.
@Transactional
public ActionDescriptor processRequest(RequestData requestData, String chainCommand) throws TException {
if (requestData == null) {
throw new IllegalArgumentException("Parameter 'requestData' can not be null");
}
if (chainCommand == null) {
throw new IllegalArgumentException("Parameter 'chainCommand' can not be null");
}
Command chain = locateCommandChain(chainCommand);
Session currentSession = getCurrentSession(requestData);
ChainContext chainContext = createChainContext(requestData, currentSession);
try {
chain.execute(chainContext);
} catch (Exception e) {
throw new RuntimeException(e);
}
return chainContext.getActionDescriptor();
}
Aggregations