Skip to main content



      Home
Home » Eclipse Projects » Virgo » Virgo-Tomcat to serve files?
Virgo-Tomcat to serve files? [message #714510] Wed, 10 August 2011 13:04 Go to next message
Eclipse UserFriend
Hi,

I am trying to begin using Virgo2 which has been adopted by a project I am working on (ie forgive my ignorance).

In the previous iteration we deployed a javaws app via tomcat by dropping the jars and jnlp into a folder under tomcat/webapps. I have not found an equivalent way to do this in Virgo 2. Can you simply use virgo2 to share files or will I need to start up a second server (tomcat/apache) to make this work?

Pointers to any docs woudl be appreciated
Re: Virgo-Tomcat to serve files? [message #714680 is a reply to message #714510] Thu, 11 August 2011 05:09 Go to previous message
Eclipse UserFriend
Hi,

In Virgo 3.0.0.x we support Tomcat 7 feature: Alias support for Contexts: Mapping to an external content into a web application. [1]
So you can create very simple web application that contains not Servlets, JSPs or Static Resources, but in it's context.xml describes aliases to an external content.



  1. Open the attached war, go to META-INF/context.xml and change the value for aliases attribute.
  2. Put the attached war file into the pickup directory.
  3. Request http://localhost:8080/aliases-example/images/<image-file-name>



Regards
Violeta

[1] http://tomcat.apache.org/tomcat-7.0-doc/config/context.html#Standard_Implementation

"aliases - This attribute provides a list of external locations from which to load resources for this context. The list of aliases should be of the form "/aliasPath1=docBase1,/aliasPath2=docBase2" where aliasPathN must include a leading '/' and docBaseN must be an absolute path to either a .war file or a directory.

A resource will be searched for in the first docBaseN for which aliasPathN is a leading path segment of the resource. If there is no such alias, then the resource will be searched in the usual way.

Using '/' as an aliasPath is not allowed. Consider using docBase instead.

These external locations will not be emptied if the context is un-deployed."
Previous Topic:Documentation about Spring Security / Virgo integration
Next Topic:Problem starting the Server
Goto Forum:
  


Current Time: Tue Jul 08 04:43:29 EDT 2025

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

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

Back to the top