head	1.15;
access;
symbols
	TIGRIS_1_1_0RC2:1.3.6.2
	TIGRIS_1_1_0RC1:1.3.6.2
	TIGRIS_1_1:1.3.6.2.0.2
	TIGRIS_1_0_8:1.3.6.2
	TIGRIS_1_0_8RC3:1.3.6.2
	TIGRIS_1_0_8RC2:1.3.6.2
	TIGRIS_1_0_8RC1:1.3.6.2
	TIGRIS_1_0_7:1.3.6.2
	TIGRIS_1_0_7RC3:1.3.6.2
	TIGRIS_1_0_7RC2:1.3.6.2
	TIGRIS_1_0_7RC1:1.3.6.2
	TIGRIS_1_0_6:1.3.6.2
	TIGRIS_1_0_6RC5:1.3.6.2
	TIGRIS_1_0_6RC4:1.3.6.2
	TIGRIS_1_0_6RC3:1.3.6.1
	TIGRIS_1_0_6RC2:1.3.6.1
	TIGRIS_1_0_6RC1:1.3.6.1
	TIGRIS_1_0_5:1.3
	TIGRIS_1_0_5RC6:1.3
	TIGRIS_1_0_5RC5:1.3
	TIGRIS_1_0_5RC4:1.3
	TIGRIS_1_0_5RC3:1.3
	TIGRIS_1_0_5RC2:1.3
	TIGRIS_1_0_5RC1:1.3
	TIGRIS_1_0_4:1.3
	TIGRIS_1_0_3:1.3
	TIGRIS_1_0_2:1.3
	TIGRIS_1_0_1:1.3
	TIGRIS_1_0:1.3.0.6
	TIGRIS_1_0_0:1.3
	TIGRIS_1_0_0_RC1:1.3.0.2
	dlr:1.1.1
	HELM_PEER_PORT_BRANCH:1.1.1.1;
locks; strict;
comment	@# @;


1.15
date	2001.08.29.19.42.49;	author leonardr;	state Exp;
branches;
next	1.14;

1.14
date	2001.08.21.16.34.12;	author leonardr;	state Exp;
branches;
next	1.13;

1.13
date	2001.08.20.19.09.12;	author leonardr;	state Exp;
branches;
next	1.12;

1.12
date	2001.08.11.09.08.02;	author dlr;	state Exp;
branches;
next	1.11;

1.11
date	2001.07.30.19.29.57;	author leonardr;	state Exp;
branches;
next	1.10;

1.10
date	2001.07.18.10.09.49;	author dlr;	state Exp;
branches;
next	1.9;

1.9
date	2001.07.18.10.09.14;	author dlr;	state Exp;
branches;
next	1.8;

1.8
date	2001.07.18.10.05.13;	author dlr;	state Exp;
branches;
next	1.7;

1.7
date	2001.06.12.00.35.14;	author leonardr;	state Exp;
branches;
next	1.6;

1.6
date	2001.06.01.19.22.55;	author leonardr;	state Exp;
branches;
next	1.5;

1.5
date	2001.06.01.17.06.32;	author leonardr;	state Exp;
branches;
next	1.4;

1.4
date	2001.05.23.01.50.12;	author dlr;	state Exp;
branches;
next	1.3;

1.3
date	2001.03.07.01.53.21;	author lucas;	state Exp;
branches
	1.3.6.1;
next	1.2;

1.2
date	2001.02.21.03.02.22;	author edk;	state Exp;
branches;
next	1.1;

1.1
date	2001.02.15.17.52.33;	author leonardr;	state dead;
branches
	1.1.1.1
	1.1.2.1;
next	;

1.1.1.1
date	2001.02.21.00.32.37;	author dlr;	state Exp;
branches;
next	;

1.1.2.1
date	2001.02.15.17.52.33;	author leonardr;	state Exp;
branches;
next	1.1.2.2;

1.1.2.2
date	2001.02.15.20.50.37;	author leonardr;	state Exp;
branches;
next	;

1.3.6.1
date	2001.06.01.19.18.07;	author leonardr;	state Exp;
branches;
next	1.3.6.2;

1.3.6.2
date	2001.06.12.01.15.29;	author leonardr;	state Exp;
branches;
next	;


desc
@@


