SSI Jboss不包括html(上下文问题)

时间:2022-06-01 20:20:15

Hi I hope that someone out there could give a clue on where to here. Here's the problem.

嗨,我希望那里的人可以提供一个线索,告诉我们去哪里。这是问题所在。

I have enabled SSI in some jboss under Solaris, I have the application web.xml configured as follows:

我在Solaris下的一些jboss中启用了SSI,我的应用程序web.xml配置如下:

<filter>
    <filter-name>ssi</filter-name>
    <filter-class>
        org.apache.catalina.ssi.SSIFilter
    </filter-class>
    <init-param>
        <param-name>contentType</param-name>
        <param-value>application/xml(;.*)?</param-value> <!-- also have tried here html(;.*)? -->
    </init-param>
    <init-param>
        <param-name>debug</param-name>
        <param-value>0</param-value>
    </init-param>
    <init-param>
        <param-name>expires</param-name>
        <param-value>666</param-value>
    </init-param>
    <init-param>
        <param-name>isVirtualWebappRelative</param-name>
        <param-value>0</param-value>
    </init-param>
</filter>

  <filter-mapping>
    <filter-name>ssi</filter-name>
    <url-pattern>*.xsl</url-pattern>
</filter-mapping>
    <!-- the following mappings were inserted after -->
<filter-mapping>
    <filter-name>ssi</filter-name>
    <url-pattern>*.html</url-pattern>
</filter-mapping>

<filter-mapping>
    <filter-name>ssi</filter-name>
    <url-pattern>*.shtml</url-pattern>
</filter-mapping>

So my problem is that the SSI is working for XSL files but not for HTML files. Also I put the Context issues in the title since I have a symbolic link to my app.war in jboss this is because I'm using a CMS and I need the files to be posted somewhere in the file system.

所以我的问题是SSI适用于XSL文件,但不适用于HTML文件。我也把语境问题的称号,因为我有一个符号链接到我在JBoss中app.war这是因为我使用的是CMS和我需要的文件,在文件系统中的某个地方张贴。

The two things I can think about this, is that either is something messing up with my multiple filter mapping declarations (which is very unlikely) and the other one is that jboss is not able to reload the context for this app.war

我能想到的两件事是,要么是我的多个过滤器映射声明搞砸了(这是非常不可能的),另一个是jboss无法为这个app.war重新加载上下文。

Also I put here some information about Context.xml since I think you might ask for it

我还在这里提供了一些关于Context.xml的信息,因为我认为你可能会要求它

<?xml version="1.0" encoding="UTF-8"?>
<Context antiJARLocking="true" reloadable="true" privileged="true"/>

I will appreciate any pointers, I can't figure out what could it be

我会欣赏任何指针,我无法弄清楚它会是什么

1 个解决方案

#1


just changed from filter to servlet and worked just fine here's the code

刚刚从过滤器更改为servlet,工作得很好,这里是代码

<servlet>
    <servlet-name>ssi</servlet-name>
    <servlet-class>org.apache.catalina.ssi.SSIServlet</servlet-class>
    <init-param>
        <param-name>buffered</param-name>
        <param-value>1</param-value>
    </init-param>
    <init-param>
        <param-name>debug</param-name>
        <param-value>0</param-value>
    </init-param>
    <init-param>
        <param-name>expires</param-name>
        <param-value>60</param-value>
    </init-param>
    <init-param>
        <param-name>isVirtualWebappRelative</param-name>
        <param-value>1</param-value>
    </init-param>
    <load-on-startup>1</load-on-startup>
</servlet>

#1


just changed from filter to servlet and worked just fine here's the code

刚刚从过滤器更改为servlet,工作得很好,这里是代码

<servlet>
    <servlet-name>ssi</servlet-name>
    <servlet-class>org.apache.catalina.ssi.SSIServlet</servlet-class>
    <init-param>
        <param-name>buffered</param-name>
        <param-value>1</param-value>
    </init-param>
    <init-param>
        <param-name>debug</param-name>
        <param-value>0</param-value>
    </init-param>
    <init-param>
        <param-name>expires</param-name>
        <param-value>60</param-value>
    </init-param>
    <init-param>
        <param-name>isVirtualWebappRelative</param-name>
        <param-value>1</param-value>
    </init-param>
    <load-on-startup>1</load-on-startup>
</servlet>