Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » calling location/path of war file.(locating my app's war file in the tmp/ folder, from within my running application)
calling location/path of war file. [message #756730] Mon, 14 November 2011 20:39 Go to next message
Missing name Missing name is currently offline Missing name Missing nameFriend
Messages: 36
Registered: November 2011
Member
hey everyone,

I have a unique situation and was wondering if anyone knows if this can even be done and/or and ideas on the topic I may try:
I am runing my web application through a JBOSS server. Upon startup it builds the WAR file and sends it to my jboss-5.1.0.GA\server\default\tmp folder.
my application builds an xml file that i then have to save to the same folder as my WAR file, but the problem is that every time I start my run my app it generates a random folder within the /tmp folder.
In order for me to send my xml to the folder i would have to locate the path of my WAR file from within the application, or i would have to know name of the folder within the /tmp folder that is being dynamically created for the session.


I know this is explained in the worst way so i will try to show you what i mean:

when i run my application the first time it builds my WAR file in this folder:
jboss-5.1.0.GA\server\default\tmp\4e3f35f-87gz9k-guzu43hg-1-guzu98hv-9u

then i close my eclipse out, reopen it and run it again, and this time it saves here:
jboss-5.1.0.GA\server\default\tmp\4e3f35f-87gz9k-guzu43hg-1-guzua866-9v

it generates the random "4e3f35f..." folder with a new name each run, and in order for me to send my xml file there i need to be able to find that folder name and place it within a String from within the running application. If anyone knows how this can be done or has any ideas i am open to tryin anything.

Thanks a lot,

John
Re: calling location/path of war file. [message #756786 is a reply to message #756730] Tue, 15 November 2011 05:38 Go to previous messageGo to next message
Deepak Azad is currently offline Deepak AzadFriend
Messages: 543
Registered: July 2009
Senior Member
> it generates the random "4e3f35f..." folder with a new name each run,
> and in order for me to send my xml file there i need to be able to find
> that folder name and place it within a String from within the running
> application.
If I were to take a wild guess, the folder name could be the session id?

Having said that, this forum is for queries related to Java Development
Tools. Your question is more suited to a JBOSS or a web development forum.

--
Deepak Azad
http://wiki.eclipse.org/JDT/FAQ
Re: calling location/path of war file. [message #756898 is a reply to message #756786] Tue, 15 November 2011 13:20 Go to previous message
Missing name Missing name is currently offline Missing name Missing nameFriend
Messages: 36
Registered: November 2011
Member
ok i will try to repost it there. thanks.
Previous Topic:Creating own shortcut / Saving changes when pressing "Run"
Next Topic:Debugging over web
Goto Forum:
  


Current Time: Sat Apr 20 03:06:43 GMT 2024

Powered by FUDForum. Page generated in 0.03506 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top