0

我是新手Java EE。我正在尝试修改init()servlet 中的代码。我创建了一个在 init() 方法中调用的 loadConfiguration(config) 方法。我还在文件WEB-INF夹中上传了一个 velocity.property 文件。loadConfiguration()方法如下:-

protected Properties loadConfiguration (ServletConfig config) throws IOException, FileNotFoundException  {
    String propsFile = config.getInitParameter(INIT_PROPS_KEY);
    Properties p = new Properties();

    if ( propsFile != null ) {
      InputStream iStream = getServletContext().getResourceAsStream( propsFile );

      if ( iStream != null ) {
        p.load( iStream );
      }
    }

    return p;
    }

当我尝试在 weblogic 中运行此应用程序时,我收到 403 错误,告诉我服务器理解请求但拒绝遵守。

这个问题有什么解决方法吗?

任何帮助将不胜感激 !

4

1 回答 1

0

Response status code 403 means the servlet is forbidden. Check if you have any security constraints defined in your web application.

于 2012-06-15T08:05:05.877 回答