Package org.apache.geronimo.common

Examples of org.apache.geronimo.common.UnresolvedEJBRefException


    private String getImplicitContainerId(URI module, String refName, EJBRefInfo ejbRefInfo) throws DeploymentException {
        Map references = (Map) ejbInterfaceIndex.get(ejbRefInfo);

        // if we didn't find any ejbs that implement that interface... give up
        if (references == null || references.isEmpty()) {
            throw new UnresolvedEJBRefException(refName, ejbRefInfo.isLocal(), ejbRefInfo.isSession(), ejbRefInfo.getHomeIntf(), ejbRefInfo.getBeanIntf(), false);
        }

        // if there is only one matching ejb, use it
        if (references.size() == 1) {
            return (String) references.values().iterator().next();
        }

        // We got more then one matching ejb.  Try to find an ejb in the current module
        String ejbRef = (String) references.get(module);
        if (ejbRef != null) {
            return ejbRef;
        }

        // there is more then one ejb that implements that interface... give up
        throw new UnresolvedEJBRefException(refName, ejbRefInfo.isLocal(), ejbRefInfo.isSession(), ejbRefInfo.getHomeIntf(), ejbRefInfo.getBeanIntf(), true);
    }
View Full Code Here

TOP

Related Classes of org.apache.geronimo.common.UnresolvedEJBRefException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.