Package com.cloudbees.vietnam4j

Examples of com.cloudbees.vietnam4j.ProxiedWebApplication


    public String getUrlName() {
        return "activiti-explorer";
    }

    public void doDynamic(StaplerRequest req, StaplerResponse rsp) throws ServletException, IOException {
        ProxiedWebApplication webApp = getProxyWebApplication(req);

        HttpSession session = req.getSession();
        HttpSession ps = webApp.getProxiedSession(session);
        UserDTO oldUser = (UserDTO)ps.getAttribute("jenkins.user");
        UserDTO newUser = createUserInfo();
        if (!mapToId(oldUser).equals(mapToId(newUser))) {
            // force a new session. AE isn't designed to anticipate the user change without invalidating a session,
            // but Jenkins does that. So when we see that the user has changed in Jenkins, force a new session
            // (but only in AE.)
            webApp.clearProxiedSession(session);
            ps = webApp.getProxiedSession(session);
        }

        ps.setAttribute("jenkins.user", newUser);


        webApp.handleRequest(req, rsp);
    }
View Full Code Here


                final ClassLoader ourLoader = getClass().getClassLoader();

                File war = new File(Jenkins.getInstance().getRootDir(), "cache/activiti-explorer");
                extract(ourLoader.getResource("activiti-explorer.war"),war);
                patch(war);
                webApp = new ProxiedWebApplication(
                        war,
                        req.getContextPath()+'/'+getUrlName());

                webApp.setParentLoaderHasPriority(true);
View Full Code Here

TOP

Related Classes of com.cloudbees.vietnam4j.ProxiedWebApplication

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.