java - 使用 JBoss 的 j_security_check 中的 http 状态 408

标签 java hibernate jboss struts http-error

目前我面临着奇怪的问题。我有一个演示应用程序,它仅从数据库对用户进行身份验证并显示欢迎页面。

问题是,如果我保持登录页面打开,然后在重新启动服务器后,尝试使用之前打开的同一页面登录,屏幕显示我 HTTP 状态 408 - 已超出登录过程允许的时间. 错误。

我尝试了 HTTP Status 408 error during login with domain forwarding set up 中的建议更改链接,但它不起作用。

这是我的登录页面:

<!DOCTYPE html>
<head>
        <title>Login</title>
        <meta charset="utf-8" />
        <meta http-equiv="Cache-Control" content="no-store,no-cache,must-revalidate"/>
        <meta http-equiv="Pragma" content="no-cache"/>
        <meta http-equiv="Expires" content="-1"/>
</head>
<body>
    <form method="post" action='<%= response.encodeURL("j_security_check") %>' id="login" >
        <label for="username">Username</label>
        <input type="text" name="j_username" id="username" autofocus />

        <label for="password">Password</label>
        <input type="password" name="j_password" id="password" />

        <button type="submit" class="primary" name="Submit">Log in</button>
    </form>
</body>
</html>

我尝试调试,但请求未通过服务器发送到 Controller 。所以我猜测jboss服务器有问题。任何帮助将不胜感激。谢谢

最佳答案

就我而言,我添加了登录页面。

setInterval(function(){
        location.reload(true); //reload each 5 minutes
    },5*60*1000);

希望这有帮助。

关于java - 使用 JBoss 的 j_security_check 中的 http 状态 408,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25933560/

相关文章:

java - 如何使用 Spring Security 从失败的登录中获取用户名?

java - Hibernate 在 DAO 查询时停止

java - 我们可以在hibernate中的选择或更新查询中使用表名而不是java类名吗?

mysql - 如何让 docker 容器与非 dockerized 应用程序对话?

java - 在列表上映射通用方法并生成结果列表

java - 调整浏览器窗口大小后无法从元素获取文本(Chrome)

java - 正则表达式:?: notation(问号和冒号)

java - Telosys 工具 Java - 从 MySQL 数据库生成 CRUD UI,BeanCreationException

Java 守护线程未获取更新的变量

java - 在将 EJBTransactionRolledbackException 记录到文件之前捕获它