ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/i-scream/projects/cms/source/server/uk/org/iscream/cms/server/clientinterface/TCPControlHandler.java
(Generate patch)

Comparing projects/cms/source/server/uk/org/iscream/cms/server/clientinterface/TCPControlHandler.java (file contents):
Revision 1.14 by tdb, Mon Feb 12 02:23:53 2001 UTC vs.
Revision 1.15 by tdb, Wed Feb 21 19:11:28 2001 UTC

# Line 47 | Line 47 | class TCPControlHandler extends Thread {
47       *
48       * @param socket The Socket connected to the new Client
49       * @param packetSorter A reference to the PacketSorter in the component
50 +     * @param queueMonitorInterval The interval at which to monitor our Queue
51       */
52 <    public TCPControlHandler(Socket socket, PacketSorter packetSorter) throws IOException {
52 >    public TCPControlHandler(Socket socket, PacketSorter packetSorter, int queueMonitorInterval) throws IOException {
53          _socket = socket;
54          _packetSorter = packetSorter;
55 +        _queueMonitorInterval = queueMonitorInterval;
56          // setup the reader & writer
57          _socketIn = new BufferedReader(new InputStreamReader(_socket.getInputStream()));
58          _socketOut = new PrintWriter(_socket.getOutputStream(), true);
# Line 141 | Line 143 | class TCPControlHandler extends Thread {
143                          // register the DataHandler's queue, giving the host list
144                          _packetSorter.register(dh.getQueue(), _hostList);
145                          // startup a monitor on the DataHandler's queue, every minute
146 <                        dh.getQueue().startMonitor(60*1000, _packetSorter.getQueue(), _name);
146 >                        String queueName = _name + " TCPHandler:"+_socket.getInetAddress().getHostName();
147 >                        dh.getQueue().startMonitor(_queueMonitorInterval*1000, _packetSorter.getQueue(), queueName);
148                          // start up the DataHandler
149                          dh.start();
150                          // Hold a reference to the DataHandler, so we can stop it later
# Line 332 | Line 335 | class TCPControlHandler extends Thread {
335       * The host list the Client has requested
336       */
337      private String _hostList;
338 +    
339 +    /**
340 +     * The interval at which to monitor our Queue
341 +     */
342 +    private int _queueMonitorInterval;
343      
344   //---STATIC ATTRIBUTES---
345  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines