[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Condor-users] dynamic port number



Hello,
I was trying to get the port number by querying the condor_collector via SOAP.
I am trying to use the following code:

Collector collector = new Collector(collectorLocation);

ClassAdStructAttr[][] collectorInfo =

ccl.queryScheddAds("HasSOAPInterface=?=TRUE");

for (int j=0; j < collectorInfo[0].length; j++)

{

ClassAdStructAttr casAttr = collectorInfo[0][j];

if(casAttr.getName().equals("ScheddIpAddr"))

{

scheddLocationStr = scheddLocationStr=casAttr.getValue();

}

}
 
But I do not have the Collector class? Is there any other way to enquire about the port via SOAP?
Thanks,
D


--- On Thu, 3/26/09, Todd Tannenbaum <tannenba@xxxxxxxxxxx> wrote:

From: Todd Tannenbaum <tannenba@xxxxxxxxxxx>
Subject: Re: [Condor-users] dynamic port number
To: "Condor-Users Mail List" <condor-users@xxxxxxxxxxx>
Date: Thursday, March 26, 2009, 12:18 PM

Debolina Ray wrote:
>
> Hi,
> The port number  of the host keeps changing as it it allocate
> dynamically. IS it possible to get information about the current port
> number using BirdBath and Axis?
> Thanks
> D
>

You mean the port of the schedd service, correct?

1) You can get the port of the schedd service by querying the collector
via SOAP, using the methods in condor_collector.wsdl, to retrieve the
ClassAd representing the schedd you want to talk to.  One of the
attributes in this classad will contain the IP address and port of the
schedd.  This is the equal of doing "condor_status -schedd -l" for a
given schedd.

2) Or, alternatively, in your condor_config can specify
     SCHEDD_ADDRESS_FILE = /some/path/to/some/file
if it is not specified already.  If your java client is running on the
same machine as the schedd (2-tier), then you could just look in the
file specified by SCHEDD_ADDRESS_FILE to discover the port.

3) Or alternatively, you can run the schedd on a well-known port by
specifying
   SCHEDD_ARGS = -p XXX
in the condor_config file where XXX is the port you want the schedd to
use (instead of the default of the schedd picking a dynamic port).

regards,
Todd

p.s. I just entered a ticket to add documentation to the Condor Manual
about using the methods in condor_collector.wsdl.  :)

_______________________________________________
Condor-users mailing list
To unsubscribe, send a message to condor-users-request@xxxxxxxxxxx with a
subject: Unsubscribe
You can also unsubscribe by visiting
https://lists.cs.wisc.edu/mailman/listinfo/condor-users

The archives can be found at:
https://lists.cs.wisc.edu/archive/condor-users/