1.15
log
@Moved integration-oriented code into new component package.
@
text
@/* ================================================================
 * Copyright (c) 2000-2001 CollabNet.  All rights reserved.
 * 
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are
 * met:
 * 
 * 1. Redistributions of source code must retain the above copyright
 * notice, this list of conditions and the following disclaimer.
 * 
 * 2. Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * 
 * 3. The end-user documentation included with the redistribution, if
 * any, must include the following acknowlegement: "This product includes
 * software developed by CollabNet (http://www.collab.net/)."
 * Alternately, this acknowlegement may appear in the software itself, if
 * and wherever such third-party acknowlegements normally appear.
 * 
 * 4. The hosted project names must not be used to endorse or promote
 * products derived from this software without prior written
 * permission. For written permission, please contact info@@collab.net.
 * 
 * 5. Products derived from this software may not use the "Tigris" name
 * nor may "Tigris" appear in their names without prior written
 * permission of CollabNet.
 * 
 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
 * IN NO EVENT SHALL COLLABNET OR ITS CONTRIBUTORS BE LIABLE FOR ANY
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
 * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
 * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 *
 * ====================================================================
 * 
 * This software consists of voluntary contributions made by many
 * individuals on behalf of CollabNet.
 */

package org.tigris.helm.host;

import java.util.*;
import java.sql.*;

import org.apache.turbine.util.Log;
import org.apache.commons.util.exception.NestableException;

import org.apache.velocity.context.Context;

import org.tigris.helm.security.HelmServlet;
import org.tigris.helm.security.RedirectException;
import org.tigris.helm.om.Task;
import org.tigris.helm.component.ToolEventPropagationService;

public class TaskList extends HelmServlet 
{
    /**
     * Put into the context information about the current tasks and
     * unfulfilled rebuild requests. This information is not
     * accessible from business objects, so we have to do this
     * explicitly.  
     */
    protected String processRequest(Context context)
        throws NestableException, RedirectException
    {
        String templateName = super.processRequest(context);
        List tasks = null;
        ToolEventPropagationService teps = 
            ToolEventPropagationService.getService();
        try 
        {
            context.put("tasks", Task.getTasks());
            context.put("eventQueue", teps.getQueue());
            context.put("failures", teps.getFailures());
        } 
        catch (Exception e) 
        {
            Log.error("Exception thrown in TaskList", e);
            throw new NestableException(e);
        }
        return templateName;
    }
}
@


1.14
log
@Added failure logging to events. The ToolEventPropagationService keeps track of the first and the most recent failure for each event.
@
text
@d60 1
a60 1
import org.tigris.helm.tool.ToolEventPropagationService;
@


1.13
log
@Tool event propagation now has singleton failover (but not persistence over restarts).
@
text
@d75 2
d80 2
a81 2
            context.put("eventQueue", 
                        ToolEventPropagationService.getService().getQueue());
@


1.12
log
@Upgrading to Turbine 3.0-dev, Fulcrum 1.0, and Torque 1.0.
@
text
@d60 1
d78 2
a79 1

@


1.11
log
@Stop coddling IZ in terms of user accounts; assume that IZ can get its permissions from Helm through the XML-RPC interface.
@
text
@d53 1
a53 1
import org.apache.turbine.util.TurbineException;
d70 1
a70 1
        throws TurbineException, RedirectException
d82 1
a82 1
            throw new TurbineException(e);
@


1.10
log
@further clean up
@
text
@a58 1
import org.tigris.helm.tool.task.IssueTrackingRebuildService;
a75 2
            IssueTrackingRebuildService service = 
                IssueTrackingRebuildService.getService();
a76 3
            context.put("unrebuiltProjects", 
                        service.getUnrebuiltProjectInformation());            
            context.put("failures", service.getFailures());
@


1.9
log
@clean up
@
text
@a51 2
import org.apache.velocity.context.Context;

d55 1
a55 1
import org.tigris.helm.security.RedirectException;
d58 1
d71 1
a71 1
	throws TurbineException, RedirectException
d73 1
a73 1
	String templateName = super.processRequest(context);
d92 1
a92 2
  
} /* end class TaskList */
@


1.8
log
@Ported Joist Redirect*Exception to Helm.
@
text
@a64 2
    public static final  String versionID = "$Id: TaskList.java,v 1.7 2001/06/12 00:35:14 leonardr Exp $";

@


