For branches/2.0, is there some reason the Tomcat stats are still disabled in TomcatContainer.java?

    public boolean isStatisticsProvider() {
        return false; // todo: return true once stats are integrated
    }


-Donald

Anita Kulshreshtha wrote:
FYI: This is the relevant change:
+    public boolean isStatisticsProvider() {
+        return true;
+    }

Thanks
Anita

--- [EMAIL PROTECTED] wrote:

Author: akulshreshtha
Date: Mon Jul 30 13:19:14 2007
New Revision: 561104

URL: http://svn.apache.org/viewvc?view=rev&rev=561104
Log:
   During Recent restructuring of tomcat connetors statisticsProvider
attribute got lost. Reenable this attribute for HTTPConnectors

Modified:
geronimo/server/trunk/modules/geronimo-tomcat6/src/main/java/org/apache/geronimo/tomcat/connector/BaseHttp11ConnectorGBean.java
Modified:

geronimo/server/trunk/modules/geronimo-tomcat6/src/main/java/org/apache/geronimo/tomcat/connector/BaseHttp11ConnectorGBean.java
URL:

http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-tomcat6/src/main/java/org/apache/geronimo/tomcat/connector/BaseHttp11ConnectorGBean.java?view=diff&rev=561104&r1=561103&r2=561104
==============================================================================
---

geronimo/server/trunk/modules/geronimo-tomcat6/src/main/java/org/apache/geronimo/tomcat/connector/BaseHttp11ConnectorGBean.java
(original)
+++

geronimo/server/trunk/modules/geronimo-tomcat6/src/main/java/org/apache/geronimo/tomcat/connector/BaseHttp11ConnectorGBean.java
Mon Jul 30 13:19:14 2007
@@ -1,409 +1,413 @@
-/*
- * 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.geronimo.tomcat.connector;
-
-import java.net.InetAddress;
-import java.net.InetSocketAddress;
-import java.net.UnknownHostException;
-import java.util.Map;
-
-import javax.management.j2ee.statistics.Stats;
-import javax.net.ssl.KeyManagerFactory;
-
-import org.apache.geronimo.gbean.GBeanInfo;
-import org.apache.geronimo.gbean.GBeanInfoBuilder;
-import org.apache.geronimo.management.StatisticsProvider;
-import org.apache.geronimo.system.serverinfo.ServerInfo;
-import org.apache.geronimo.tomcat.TomcatContainer;
-import org.apache.geronimo.tomcat.stats.ConnectorStats;
-
-public abstract class BaseHttp11ConnectorGBean extends
ConnectorGBean implements BaseHttp11Protocol, StatisticsProvider {
-
-    protected String connectHost;
- - // JSR77 stats
-    private ConnectorStats connStatsProvider = new ConnectorStats();
-
-    private boolean reset = true;
-
-    public BaseHttp11ConnectorGBean(String name, Map initParams,
String tomcatProtocol, String address, int port, TomcatContainer
container, ServerInfo serverInfo) throws Exception {
-        super(name, initParams, tomcatProtocol, container,
serverInfo);
-
-        // Default the host to listen on all address is one was not
specified
-        if (address == null) {
-            address = "0.0.0.0";
-        }
-
-        // Must have a port
-        if (port == 0) {
-            throw new IllegalArgumentException("Must declare a
port.");
-        }
-
-        connector.setAttribute("address", address);
-        connector.setPort(port);
-
-    }
- - protected void initProtocol() {} - - public String getConnectUrl() {
-        if(connectHost == null) {
-            String host = getAddress();
-            if(host == null || host.equals("0.0.0.0") ||
host.equals("0:0:0:0:0:0:0:1")) {
-                InetAddress address = null;
-                try {
-                    address = InetAddress.getLocalHost();
-                } catch (UnknownHostException e) {
-                    host = "unknown-host";
-                }
-                if(address != null) {
-                    host = address.getCanonicalHostName();
-                    if(host == null || host.equals("")) {
-                        host = address.getHostAddress();
-                    }
-                }
-            }
- // this host address could be in IPv6 format, - // which means we need to wrap it in brackets
-            if (host.indexOf(":") >= 0) {
- host = "[" + host + "]"; - }
-            connectHost = host;
-        }
-        return
getScheme().toLowerCase()+"://"+connectHost+(getPort() ==
getDefaultPort() ? "" : ":"+getPort());
-    }
- - public abstract int getDefaultPort();
-
-
-    // Generic HTTP
-    public int getAcceptCount() {
-        Object value = connector.getAttribute("acceptCount");
-        return value == null ? 10 :
Integer.parseInt(value.toString());
-    }
-
-    public String getAddress() {
-        Object value = connector.getAttribute("address");
-        if (value == null) {
-            return "0.0.0.0";
-        } else if (value instanceof InetAddress) {
-            return ((InetAddress) value).getHostAddress();
-        } else
-            return value.toString();
-    }
-
-    public int getBufferSize() {
-        Object value = connector.getAttribute("bufferSize");
-        return value == null ? 2048 :
Integer.parseInt(value.toString());
-    }
-
-    public String getCompressableMimeType() {
-        return (String)
connector.getAttribute("compressableMimeType");
-    }
-
-    public String getCompression() {
-        return (String) connector.getAttribute("compression");
-    }
-
-    public int getConnectionLinger() {
-        Object value = connector.getAttribute("connectionLinger");
-        return value == null ? -1 :
Integer.parseInt(value.toString());
-    }
-
-    public int getConnectionTimeout() {
-        Object value = connector.getAttribute("connectionTimeout");
-        return value == null ? 60000 :
Integer.parseInt(value.toString());
-    }
-
-    public boolean getDisableUploadTimeout() {
-        Object value =
connector.getAttribute("disableUploadTimeout");
-        return value == null ? true : new
Boolean(value.toString()).booleanValue();
-    }
-
-    public String getExecutor() {
-        return (String) connector.getAttribute("Executor");
-    }
- - public String getHost() {
-        return getAddress();
-    }
- - public InetSocketAddress getListenAddress() {
-        return new InetSocketAddress(getHost(), getPort());
-    }
-
-    public int getKeepAliveTimeout() {
-        Object value = connector.getAttribute("keepAliveTimeout");
-        return value == null ? getConnectionTimeout() :
Integer.parseInt(value.toString());
-    }
-
-    public int getMaxHttpHeaderSize() {
-        Object value = connector.getAttribute("maxHttpHeaderSize");
-        return value == null ? 4096 :
Integer.parseInt(value.toString());

=== message truncated ===



____________________________________________________________________________________
Get the Yahoo! toolbar and be alerted to new email wherever you're surfing.
http://new.toolbar.yahoo.com/toolbar/features/mail/index.php


Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

Reply via email to