问题描述
我在服务器上有一个文件夹,里面包含了所有的图像,静态文件,还有我的应用程序的存储,我需要在 **上下文。
此刻,我在名为storage的应用程序statup上安装了一个符号链接,
我试图在GlassFish应用服务器v2.1中设置一个虚拟主机,只为静态内容提供服务,但是,出现了一个大问题,如何禁用httpsession管理?
对JS,CSS或IMG文件的每个请求,会话都由jsessionid检索。所有这些工作都是徒劳的。
关于如何在存储上下文中提供静态内容的最佳方式以及如何禁用特定主机中的会话管理的所有解释?
问候。
Rigoni
我不知道您是否知道这一点,但GlassFish支持,它非常适合静态内容:
我知道这不是对问题的直接回答,但这不是更好的选择吗?
资源
I have a folder in the server, that contains all the images, static files, and more its the storage of my application, I need to serve this files on a http://host:8080/storage/** context.At this moment I mount a symlink on the root of the application on the application statup called "storage",I'm trying to setup a virtualhost in Glassfish Application Server v2.1 to serve only static content, but, a big problem appeared, how to disable the httpsession management?Each request to a JS,CSS or IMG file, the session was retrieved by the jsessionid. All this work will be vain.All sugestion about how the best way to serve the static content in the "storage" context and how to disable the session management in a specific host?
Regards.Rigoni
I don't know if you are aware of that but GlassFish does support Alternate Docroots and Local Resource Paths which is very nice to serve static content:
I know this is not a direct answer to the question, but wouldn't this be a better alternative?
Resources
这篇关于Glassfish vhost只提供静态内容。禁用会话如何?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!