1.7
log
@Persistent failures are now visible from the outside, since it's useful information.
@
text
@d57 1
a57 1
import org.joist.security.RedirectException;
d65 1
a65 1
    public static final  String versionID = "$Id: TaskList.java,v 1.6 2001/06/01 19:22:55 leonardr Exp $";
@


1.6
log
@Got rid of IssueTrackingRebuild task for good.
@
text
@d65 1
a65 1
    public static final  String versionID = "$Id: TaskList.java,v 1.5 2001/06/01 17:06:32 leonardr Exp $";
d80 2
d84 3
a86 2
                        IssueTrackingRebuildService.getService()
                        .getUnrebuiltProjectInformation());
@


1.5
log
@Added section to TaskList to display currently unfulfilled issue tracking rebuild requests.
@
text
@d65 1
a65 1
    public static final  String versionID = "$Id: TaskList.java,v 1.4 2001/05/23 01:50:12 dlr Exp $";
d68 1
a68 1
     * Put into the context informatino about the current tasks and
@


1.4
log
@Ported Helm from WebMacro to Velocity.
@
text
@a55 1
import org.apache.turbine.util.TurbineException;
d60 2
d63 3
a65 3
import org.tigris.helm.om.Task;
public class TaskList extends HelmServlet {
    public static final  String versionID = "$Id: TaskList.java,v 1.3 2001/03/07 01:53:21 lucas Exp $";
d68 4
a71 2
     * Put the current tasks into the context. Tasks are not accessible from
     * business objects, so we have to do this explicitly.
d78 2
a79 1
        try {
d81 6
a86 1
        } catch (Exception e) {
@


1.3
log
@Corrected regex madness for Torque upgrade.  -dlr
@
text
@d52 1
a52 1
import org.webmacro.servlet.*;
d55 2
d64 1
a64 1
    public static final  String versionID = "$Id: TaskList.java,v 1.2 2001/02/21 03:02:22 edk Exp $";
d70 2
a71 2
    protected String processRequest (Connection connection, WebContext context)
	throws HandlerException, RedirectException
d73 1
a73 1
	String templateName = super.processRequest(connection, context);
d79 1
a79 1
            throw new HandlerException(e.getMessage());
@


1.3.6.1
log
@Ported minimal cluster functionality so that I could also port IssueTrackingRebuildService, which builds on it.
@
text
@d59 1
a59 1
import org.tigris.helm.tool.task.IssueTrackingRebuildService;
d61 2
a62 4

public class TaskList extends HelmServlet 
{
    public static final  String versionID = "$Id: TaskList.java,v 1.3 2001/03/07 01:53:21 lucas Exp $";
d73 1
a73 2
        try 
        {
d75 1
a75 6
            context.put("unrebuiltProjects", 
                        IssueTrackingRebuildService.getService()
                        .getUnrebuiltProjectInformation());
        } 
        catch (Exception e) 
        {
@


1.3.6.2
log
@Ported over observation of persistent issue tracking rebuild failures.
@
text
@d64 1
a64 1
    public static final  String versionID = "$Id: TaskList.java,v 1.3.6.1 2001/06/01 19:18:07 leonardr Exp $";
a76 2
            IssueTrackingRebuildService service = 
                IssueTrackingRebuildService.getService();
d79 2
a80 2
                        service.getUnrebuiltProjectInformation());            
            context.put("failures", service.getFailures());
@


1.2
log
@adding files from the branch to the head
@
text
@a60 1

d62 1
a62 1
    public static final  String versionID = "$Id: TaskList.java,v 1.1.1.1 2001/02/21 00:32:37 dlr Exp $";
@


1.1
log
@file TaskList.java was initially added on branch HELM_PEER_PORT_BRANCH.
@
text
@d1 83
@


1.1.1.1
log
@Replacing the HEAD with the HELM_PEER_PORT_BRANCH.
@
text
@a0 83
/* ================================================================
 * Copyright (c) 2000-2001 CollabNet.  All rights reserved.
 * 
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are
 * met:
 * 
 * 1. Redistributions of source code must retain the above copyright
 * notice, this list of conditions and the following disclaimer.
 * 
 * 2. Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * 
 * 3. The end-user documentation included with the redistribution, if
 * any, must include the following acknowlegement: "This product includes
 * software developed by CollabNet (http://www.collab.net/)."
 * Alternately, this acknowlegement may appear in the software itself, if
 * and wherever such third-party acknowlegements normally appear.
 * 
 * 4. The hosted project names must not be used to endorse or promote
 * products derived from this software without prior written
 * permission. For written permission, please contact info@@collab.net.
 * 
 * 5. Products derived from this software may not use the "Tigris" name
 * nor may "Tigris" appear in their names without prior written
 * permission of CollabNet.
 * 
 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
 * IN NO EVENT SHALL COLLABNET OR ITS CONTRIBUTORS BE LIABLE FOR ANY
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
 * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
 * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 *
 * ====================================================================
 * 
 * This software consists of voluntary contributions made by many
 * individuals on behalf of CollabNet.
 */

package org.tigris.helm.host;

import java.util.*;
import java.sql.*;

import org.webmacro.servlet.*;

import org.apache.turbine.util.Log;

import org.joist.security.RedirectException;

import org.tigris.helm.security.HelmServlet;

import org.tigris.helm.om.Task;

public class TaskList extends HelmServlet {
    public static final  String versionID = "$Id: TaskList.java,v 1.1.2.2 2001/02/15 20:50:37 leonardr Exp $";

    /**
     * Put the current tasks into the context. Tasks are not accessible from
     * business objects, so we have to do this explicitly.
     */
    protected String processRequest (Connection connection, WebContext context)
	throws HandlerException, RedirectException
    {
	String templateName = super.processRequest(connection, context);
        List tasks = null;
        try {
            context.put("tasks", Task.getTasks());
        } catch (Exception e) {
            Log.error("Exception thrown in TaskList", e);
            throw new HandlerException(e.getMessage());
        }
        return templateName;
    }
  
} /* end class TaskList */
@


1.1.2.1
log
@Ported StaticUtils and TaskList, moving them into the host package.
@
text
@a0 83
/* ================================================================
 * Copyright (c) 2001 CollabNet.  All rights reserved.
 * 
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are
 * met:
 * 
 * 1. Redistributions of source code must retain the above copyright
 * notice, this list of conditions and the following disclaimer.
 * 
 * 2. Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * 
 * 3. The end-user documentation included with the redistribution, if
 * any, must include the following acknowlegement: "This product includes
 * software developed by CollabNet (http://www.collab.net/)."
 * Alternately, this acknowlegement may appear in the software itself, if
 * and wherever such third-party acknowlegements normally appear.
 * 
 * 4. The hosted project names must not be used to endorse or promote
 * products derived from this software without prior written
 * permission. For written permission, please contact info@@collab.net.
 * 
 * 5. Products derived from this software may not use the "Tigris" name
 * nor may "Tigris" appear in their names without prior written
 * permission of CollabNet.
 * 
 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
 * IN NO EVENT SHALL COLLABNET OR ITS CONTRIBUTORS BE LIABLE FOR ANY
 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
 * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
 * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 *
 * ====================================================================
 * 
 * This software consists of voluntary contributions made by many
 * individuals on behalf of CollabNet.
 */

package org.tigris.helm.host;

import java.util.*;
import java.sql.*;

import org.webmacro.servlet.*;

import org.apache.turbine.util.Log;

import org.joist.security.RedirectException;

import org.tigris.helm.security.HelmServlet;

import org.tigris.helm.om.Task;

public class TaskList extends HelmServlet {
    public static final  String versionID = "$Id: TaskList.java,v 1.1.2.1 2001/02/05 14:55:20 leonardr Exp $";

    /**
     * Put the current tasks into the context. Tasks are not accessible from
     * business objects, so we have to do this explicitly.
     */
    protected String processRequest (Connection connection, WebContext context)
	throws HandlerException, RedirectException
    {
	String templateName = super.processRequest(connection, context);
        List tasks = null;
        try {
            context.put("tasks", Task.getTasks());
        } catch (Exception e) {
            Log.error("Exception thrown in TaskList", e);
            throw new HandlerException(e.getMessage());
        }
        return templateName;
    }
  
} /* end class TaskList */
@


1.1.2.2
log
@Normalized copyright dates.
@
text
@d2 1
a2 1
 * Copyright (c) 2000-2001 CollabNet.  All rights reserved.
d63 1
a63 1
    public static final  String versionID = "$Id: TaskList.java,v 1.1.2.1 2001/02/15 17:52:33 leonardr Exp $";
@


