"adrian(a)jboss.org" wrote :
| Iteration and delegation, {insert explitive here :-) }
|
| | for (BeanMetaData bfb : bfBeans)
| | {
| | KernelDeploymentDeployer.addBeanComponent(unit, bfb);
| |
|
| Who knows what happens when addBeanComponent throws an error?
|
Why do we treat component failure on deploy (AbstractComponentDeployer)
| try
| {
| deployComponents(unit);
| }
| catch (Throwable t)
| {
| undeployComponents(unit);
| throw DeploymentException.rethrowAsDeploymentException("Error deploying:
" + unit.getName(), t);
| }
|
differently then in AbstractRealDeployerWithInput
| List<T> visited = new ArrayList();
| try
| {
| Set<? extends T> deployments = unit.getAllMetaData(getInput());
| for (T deployment : deployments)
| {
| visitor.deploy(unit, deployment);
| visited.add(deployment);
| }
| }
| catch (Throwable t)
| {
| for (int i = visited.size()-1; i >= 0; --i)
| {
| try
| {
| visitor.undeploy(unit, visited.get(i));
| }
| catch (Throwable ignored)
| {
| log.warn("Error during undeploy: " + unit.getName(),
ignored);
| }
| }
| throw DeploymentException.rethrowAsDeploymentException("Error deploying:
" + unit.getName(), t);
| }
|
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4154576#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...