void statsCloseConnection(long duration,int requests)
    {
        synchronized(_statsLock)
        {
            _connections++;
            _connectionsOpen--;
            _connectionsDurationTotal+=duration;
            if (_connectionsOpen<0)
                _connectionsOpen=0;
            if (_connectionsOpen<_connectionsOpenMin)
                _connectionsOpenMin=_connectionsOpen;
            if (_connectionsDurationMin==0 || duration<_connectionsDurationMin)
                _connectionsDurationMin=duration;
            if (duration>_connectionsDurationMax)
                _connectionsDurationMax=duration;
            if (_connectionsRequestsMin==0 || requests<_connectionsRequestsMin)
                _connectionsRequestsMin=requests;
            if (requests>_connectionsRequestsMax)
                _connectionsRequestsMax=requests;
        }
    }
void statsCloseConnection ( long duration , int requests ) { synchronized ( _statsLock ) { _connections ++ ; _connectionsOpen -- ; _connectionsDurationTotal += duration ; if ( _connectionsOpen < 0 ) _connectionsOpen = 0 ; if ( _connectionsOpen < _connectionsOpenMin ) _connectionsOpenMin = _connectionsOpen ; if ( _connectionsDurationMin == 0 || duration < _connectionsDurationMin ) _connectionsDurationMin = duration ; if ( duration > _connectionsDurationMax ) _connectionsDurationMax = duration ; if ( _connectionsRequestsMin == 0 || requests < _connectionsRequestsMin ) _connectionsRequestsMin = requests ; if ( requests > _connectionsRequestsMax ) _connectionsRequestsMax = requests ; } }
/* ------------------------------------------------------------