Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Context root in websphere 6.1

285 views
Skip to first unread message

lthan...@gmail.com

unread,
Aug 6, 2008, 1:48:56 AM8/6/08
to
Dear Techies ,

My requirement is that we have to upload the file (like .txt , .pdf etc ..) . Normally in JBoss , we are creating one folder called "X" under the ROOTWAR , in which folder we are uploading file and while searching the file using the keyword with the help lucene search engine, we are finding the file , location and displaying the filename in jsp , Moreover for user friendly , we are providing href link to the file name like following ,

Test.txt

while click the link the file will display in new window . This is the case in JBoss . (Note : /docs/Test.txt this is from root war )


Our application it will be deployed in was 6.1 also, so where is the context root ?

where i have create the "X" folder to upload the file ? how to get the context root ?

plz help me ..... thanks in advance ....

Regards ,

Thangavel.L

Cranes Software International Limited,

Bangalore , India.

lthan...@gmail.com

unread,
Aug 6, 2008, 1:59:25 AM8/6/08
to

lthan...@gmail.com

unread,
Aug 6, 2008, 2:03:17 AM8/6/08
to
Dear Techies ,

My requirement is that we have to upload the file (like .txt , .pdf etc ..) . Normally in JBoss , we are creating one folder called "X" under the ROOTWAR , in which folder we are uploading file and while searching the file using the keyword with the help lucene search engine, we are finding the file , location and displaying the filename in jsp , Moreover for user friendly , we are providing href link to the file name like following ,


a href= "/docs/Test.txt" target= "_blank" Test.txt

gautham...@gmail.com

unread,
Aug 6, 2008, 4:52:19 AM8/6/08
to
hi

Here the context root is the first point to reach the application, you
need to prefix the file name after the context root to invoke the
file, the best location would be the docroot of the appserver, where
you can host the files

Thanx

Gautam Reddy

Ken Hygh

unread,
Aug 6, 2008, 6:22:42 AM8/6/08
to
First, allow me to protest that putting uploaded files in the same
filesystem as your application server is risky. One user, uploading
enough stuff to fill that filesystem, will kill your appserver. Among
other nasties that could happen.

But in case you really want to do this...
<wasInstallRoot>/profiles/<profilename>/installedApps/<cellname>/<earfilename>/<warfilename>

Ken

Ben_

unread,
Aug 6, 2008, 7:37:37 AM8/6/08
to

> First, allow me to protest that putting uploaded files in the same
> filesystem as your application server is risky. One user, uploading enough
> stuff to fill that filesystem, will kill your appserver. Among other
> nasties that could happen.

+1

I also wonder to what extends it's even legal and portable.

I can imagine the implementer of a J2EE Container can choose how it deploys
the EAR and if it even needs to expand the EAR on the file system, in which
case it breaks this design.

karun_su...@chiron.com

unread,
Aug 6, 2008, 11:54:00 AM8/6/08
to
Thangavel!

Context Root is a J2EE Web Application Specification and it is same whether it is JBOSS or WebSphere or WebLogic.

Context Root is specified in application.xml Deployment Descriptor and it must be present in the META-INF directory in your EAR file.

So, all you are doing is just porting the App to WebSphere, you shouldn't have to do anything extra.


Karun


0 new messages