/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.jk.status;
import java.io.UnsupportedEncodingException;
import java.net.URLEncoder;
import org.apache.catalina.ant.AbstractCatalinaTask;
import org.apache.tools.ant.BuildException;
/**
* Ant task that implements the /status
command, supported by the
* mod_jk status (1.2.13) application.
*
*
* @author Peter Rossbach
* @version $Revision: 611693 $
* @since 5.5.10
* @deprecated
*/
public class JkStatusUpdateTask extends AbstractCatalinaTask {
/**
* The descriptive information about this implementation.
*/
private static final String info = "org.apache.jk.status.JkStatusUpdateTask/1.1";
private String worker = "lb";
private String workerType = "lb";
private int internalid = 0;
private Integer lbRetries;
private Integer lbRecovertime;
private Boolean lbStickySession = Boolean.TRUE;
private Boolean lbForceSession = Boolean.FALSE;
private Integer workerLoadFactor;
private String workerJvmRoute ;
private int workerDistance = -1;
private String workerRedirect;
private String workerClusterDomain;
private Boolean workerDisabled ;
private Boolean workerStopped ;
private int workerActivation = -1;
private boolean isLBMode = true;
private String workerLb;
/**
* Return descriptive information about this implementation and the
* corresponding version number, in the format
* <description>/<version>
.
*/
public String getInfo() {
return (info);
}
/**
*
*/
public JkStatusUpdateTask() {
super();
setUrl("http://localhost/jkstatus");
}
/**
* @return Returns the workerDistance.
*/
public int getWorkerDistance() {
return workerDistance;
}
/**
* @param workerDistance The workerDistance to set.
*/
public void setWorkerDistance(int workerDistance) {
this.workerDistance = workerDistance;
}
/**
* @return Returns the workerJvmRoute.
*/
public String getWorkerJvmRoute() {
return workerJvmRoute;
}
/**
* @param workerJvmRoute The workerJvmRoute to set.
*/
public void setWorkerJvmRoute(String workerJvmRoute) {
this.workerJvmRoute = workerJvmRoute;
}
/**
* @return Returns the internalid.
*/
public int getInternalid() {
return internalid;
}
/**
* @param internalid
* The internalid to set.
*/
public void setInternalid(int internalid) {
this.internalid = internalid;
}
/**
* @return Returns the lbForceSession.
*/
public Boolean getLbForceSession() {
return lbForceSession;
}
/**
* @param lbForceSession
* The lbForceSession to set.
*/
public void setLbForceSession(Boolean lbForceSession) {
this.lbForceSession = lbForceSession;
}
/**
* @return Returns the lbRecovertime.
*/
public Integer getLbRecovertime() {
return lbRecovertime;
}
/**
* @param lbRecovertime
* The lbRecovertime to set.
*/
public void setLbRecovertime(Integer lbRecovertime) {
this.lbRecovertime = lbRecovertime;
}
/**
* @return Returns the lbRetries.
*/
public Integer getLbRetries() {
return lbRetries;
}
/**
* @param lbRetries
* The lbRetries to set.
*/
public void setLbRetries(Integer lbRetries) {
this.lbRetries = lbRetries;
}
/**
* @return Returns the lbStickySession.
*/
public Boolean getLbStickySession() {
return lbStickySession;
}
/**
* @param lbStickySession
* The lbStickySession to set.
*/
public void setLbStickySession(Boolean lbStickySession) {
this.lbStickySession = lbStickySession;
}
/**
* @return Returns the worker.
*/
public String getWorker() {
return worker;
}
/**
* @param worker
* The worker to set.
*/
public void setWorker(String worker) {
this.worker = worker;
}
/**
* @return Returns the workerType.
*/
public String getWorkerType() {
return workerType;
}
/**
* @param workerType
* The workerType to set.
*/
public void setWorkerType(String workerType) {
this.workerType = workerType;
}
/**
* @return Returns the workerLb.
*/
public String getWorkerLb() {
return workerLb;
}
/**
* @param workerLb
* The workerLb to set.
*/
public void setWorkerLb(String workerLb) {
this.workerLb = workerLb;
}
/**
* @return Returns the workerClusterDomain.
*/
public String getWorkerClusterDomain() {
return workerClusterDomain;
}
/**
* @param workerClusterDomain
* The workerClusterDomain to set.
*/
public void setWorkerClusterDomain(String workerClusterDomain) {
this.workerClusterDomain = workerClusterDomain;
}
/**
* @return Returns the workerDisabled.
*/
public Boolean getWorkerDisabled() {
return workerDisabled;
}
/**
* @param workerDisabled
* The workerDisabled to set.
*/
public void setWorkerDisabled(Boolean workerDisabled) {
this.workerDisabled = workerDisabled;
}
/**
* @return Returns the workerActivation.
*/
public int getWorkerActivation() {
return workerActivation;
}
/**
*