Careful with the Application.host() call. It can rely on the underlying operating system's sense of identity. Therefor its not always a complete domain name, i.e. you'll occasionally get "www" instead of "www.foobar.com".

In addition its returning the name of the computer the WebObjects Application is running on. If you have separate machines for Web server and App server you could be in trouble. The solution I ended up with was to set a property in JavaMonitor specifying the DNS of the main web server.



Date: Fri, 8 Sep 2006 13:33:36 -0400
From: Gilles MATHURIN <[EMAIL PROTECTED]>
Subject: Re: Newbie : Obtain the name of a server in Java
To: Thomas Meyer <[EMAIL PROTECTED]>
Cc: [email protected]
Message-ID: <[EMAIL PROTECTED]>
Content-Type: text/plain; charset=ISO-8859-1; delsp=yes; format=flowed

Thank you Mr Meyer

it's the simpliest answer i obtain along with the DirectAction trick
and because i am a newbie, it is the one i manage to include in my App.
However i will try to implement it in a more complete way by
integrating the various solutions that came along thoses last days.
In orfer to get a method that work with the as many browsers as
possible.
But for now, it fits my needs.

Regards.

GM

Le 8 sept. 06 à 11:23, Thomas Meyer a écrit :

try this.host() in Application.java



------------------------------

_______________________________________________
Webobjects-dev mailing list
[email protected]
http://lists.apple.com/mailman/listinfo/webobjects-dev

End of Webobjects-dev Digest, Vol 3, Issue 646
**********************************************

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to