-
From: Dakota Jack [mailto:[EMAIL PROTECTED]
Sent: Friday, January 28, 2005 9:49 AM
To: Struts Users Mailing List
Cc: Martin Wegner
Subject: Re: PlugIn and the base URL
On Fri, 28 Jan 2005 08:02:46 -0600, David Suarez
<[EMAIL PROTECTED]> wrote:
> Just the same, it's
> likely not a
Just so everyone is knowingly on the same page, the basics are at
http://webserver.cpg.com/ws/3.4/.
Jack
--
--
"You can lead a horse to water but you cannot make it float on its back."
~Dakota Jack~
"You can't wake a person who is pretending to be asleep."
~Nat
On Fri, 28 Jan 2005 11:15:35 -0600, Eddie Bush <[EMAIL PROTECTED]> wrote:
> See Frank's post on the web service. He expressed it more eloquently
> than I did.
But, Frank and I are in agreement. If you are not talking about the
Web, then you are saying that the solution is not a solution to an
On Fri, 28 Jan 2005 09:03:07 -0800 (PST), [EMAIL PROTECTED]
<[EMAIL PROTECTED]> wrote:
> While I absolutely acknowledge the cleverness of this solution, it's not one
> I would personally employ. Making a server application dependent on another
> server for startup configuration strikes me as qu
Lo, Eddie,
See infra:
> How many different host/port combinations are the applications you use
> this strategy in deployed to?
Thousands.
> In the environment I "live", apps deploy on multiple servers (always
> 2+ for high availability), and are likely to be accessed by a
> different (non-st
While I absolutely acknowledge the cleverness of this solution, it's not one I
would personally employ. Making a server application dependent on another
server for startup configuration strikes me as quite a hack (albeit a clever
one!)
> It in fact does make sense to assume that a web service
On Fri, 28 Jan 2005 08:21:40 -0800, Dakota Jack <[EMAIL PROTECTED]> wrote:
> I am not sure at this point David S. what you have tried, but I can
> assure you that your conclusion that "configuration is the only way in
> this scenario above" is incorrect, because I do this all the time with
> no dif
Kishore,
This turns out to be the exact solution that I require. I just extended
AxisServlet and scrape off the "requestURL" which is the URL that was used
to reach the WS. That did the trick.
And again, this illustrates what I consider a flaw in the Axis
implementation. If you look through
On Fri, 28 Jan 2005 08:02:46 -0600, David Suarez
<[EMAIL PROTECTED]> wrote:
> I think the answer here would be configuration is the only way in the
> scenario above. The question is, do you really need the call backs for
> what you're really doing? In the licensing example above, you likely
> on
On Fri, 28 Jan 2005 08:02:46 -0600, David Suarez
<[EMAIL PROTECTED]> wrote:
> Just the same, it's
> likely not a problem for your server to figure out where the request
> came from if that is needed for the protocol (the receiver of the
> initial message). It's the callback that you have a proble
..djsuaerz
-Original Message-
From: Martin Wegner [mailto:[EMAIL PROTECTED]
Sent: Thursday, January 27, 2005 11:17 PM
To: Struts Users Mailing List
Subject: RE: PlugIn and the base URL
David,
Also, as I said early the Axis architecture is such that it does not
provide any of the
On Thu, 27 Jan 2005 22:46:20 -0800 (PST), Martin Wegner
<[EMAIL PROTECTED]> wrote:
> Jack,
>
> Your solution would work. But I don't have the ability to deploy a
> foreign machine to do the echo.
>
> Someone just wrote in about a Struts filter on "/axis/" which may actually
> do the trick. I n
EMAIL PROTECTED]> wrote:
> -- Forwarded message --
> From: Dakota Jack <[EMAIL PROTECTED]>
> Date: Thu, 27 Jan 2005 22:24:00 -0800
> Subject: Re: PlugIn and the base URL
>
> To: Martin Wegner <[EMAIL PROTECTED]>
>
>
> On Thu, 27 Jan 2005 21:25:11
On Thu, 27 Jan 2005 21:17:07 -0800 (PST), Martin Wegner
<[EMAIL PROTECTED]> wrote:
> David,
>
> Also, as I said early the Axis architecture is such that it does not
> provide any of the information related to the HTTP layer beneath SOAP.
> The only think you know is that your dispatcher gets calle
David,
Also, as I said early the Axis architecture is such that it does not
provide any of the information related to the HTTP layer beneath SOAP.
The only think you know is that your dispatcher gets called. So my
problem may be considered a limitation in Axis.
--Marty
> Martin, since you see
David,
As I said in a previous message my Struts app has an Axis-based SOAP
service. The business logic behind the WS needs to know a/the URL that
can be used to access the WS. This is a requirement of the WS. This part
can't be changed. It is part of the protocol of the answer sent back by
th
I think it is important to remember that the URL is a "detail" that is
wholly independent of the application or the machine. This is an
external device for the benefit of human beings whom do not do as well
with numbers as with letters in the memonic department. Therefore, I
don't think that this
David,
I do not mean to speak for Martin, but my guess is that he might want
to send SOAP prior to a request. He might even have to send and to
receive SOAP prior to a request.I know that this is why I often need
to do this sort of thing.
Jack
On Thu, 27 Jan 2005 18:50:08 -0500, David G. Fried
>>Martin Wegner wrote:
>>In have a Struts PlugIn that needs to determine the
>> URL for the containing web application
>> (http://localhost:8080/BlahBlahBlah/).
Martin, since you seem firm on this issue, can we/I ask WHY you need this
information in your webapp during initialization? What are you
; Regards...djsuarez
>
> -Original Message-
> From: Martin Wegner [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, January 26, 2005 11:51 PM
> To: Struts Users Mailing List; Dakota Jack
> Subject: Re: PlugIn and the base URL
>
>
> Thanks to everybody who contr
ssage-
From: David Suarez
Sent: Thursday, January 27, 2005 8:12 AM
To: 'Martin Wegner'; Struts Users Mailing List; Dakota Jack
Subject: RE: PlugIn and the base URL
The light came on when "the ip address is sufficient" came up. I had
context paths and ports in my head.
ez
-Original Message-
From: Martin Wegner [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 26, 2005 11:51 PM
To: Struts Users Mailing List; Dakota Jack
Subject: Re: PlugIn and the base URL
Thanks to everybody who contributed to this topic. There appears to be
no
foolproof solution to the
inal Message-
From: Craig McClanahan [mailto:[EMAIL PROTECTED]
Sent: Thursday, January 27, 2005 1:06 AM
To: Struts Users Mailing List
Subject: Re: PlugIn and the base URL
On Wed, 26 Jan 2005 13:32:50 -0500, David G. Friedman
<[EMAIL PROTECTED]> wrote:
> A Devil's Advocate says:
&g
On Wed, 26 Jan 2005 13:32:50 -0500, David G. Friedman
<[EMAIL PROTECTED]> wrote:
> A Devil's Advocate says:
>
> I agree with the theory that the webapp Context name within the application
> server "/myapp" should be available to the servlet but not the
> host/port/etc.
The assumption that a parti
requirements (ie. A Filter that would instantiate the objects
> you
> > > > need to populate on the first request? A base action that lazy
> loads
> > > > your config stuff?)
> > > >
> > > > Just a thought...djsuarez
> > > >
> &
> >
> > > Just a thought...djsuarez
> > >
> > > -Original Message-
> > > From: Martin Wegner [mailto:[EMAIL PROTECTED]
> > > Sent: Wednesday, January 26, 2005 12:18 AM
> > > To: Struts Users Mailing List; Dakota Jack
> > >
ot as long as you saved the URL in a file so future
> > restarts/reboots
> > would not need that manual (first-time) URL ever again.
> >
> > Regards,
> > David
> >
> > -Original Message-
> > From: Martin Wegner [mailto:[EMAIL PROTECTED]
> >
Even if you did need to know it, why not get it at the first request
and then cache it?
Jack
On Wed, 26 Jan 2005 16:59:17 +0100, Cedric Levieux
<[EMAIL PROTECTED]> wrote:
> > My Struts app contains an Axis-based SOAP service. The Struts app
> > initializes the call dispatcher for the SOAP servi
ernative depending on
> > >> your requirements (ie. A Filter that would instantiate the objects
> > you
> > >> need to populate on the first request? A base action that lazy loads
> > >> your config stuff?)
> > >>
> > >> Just a tho
artin Wegner [mailto:[EMAIL PROTECTED]
> > Sent: Wednesday, January 26, 2005 12:18 AM
> > To: Struts Users Mailing List; Dakota Jack
> > Subject: Re: PlugIn and the base URL
> >
> >
> > I am looking for the:
> >
> > http://blahblahblah.com
aith for conditions a) and b) above.
How does that idea work for you?
Regards,
David, happy at finding a conditional answer that works on his one-tested
Java server.
-Original Message-
From: Martin Wegner [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 26, 2005 3:57 PM
To: Struts Users
at manual (first-time) URL ever again.
Regards,
David
-Original Message-
From: Martin Wegner [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 26, 2005 3:39 PM
To: Struts Users Mailing List
Subject: RE: PlugIn and the base URL
Yes, this is the scenario. The web container could change, the
s long as you saved the URL in a file so future
> restarts/reboots
> would not need that manual (first-time) URL ever again.
>
> Regards,
> David
>
> -Original Message-
> From: Martin Wegner [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, January 26, 2005 3:39 PM
&g
time) URL ever again.
Regards,
David
-Original Message-
From: Martin Wegner [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 26, 2005 3:39 PM
To: Struts Users Mailing List
Subject: RE: PlugIn and the base URL
Yes, this is the scenario. The web container could change, the port
number coul
To localhost but with what
> > context? See where my snow-covered (yep, another Boston,MA,USA storm)
> > thinking is going with this?
> >
> > -David, having a 'bald' moment
> >
> > -----Original Message-----
> > From: [EMAIL PROTECTED] [mailto
ings as well, such as
> record the activation time (if you need it for billing) or fire off a
> message to a licensing or billing server (for hosted apps, etc).
>
> Wiebe de Jong
>
>
> -Original Message-
> From: David G. Friedman [mailto:[EMAIL PROTECTED]
> Se
> thinking is going with this?
>
> -David, having a 'bald' moment
>
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, January 26, 2005 2:13 PM
> To: user@struts.apache.org
> Subject: RE: PlugIn and the base URL
storm)
thinking is going with this?
-David, having a 'bald' moment
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 26, 2005 2:13 PM
To: user@struts.apache.org
Subject: RE: PlugIn and the base URL
I would personally couple this with th
#x27;s class instance data). If the file exists, the action
> could politely return a page explaining the requested function is not
> available (to prevent someone from potentially screwing things up by
> running
> that action again).
>
> Regards,
> David, the devil's advoca
ruts Users Mailing List'
Subject: RE: PlugIn and the base URL
Hey David, that is a great idea.
Let me build on it a bit...
When the .war file is deployed, the baseURL property will be blank.
When the application starts up, it will check this property. If the property
is blank, the app will
riedman [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 26, 2005 10:33 AM
To: Struts Users Mailing List
Subject: RE: PlugIn and the base URL
A Devil's Advocate says:
I agree with the theory that the webapp Context name within the application
server "/myapp" should be available to th
ocate today.
-Original Message-
From: Martin Wegner [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 26, 2005 12:53 PM
To: Struts Users Mailing List
Subject: RE: PlugIn and the base URL
Agreed. That approach works more often than not. Except in this case.
The client of the WS does indeed use
Agreed. That approach works more often than not. Except in this case.
The client of the WS does indeed use the URL that is sent back. That is
part of the overal protocol. So it has to be a valid URL that reaches the
WS inside of my Struts app.
One could argue that the real problem is within
>
> The WS response has to contain the URL that was used to
> access the WS.
> This is a requirement of the XML Schema that defines the WS response
> payload. I have no control over this.
>
I know this might be stupid, but whenever I see an odd requirement like this my
first experiment is to
Cedric,
No doubt it is confusing. I admit it is an odd requirement.
The WS response has to contain the URL that was used to access the WS.
This is a requirement of the XML Schema that defines the WS response
payload. I have no control over this.
So when the WS call comes in the Axis-based cal
Message -
From: "Martin Wegner" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List"
Sent: Wednesday, January 26, 2005 3:27 PM
Subject: Re: PlugIn and the base URL
> Niall,
>
> That would. Except it would require our customer to copy the WAR file to
> the w
> My Struts app contains an Axis-based SOAP service. The Struts app
> initializes the call dispatcher for the SOAP service. This dispatcher
> needs to know the URL of itself. This is a requirement of the semantics
> of the SOAP service (outside of my control). So a Listener or a Plug In
> appea
o have the location
in config as someone else mentioned?
Regards...djsuarez
-Original Message-
From: Martin Wegner [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 26, 2005 9:12 AM
To: Struts Users Mailing List
Subject: RE: PlugIn and the base URL
David,
My Struts app contains an A
> that initializes your SOAP service?
>>
>>
>> > value="http://blahblahblah.com:8080/AppName/"/>
>>
>>
>> Niall
>>
>> - Original Message -----
>> From: "Martin Wegner" <[EMAIL PROTECTED]>
>> To
table alternative depending
> on
> > > your requirements (ie. A Filter that would instantiate the objects
> you
> > > need to populate on the first request? A base action that lazy
> loads
> > > your config stuff?)
> > >
> > > Just a thought...djsua
sers Mailing List"
Sent: Wednesday, January 26, 2005 3:12 PM
Subject: RE: PlugIn and the base URL
> David,
>
> My Struts app contains an Axis-based SOAP service. The Struts app
> initializes the call dispatcher for the SOAP service. This dispatcher
> needs to know the URL
t; >> need to populate on the first request? A base action that lazy loads
> >> your config stuff?)
> >>
> >> Just a thought...djsuarez
> >>
> >> -Original Message-
> >> From: Martin Wegner [mailto:[EMAIL PROTECTED]
> >> S
From: Martin Wegner [mailto:[EMAIL PROTECTED]
>> Sent: Wednesday, January 26, 2005 12:18 AM
>> To: Struts Users Mailing List; Dakota Jack
>> Subject: Re: PlugIn and the base URL
>>
>>
>> I am looking for the:
>>
>> http://blahblahblah.co
ilto:[EMAIL PROTECTED]
> Sent: Wednesday, January 26, 2005 12:18 AM
> To: Struts Users Mailing List; Dakota Jack
> Subject: Re: PlugIn and the base URL
>
>
> I am looking for the:
>
> http://blahblahblah.com:8080/AppName/
>
> As Craig said I can get that if I have
I need to find the URL of my web app at start up. I need it as soon as
possible in the boot process. So Listerners and Plug Ins are the only two
ways I know of that allow me to hook into the startup of the app. Is
there another mechanism available?
--Marty
--- Larry Meadors <[EMAIL PROTECTED
stuff?)
Just a thought...djsuarez
-Original Message-
From: Martin Wegner [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 26, 2005 12:18 AM
To: Struts Users Mailing List; Dakota Jack
Subject: Re: PlugIn and the base URL
I am looking for the:
http://blahblahblah.com:8080/AppName
why does it have to be a plugin?
On Tue, 25 Jan 2005 22:18:20 -0800 (PST), Martin Wegner
<[EMAIL PROTECTED]> wrote:
>
> I am looking for the:
>
> http://blahblahblah.com:8080/AppName/
>
> As Craig said I can get that if I have a Request object. But from a
> PlugIn I don't have that. I ca
I am looking for the:
http://blahblahblah.com:8080/AppName/
As Craig said I can get that if I have a Request object. But from a
PlugIn I don't have that. I can think of some ugly hacks but nothing
clean.
--Marty
--- Dakota Jack <[EMAIL PROTECTED]> wrote:
> Do you want the URL or the In
Do you want the URL or the Internet Protocol address? I have some
ideas on the latter.
Jack
On Tue, 25 Jan 2005 21:05:30 -0800 (PST), Martin Wegner
<[EMAIL PROTECTED]> wrote:
> Jack,
>
> That tells me where the JAR files are stored which is cool. But what I am
> looking for a valid URL (of wh
On Tue, 25 Jan 2005 21:05:30 -0800 (PST), Martin Wegner
<[EMAIL PROTECTED]> wrote:
> Jack,
>
> That tells me where the JAR files are stored which is cool. But what I am
> looking for a valid URL (of which there may be many) to access my given
> web application. This info has to come from the con
Jack,
That tells me where the JAR files are stored which is cool. But what I am
looking for a valid URL (of which there may be many) to access my given
web application. This info has to come from the container which may be
the problem. I don't see anything in the container standard which
provid
That is actually useful, but I don't think it's what the OP was looking
for... I think he literally wants the complete URL to the current
webapp's root. That's what I was looking for way back when too.
--
Frank W. Zammetti
Founder and Chief Software Architect
Omnytex Technologies
http://www.omn
Not sure what you want. Does this help?
package whatever;
import java.io.File;
import java.net.URL;
public final class Classpath {
public static final String SLASH= File.separator;
public static final String HERE =
Classpath.class.getClassLoader().getResource("whatever" + SL
As far as I can tell the attributes offer no insight. I have yet to find
a way to get to the container from within a PlugIn. But I will keep
looking. Using an initParam is not an option in this application.
--Marty
--- "Frank W. Zammetti" <[EMAIL PROTECTED]> wrote:
> The OP was looking for
The OP was looking for a way to construct the entire path. I too got as
far as ServletContext, but I'm not sure what in it would give you that,
or even all the pieces to constuct it... Maybe getAttribute()? I'm not
sure what it will return, although you can use getAttributeNames() to
see. Th
On Tue, 25 Jan 2005 18:37:29 -0500, Frank W. Zammetti
<[EMAIL PROTECTED]> wrote:
> I seem to remember trying to solve this problem myself and coming to the
> conclusion that there was no way to do it independent of a request. I
> wound up just sticking it in my application config file that gets re
I'm not entirely sure, but I think Struts itself has some code that
goes through some length to get information like this. Could be in
the Struts ActionServlet object. I don't have time to check right
now, though.
On Tue, 25 Jan 2005 18:37:29 -0500, Frank W. Zammetti
<[EMAIL PROTECTED]> wrote:
>
I seem to remember trying to solve this problem myself and coming to the
conclusion that there was no way to do it independent of a request. I
wound up just sticking it in my application config file that gets read
in the plugin anyway. Can anyone prove me wrong? :)
--
Frank W. Zammetti
Founde
68 matches
Mail list logo