Ignore:
Timestamp:
08/22/11 12:35:53 (13 years ago)
Author:
gaba
Message:

workspaceprofile options

File:
1 edited

Legend:

Unmodified
Added
Removed
  • MDService2/trunk/MDService2/src/eu/clarin/cmdi/mdservice/action/Pz2ProxyAction.java

    r1488 r1491  
    189189               
    190190                InputStream is = null;
    191                
     191                // TODO param settings
    192192                //init
    193193                setCommand("init");
     
    203203                setSort("relevance");
    204204                setBlock("1");
     205                //TODO timeout  settings
     206                long startMillis = System.currentTimeMillis();
     207                long timeout = 0;
     208                if (this.getWPOption("pazpartimeout") == null){
     209                        timeout = 1000;
     210                } else {
     211                        timeout = Integer.parseInt(this.getWPOption("pazpartimeout"));
     212                }
    205213                while (Integer.parseInt(activeclients) > 0){
    206214                        //activeclients = getDocumentData(this.getSourceStream(), "//show/activeclients");
    207215                        is = this.getSourceStream();
    208216                        activeclients = getDocumentData(is, "//show/activeclients");
    209                        
     217                        Thread.sleep(1000);
     218                        Admin.notifyUser("ActiveClients: " + activeclients, Admin.DEBUG);
     219                        if ((System.currentTimeMillis() - startMillis) > timeout) {
     220                                break;
     221                        }
    210222                }
    211223                is = this.getSourceStream();
Note: See TracChangeset for help on using the changeset viewer.